used to teach how to write Makefile.am and configure.ac
setup steps:
- sh build.sh init
- configure --prefix=/your/install/path
- make
- make install
cleanup steps:
- make clean
- build.sh clean
example:
- My code dir is /home/raywill/teach/automake
- My build dir is /home/raywill/teach/automake/build
- My install dir is /home/raywill/teach/automake/install
after all dirs are ready, I follow these step to build my program:
- cd /home/raywill/teach/automake
- sh build.sh init
- cd build
- ../configure --prefix=/home/raywill/teach/automake/install
- make
- make install #may be [sudo make install], depends if sys folder.
- cd ../install/
- ls #check if everything is installed. done ;)
I want my code tree clean, so I mkdir an ./build dir to I configure the prefix as /home/raywill/teach/automake