Hello,
my autoupdater found out that a new version 8.0 got published over the weekend. Cool! But the update failed.
Changelog: there is a new Cmake system. So, let's try it manually.
I ran:
wget http://www.hiawatha-webserver.org/files/hiawatha-8.0.tar.gz
tar -xzf hiawatha-8.0.tar.gz
cd hiawatha-8.0/extra
./make_debian_package
I got:
-- Checking for required packages
./make_debian_package: 33: ./make_debian_package: cmake: not found
make: *** No targets specified and no makefile found. Stop.
make: *** No rule to make target `install'. Stop.
-- Building package
gzip: debian/hiawatha/usr/share/man/man1/*: No such file or directory
cp: cannot stat `logrotate.d': No such file or directory
dpkg-gencontrol: warning: Depends field of package hiawatha: unknown substitution variable ${shlibs:Depends}
dpkg-deb: building package `hiawatha' in `../hiawatha_8.0_i386.deb'.
My bad. Let's try again:
sudo aptitude install cmake
./make_debian_package
Now it looks much better, but fails again:
-- Checking for required packages
-- The C compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Found LibXml2: /usr/lib/libxml2.so
-- checking for module 'libxslt'
-- found libxslt, version 1.1.26
-- Found LibXslt: /usr/lib/libxslt.so
-- Looking for crypt.h
-- Looking for crypt.h - found
-- Looking for arpa/inet.h
-- Looking for arpa/inet.h - found
-- Looking for netinet/in.h
-- Looking for netinet/in.h - found
-- Looking for include files HAVE_NETINET_TCP_H
-- Looking for include files HAVE_NETINET_TCP_H - found
-- Looking for rpcsvc/crypt.h
-- Looking for rpcsvc/crypt.h - not found
-- Looking for sys/socket.h
-- Looking for sys/socket.h - found
-- Looking for sys/time.h
-- Looking for sys/time.h - found
-- Looking for setenv
-- Looking for setenv - found
-- Looking for unsetenv
-- Looking for unsetenv - found
-- Looking for clearenv
-- Looking for clearenv - found
-- Looking for strcasecmp
-- Looking for strcasecmp - found
-- Looking for strncasecmp
-- Looking for strncasecmp - found
-- Looking for strnstr
-- Looking for strnstr - not found
-- Looking for strcasestr
-- Looking for strcasestr - found
-- Looking for strncasestr
-- Looking for strncasestr - not found
-- Looking for crypt in crypt
-- Looking for crypt in crypt - found
-- Looking for socket in network
-- Looking for socket in network - not found
-- Looking for gzdopen in z
-- Looking for gzdopen in z - found
-- Configuring done
-- Generating done
-- Build files have been written to: /root/inst/hiawatha/hiawatha-8.0/build
Scanning dependencies of target cgi-wrapper
[ 1%] Building C object CMakeFiles/cgi-wrapper.dir/src/alternative.c.o
[ 2%] Building C object CMakeFiles/cgi-wrapper.dir/src/cgi-wrapper.c.o
[ 3%] Building C object CMakeFiles/cgi-wrapper.dir/src/userconfig.c.o
[ 4%] Building C object CMakeFiles/cgi-wrapper.dir/src/libfs.c.o
[ 5%] Building C object CMakeFiles/cgi-wrapper.dir/src/libstr.c.o
Linking C executable cgi-wrapper
[ 5%] Built target cgi-wrapper
Scanning dependencies of target polarssl
[ 7%] Building C object polarssl/library/CMakeFiles/polarssl.dir/aes.c.o
[ 8%] Building C object polarssl/library/CMakeFiles/polarssl.dir/arc4.c.o
[ 9%] Building C object polarssl/library/CMakeFiles/polarssl.dir/asn1parse.c.o
[ 10%] Building C object polarssl/library/CMakeFiles/polarssl.dir/base64.c.o
[ 11%] Building C object polarssl/library/CMakeFiles/polarssl.dir/bignum.c.o
[ 13%] Building C object polarssl/library/CMakeFiles/polarssl.dir/camellia.c.o
[ 14%] Building C object polarssl/library/CMakeFiles/polarssl.dir/certs.c.o
[ 15%] Building C object polarssl/library/CMakeFiles/polarssl.dir/cipher.c.o
[ 16%] Building C object polarssl/library/CMakeFiles/polarssl.dir/cipher_wrap.c.o
[ 17%] Building C object polarssl/library/CMakeFiles/polarssl.dir/ctr_drbg.c.o
[ 19%] Building C object polarssl/library/CMakeFiles/polarssl.dir/debug.c.o
[ 20%] Building C object polarssl/library/CMakeFiles/polarssl.dir/des.c.o
[ 21%] Building C object polarssl/library/CMakeFiles/polarssl.dir/dhm.c.o
[ 22%] Building C object polarssl/library/CMakeFiles/polarssl.dir/entropy.c.o
[ 23%] Building C object polarssl/library/CMakeFiles/polarssl.dir/entropy_poll.c.o
[ 25%] Building C object polarssl/library/CMakeFiles/polarssl.dir/error.c.o
[ 26%] Building C object polarssl/library/CMakeFiles/polarssl.dir/havege.c.o
[ 27%] Building C object polarssl/library/CMakeFiles/polarssl.dir/md.c.o
[ 28%] Building C object polarssl/library/CMakeFiles/polarssl.dir/md_wrap.c.o
[ 29%] Building C object polarssl/library/CMakeFiles/polarssl.dir/md2.c.o
[ 30%] Building C object polarssl/library/CMakeFiles/polarssl.dir/md4.c.o
[ 32%] Building C object polarssl/library/CMakeFiles/polarssl.dir/md5.c.o
[ 33%] Building C object polarssl/library/CMakeFiles/polarssl.dir/net.c.o
[ 34%] Building C object polarssl/library/CMakeFiles/polarssl.dir/padlock.c.o
[ 35%] Building C object polarssl/library/CMakeFiles/polarssl.dir/pem.c.o
[ 36%] Building C object polarssl/library/CMakeFiles/polarssl.dir/pkcs11.c.o
[ 38%] Building C object polarssl/library/CMakeFiles/polarssl.dir/rsa.c.o
[ 39%] Building C object polarssl/library/CMakeFiles/polarssl.dir/sha1.c.o
[ 40%] Building C object polarssl/library/CMakeFiles/polarssl.dir/sha2.c.o
[ 41%] Building C object polarssl/library/CMakeFiles/polarssl.dir/sha4.c.o
[ 42%] Building C object polarssl/library/CMakeFiles/polarssl.dir/ssl_cli.c.o
[ 44%] Building C object polarssl/library/CMakeFiles/polarssl.dir/ssl_srv.c.o
[ 45%] Building C object polarssl/library/CMakeFiles/polarssl.dir/ssl_tls.c.o
[ 46%] Building C object polarssl/library/CMakeFiles/polarssl.dir/timing.c.o
[ 47%] Building C object polarssl/library/CMakeFiles/polarssl.dir/version.c.o
[ 48%] Building C object polarssl/library/CMakeFiles/polarssl.dir/x509parse.c.o
[ 50%] Building C object polarssl/library/CMakeFiles/polarssl.dir/xtea.c.o
Linking C shared library libpolarssl.so
[ 50%] Built target polarssl
Scanning dependencies of target hiawatha
[ 51%] Building C object CMakeFiles/hiawatha.dir/src/alternative.c.o
[ 52%] Building C object CMakeFiles/hiawatha.dir/src/cache.c.o
[ 53%] Building C object CMakeFiles/hiawatha.dir/src/cgi.c.o
[ 54%] Building C object CMakeFiles/hiawatha.dir/src/client.c.o
[ 55%] Building C object CMakeFiles/hiawatha.dir/src/command.c.o
[ 57%] Building C object CMakeFiles/hiawatha.dir/src/envir.c.o
[ 58%] Building C object CMakeFiles/hiawatha.dir/src/hiawatha.c.o
[ 59%] Building C object CMakeFiles/hiawatha.dir/src/httpauth.c.o
[ 60%] Building C object CMakeFiles/hiawatha.dir/src/libfs.c.o
[ 61%] Building C object CMakeFiles/hiawatha.dir/src/libip.c.o
[ 63%] Building C object CMakeFiles/hiawatha.dir/src/liblist.c.o
[ 64%] Building C object CMakeFiles/hiawatha.dir/src/libssl.c.o
[ 65%] Building C object CMakeFiles/hiawatha.dir/src/libstr.c.o
[ 66%] Building C object CMakeFiles/hiawatha.dir/src/log.c.o
[ 67%] Building C object CMakeFiles/hiawatha.dir/src/mimetype.c.o
[ 69%] Building C object CMakeFiles/hiawatha.dir/src/monitor.c.o
[ 70%] Building C object CMakeFiles/hiawatha.dir/src/send.c.o
[ 71%] Building C object CMakeFiles/hiawatha.dir/src/serverconfig.c.o
[ 72%] Building C object CMakeFiles/hiawatha.dir/src/session.c.o
[ 73%] Building C object CMakeFiles/hiawatha.dir/src/target.c.o
[ 75%] Building C object CMakeFiles/hiawatha.dir/src/toolkit.c.o
[ 76%] Building C object CMakeFiles/hiawatha.dir/src/userconfig.c.o
[ 77%] Building C object CMakeFiles/hiawatha.dir/src/xslt.c.o
Linking C executable hiawatha
/usr/bin/ld: CMakeFiles/hiawatha.dir/src/monitor.c.o: undefined reference to symbol 'gzdopen'
/usr/bin/ld: note: 'gzdopen' is defined in DSO /usr/lib/libz.so.1 so try adding it to the linker command line
/usr/lib/libz.so.1: could not read symbols: Invalid operation
collect2: ld returned 1 exit status
make[2]: *** [hiawatha] Error 1
make[1]: *** [CMakeFiles/hiawatha.dir/all] Error 2
make: *** [all] Error 2
[ 5%] Built target cgi-wrapper
[ 50%] Built target polarssl
Linking C executable hiawatha
/usr/bin/ld: CMakeFiles/hiawatha.dir/src/monitor.c.o: undefined reference to symbol 'gzdopen'
/usr/bin/ld: note: 'gzdopen' is defined in DSO /usr/lib/libz.so.1 so try adding it to the linker command line
/usr/lib/libz.so.1: could not read symbols: Invalid operation
collect2: ld returned 1 exit status
make[2]: *** [hiawatha] Error 1
make[1]: *** [CMakeFiles/hiawatha.dir/all] Error 2
make: *** [all] Error 2
-- Building package
gzip: debian/hiawatha/usr/share/man/man1/*: No such file or directory
dpkg-gencontrol: warning: Depends field of package hiawatha: unknown substitution variable ${shlibs:Depends}
dpkg-deb: building package `hiawatha' in `../hiawatha_8.0_i386.deb'.
Not cool.I do understand, that there is an idea of improvement in the compilation/installation process behind the strategic move to Cmake. I also appreciate things like automated package dependency checks and clear multiplatform targeting.
However, the user point of view is: "It used to work before, and now it's broken!"
]In both cases the script happily continued and created a deb package, even after a failure!The deb file was 13kB in size. This should not be happening, it makes Hiawatha look unfinished.
What is
undefined reference to symbol 'gzdopen'? How can I resolve it?
Thanks,
JanH