Wireshark-users: Re: [Wireshark-users] Unable to compile static build of TShark on Fedora 7
From: Guy Harris <guy@xxxxxxxxxxxx>
Date: Thu, 6 Sep 2007 19:21:34 -0700

On Sep 6, 2007, at 3:26 PM, Barry Gould wrote:

I'm really starting to suspect that configure isn't working right.
I just tried with --disable-zlib, and it still says "Ues zlib library: yes"

This leads me to wonder if the other options are working

The options that exist should be working.

"--disable-zlib", however, isn't one of the options that exist:

	$ ./configure --help
	`configure' configures this package to adapt to many kinds of systems.

	Usage: ./configure [OPTION]... [VAR=VALUE]...

		...

	For better control, use the options below.

		...

	Optional Features:
--disable-FEATURE do not include FEATURE (same as --enable- FEATURE=no)
	  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
	  --enable-static[=PKGS]  build static libraries [default=no]
	  --disable-dependency-tracking  speeds up one-time build
--enable-dependency-tracking do not reject slow dependency extractors
	  --enable-shared[=PKGS]  build shared libraries [default=yes]
	  --enable-fast-install[=PKGS]
	                          optimize for fast installation [default=yes]
	  --disable-libtool-lock  avoid locking (might break parallel builds)
	  --enable-extra-gcc-checks
	                          Do additional -W checks in GCC. [default=no]
	  --enable-warnings-as-errors
	                          Treat warnings as errors (only for gcc).
	                          [default=yes]
	  --enable-usr-local      look for headers and libs in /usr/local tree.
	                          [default=yes]
--enable-wireshark build GTK+-based wireshark. [default=yes, if GTK+
	                          available]
	  --disable-gtk2          build Glib1/Gtk1+-based wireshark/tshark.
	                          [default=no]
	  --enable-threads        use threads in wireshark. [default=no]
	  --enable-profile-build  build profile-ready binaries. [default=no]
--disable-gtktest do not try to compile and run a test GTK+ program --disable-gtktest Do not try to compile and run a test GTK program --disable-glibtest do not try to compile and run a test GLIB program --disable-glibtest Do not try to compile and run a test GLIB program
	  --enable-tshark         build tshark. [default=yes]
	  --enable-editcap        build editcap. [default=yes]
	  --enable-capinfos       build capinfos. [default=yes]
	  --enable-mergecap       build mergecap. [default=yes]
	  --enable-text2pcap      build text2pcap. [default=yes]
	  --enable-idl2wrs        build idl2wrs. [default=yes]
	  --enable-dftest         build dftest. [default=yes]
	  --enable-randpkt        build randpkt. [default=yes]
	  --enable-dumpcap        build dumpcap. [default=yes]
	  --enable-ipv6           use ipv6 name resolution, if available.
	                          [default=yes]
--enable-setuid-install install tshark and dumpcap as setuid [default=no]
	
	Optional Packages:
	  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
--without-PACKAGE do not use PACKAGE (same as --with- PACKAGE=no) --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-pic try to use only PIC/non-PIC objects [default=use
	                          both]
	  --with-tags[=TAGS]      include additional configurations [automatic]
	  --with-gnutls=[yes/no]  use gnutls library [default=yes]
--with-libgnutls-prefix=PFX Prefix where libgnutls is installed (optional)
	  --with-gcrypt=[yes/no]  use gcrypt library [default=yes]
	  --with-libgcrypt-prefix=PFX
prefix where LIBGCRYPT is installed (optional)
	  --with-gtk-prefix=PFX   Prefix where GTK is installed (optional)
--with-gtk-exec-prefix=PFX Exec prefix where GTK is installed (optional)
	  --with-glib-prefix=PFX   Prefix where GLIB is installed (optional)
--with-glib-exec-prefix=PFX Exec prefix where GLIB is installed (optional) --with-pcap[=DIR] use libpcap for packet capturing. [default=yes] --with-zlib[=DIR] use zlib (located in directory DIR, if supplied) to read compressed data. [default=yes, if available] --with-pcre[=DIR] use libpcre (located in directory DIR, if supplied) to use in dfilter regular expressions. [default=yes,
	                          if available]
--with-lua[=DIR] use liblua (located in directory DIR, if supplied)
	                          for the lua scripting plugin. [default=no]
--with-portaudio[=DIR] use libportaudio (located in directory DIR, if supplied) for the rtp_player. [default=yes, if
	                          available]
--with-libiconv-prefix=DIR search for libiconv in DIR/include and DIR/lib --with-ssl[=DIR] use SSL crypto library (located in directory DIR, if
	                          supplied). [default=no]
--with-net-snmp[=PATH] use Net-SNMP library (with PATH as the location of the net-snmp-config shell script that comes with the net-snmp package, if supplied) [default=yes, if
	                          available]
--with-krb5[=DIR] use kerberos (located in directory DIR, if supplied)
	                          to use in kerberos dissection [default=yes]
	  --with-adns[=DIR]       use GNU ADNS (located in directory DIR, if
	                          supplied). [default=yes, if present]
--with-plugins[=DIR] support plugins (installed in DIR, if supplied).
	                          [default=yes, if possible]

zlib is a package, not a feature, so there's no "--disable-zlib" option; the option is "--without-zlib".

However, configure scripts don't check whether a --enable, --disable, --with, or --without flag refers to an option that exists; you could say "--enable-faster-than-light-travel" or "--with-an-extra-scoop-of- whipped-cream" and you'll get no complaints.