Wireshark-dev: [Wireshark-dev] SVN link failing on FC5 due to missing -lgcrypt
From: Jeff Morriss <jeff.morriss@xxxxxxxxxxx>
Date: Mon, 03 Jul 2006 14:33:16 +0800

Hi list,

My FC5 (SVN 18636) compile fails here:

gcc -DINET6 "-D_U_=__attribute__((unused))" -Wall -Wpointer-arith -W -g -O2 -I/usr/local/include -pthread -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -o .libs/wireshark capture-pcap-util-unix.o capture_errs.o capture-pcap-util.o capture_stop_conditions.o capture_ui_utils.o cfile.o clopts_common.o conditions.o disabled_protos.o packet-range.o print.o ps.o pcapio.o ringbuffer.o timestats.o util.o version_info.o alert_box.o capture.o capture_info.o capture_opts.o capture_sync.o color_filters.o file.o fileset.o filters.o g711.o merge.o proto_hier_stats.o sync_pipe_write.o summary.o tempfile.o .libs/wiresharkS.o -pthread -Wl,--export-dynamic  -L/usr/local/lib gtk/libui.a wiretap/.libs/libwiretap.so epan/.libs/libwireshark.so -lpcap -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgdk_pixbuf-2.0 -lm -lpangocairo-1.0 -lpango-1.0 -lcairo -lgobject-2.0 -lgmodule-2.0
-ldl -lgthread-2.0 -lglib-2.0 -lkrb5 -lk5crypto -lkrb5support -lcom_err -lresolv -lz
epan/.libs/libwireshark.so: undefined reference to `gcry_md_get_algo_dlen'
epan/.libs/libwireshark.so: undefined reference to `gcry_md_close'
epan/.libs/libwireshark.so: undefined reference to `gcry_md_read'
epan/.libs/libwireshark.so: undefined reference to `gcry_md_setkey'
epan/.libs/libwireshark.so: undefined reference to `gcry_cipher_get_algo_keylen'
epan/.libs/libwireshark.so: undefined reference to `gcry_control'
epan/.libs/libwireshark.so: undefined reference to `gcry_md_write'
epan/.libs/libwireshark.so: undefined reference to `gcry_cipher_open'
epan/.libs/libwireshark.so: undefined reference to `gcry_cipher_ctl'
epan/.libs/libwireshark.so: undefined reference to `gcry_cipher_close'
epan/.libs/libwireshark.so: undefined reference to `gcry_md_open'
epan/.libs/libwireshark.so: undefined reference to `gcry_md_algo_name'
epan/.libs/libwireshark.so: undefined reference to `gpg_strerror'
epan/.libs/libwireshark.so: undefined reference to `gcry_cipher_decrypt'
epan/.libs/libwireshark.so: undefined reference to `gcry_cipher_algo_name'
collect2: ld returned 1 exit status
make[2]: *** [wireshark] Error 1

The relevant output from 'configure' seems to be:

checking for libgnutls-config... no
checking for libgnutls - version >= 1.0.0... no
*** The libgnutls-config script installed by LIBGNUTLS could not be found
*** If LIBGNUTLS was installed in PREFIX, make sure PREFIX/bin is in
*** your path, or set the LIBGNUTLS_CONFIG environment variable to the
*** full path to libgnutls-config.
echo gnuTLS not found, disabling ssl decryption
checking for libgcrypt-config... /usr/bin/libgcrypt-config
checking for LIBGCRYPT - version >= 1.1.0... yes
libgcrypt found, enabling ipsec decryption


Manually adding "-lgcrypt" to the link solves the problem. The attached patch does, too, but it's my first time mucking with any file named ".am", so it may not be correct.

Regards,
-Jeff

Attachment: Makefile.am.patch.gz
Description: GNU Zip compressed data