Apache & mod_gzip: No rule to make target `libgzip.’
I was upgrading an Apache install from 1.3.33 to 1.3.34 last night, including the gzip module using: --activate-module=src/modules/gzip/mod_gzip.o, and during the make process I received the following error:
rm -f libgzip.a
ar cr libgzip.a mod_gzip.o mod_gzip_compress.o mod_gzip_debug.o
make: *** No rule to make target `libgzip.', needed by `lib'. Stop.
make: *** [all] Error 1
make: *** [subdirs] Error 1
make: Leaving directory `/usr/local/src/apache_1.3.34/src'
make: *** [build-std] Error 2
make: Leaving directory `/usr/local/src/apache_1.3.34'
make: *** [build] Error 2
It turns out that there’s an entry in mod_gzip’s Makefile.tmpl file that confuses my system. The very first line of src/modules/gzip/Makefile.tmpl uses a variable named LIBEXT that’s not defined on my system, so it fails. It’s an easy fix, open up src/modules/gzip/Makefile.tmpl for editing and find:
And replace with:
Save & Exit, run make clean; make; make install in the Apache src dir and you should be good to go.