Nous utilisons Apache HTTPD comme équilibreur de charge de production en utilisant mod_ssl avec OpenSSL. J'essaie de recompiler Apache HTTPD sur la dernière version (2.4.41) et je rencontre l'erreur suivante lors de son exécution make
. Je vais inclure l'erreur, mais si une plus grande partie de la trace de la pile peut être utile, je suis heureux de la poster.
Notez qu'OpenSSL est actuellement sur la version 1.1.1c, et je rencontre le même problème en essayant de construire Apache HTTPD versions 2.4.38 et 2.4.39.
Au départ, j'ai pensé qu'il s'agissait d'un problème de compatibilité entre OpenSSL et Apache en me basant sur des articles publiés ailleurs, mais je ne peux pas reproduire l'erreur sur une nouvelle machine virtuelle - tout se compile sans problème. Il doit donc s'agir d'un problème environnemental.
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/srclib/apr/libtool --silent --mode=compile gcc -std=gnu99 -g -O2 -pthread -DLINUX -D_REENTRANT -D_GNU_SOURCE \
-I. -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/os/unix -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/include -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/srclib/apr/include -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/srclib/apr-util/include -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/aaa -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/cache -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/core -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/database -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/filters -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/ldap -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/loggers -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/lua -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/proxy -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/http2 -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/session -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/ssl -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/test -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/server -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/md -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/arch/unix -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/dav/main -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/generators -I/etc/puppetlabs/tmp/httpd/httpd-2.4.41/modules/mappers -prefer-non-pic -static -c ab.c && touch ab.lo
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/srclib/apr/libtool --silent --mode=link gcc -std=gnu99 -g -O2 -pthread \
-o ab ab.lo /etc/puppetlabs/tmp/httpd/httpd-2.4.41/srclib/apr-util/libaprutil-1.la -lexpat /etc/puppetlabs/tmp/httpd/httpd-2.4.41/srclib/apr/libapr-1.la -lrt -lcrypt -lpthread -ldl -lm -lssl -lcrypto -lrt -lcrypt -lpthread -ldl
ab.o: In function `ssl_state_cb':
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:575: undefined reference to `SSL_in_init'
ab.o: In function `ssl_print_cert_info':
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:653: undefined reference to `X509_get_version'
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:655: undefined reference to `X509_getm_notBefore'
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:659: undefined reference to `X509_getm_notAfter'
ab.o: In function `sk_X509_num':
/usr/local/include/openssl/x509.h:99: undefined reference to `OPENSSL_sk_num'
ab.o: In function `sk_X509_value':
/usr/local/include/openssl/x509.h:99: undefined reference to `OPENSSL_sk_value'
ab.o: In function `main':
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:2305: undefined reference to `TLS_client_method'
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:2560: undefined reference to `TLS_client_method'
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:2637: undefined reference to `OPENSSL_init_ssl'
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:2638: undefined reference to `OPENSSL_init_ssl'
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:2647: undefined reference to `SSL_CTX_set_options'
ab.o: In function `test':
/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support/ab.c:1990: undefined reference to `SSL_in_init'
collect2: error: ld returned 1 exit status
make[2]: *** [ab] Error 1
make[2]: Leaving directory `/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/etc/puppetlabs/tmp/httpd/httpd-2.4.41/support'
make: *** [all-recursive] Error 1
Notez que le répertoire 'puppetlabs' est uniquement destiné à permettre à Puppet de gérer la compilation, bien qu'il ne fasse qu'exécuter configure
, make
y make install
comme d'habitude.