recently I'm reading nginx source code, but I got confused how to build it's code by autoconf, I have try my best to write a Makefile.am, unfortunate, I'm failed to write a correct Makefile.am file, so I cann't get a configure file, does anybody know how to write a Makefile.am?
I know how to write a
Makefile.am
, but you have no need to.As you know, the
nginx
source package is a GNU autotools package.You don't do the autotooling. The people who write
nginx
do that. When you download the source package, theconfigure.ac
, theMakefile.am
(s) and other autotools files are already there along with all the source code.To build the package, all you have to do is run the
configure
script to generate correct makefiles for your system, then runmake
. (This is why the build system is calledautotools
.)Source packages are distributed from
http://nginx.org/download/
. Assuming you wantnginx 1.10.2
(the stable release at this time), you simply do this in a suitable working directory:Then it's built in
./nginx-1.10.2
. If you then want to installnginx
in your system, continue:Building any autotooled source package is essential the same as this.
For full details and variations, do read NSTALLING NGINX OPEN SOURCE