aboutsummaryrefslogtreecommitdiffstats
path: root/acinclude.m4
AgeCommit message (Collapse)AuthorFilesLines
2013-12-26Fix configure-script errors with some versions of autoconf.Guy Harris1-0/+6
svn path=/trunk/; revision=54470
2013-12-26OK, "i686-apple-darwin11-llvm-g++-4.2 (GCC) 4.2.1 (Based on Apple Inc.Guy Harris1-18/+59
build 5658) (LLVM build 2336.11.00)" likes -Wmissing-prototypes but not -Wmissing-declarations and G++ 4.8.2 likes -Wmissing-declarations but not -Wmissing-prototypes, so check whether *either* of them requires -Werror in order to be detected as NSFC++. Fix a copy-and-pasteo while we're at it. Don't treat a different willingness to accept -Wmissing-{prototypes,declarations} as an indication that you have mismatched C and C++ compilers. svn path=/trunk/; revision=54468
2013-12-24No need for quotes around the arguments to AC_MSG_ macros.Guy Harris1-2/+2
svn path=/trunk/; revision=54448
2013-12-24Some warning options are, for reasons not entirely obvious to me, notGuy Harris1-1/+42
supported by some versions of g++ even though the corresponding version of gcc supports them. Other versions of g++, and clang, support them. Check, before adding a -W option for C++, whether the compiler supports it; that check must be done with -Werror, at least with g++, in order to get a non-zero exit status from the compiler. svn path=/trunk/; revision=54447
2013-10-16Add checks to see if CC and/or CXX are Clang. Add "-Qunused-arguments"Gerald Combs1-0/+42
to CFLAGS and/or CXXFLAGS as needed. svn path=/trunk/; revision=52654
2013-10-10Fix other HAVE_LUA entry.Guy Harris1-1/+1
svn path=/trunk/; revision=52517
2013-10-10Just describe HAVE_LUA as "Define to use Lua"; it's not tied to aGuy Harris1-1/+1
version, and this matches cmakeconfig.h.in. svn path=/trunk/; revision=52511
2013-09-18Revert "Prefer newer Lua versions"Balint Reczey1-1/+1
The original version was OK, obviously. svn path=/trunk/; revision=52141
2013-09-18Prefer newer Lua versionsBalint Reczey1-1/+1
svn path=/trunk/; revision=52140
2013-09-14Fix a typo Jörg Mayer1-1/+1
svn path=/trunk/; revision=52030
2013-08-12Just check whether dladdr() is available; we check in the code whetherGuy Harris1-36/+0
it succeeds, so there's no point in checking whether it succeeds in a sample program. svn path=/trunk/; revision=51322
2013-08-12On some platforms, to get dladdr() you need to link with -ldl. FirstGuy Harris1-0/+36
try it without -ldl (in case the OS doesn't have it - not a good idea, as it complicates the build process for cross-platform tools that might require it on other platforms, but "not a good idea" never stopped UN*X vendors in the past) and, if that fails, try it with -ldl. svn path=/trunk/; revision=51309
2013-07-24Add a AC_WIRESHARK_QT_MODULE_CHECK that checks for a particular QtGuy Harris1-67/+63
module, and use that in AC_WIRESHARK_QT_CHECK. svn path=/trunk/; revision=50882
2013-07-24The files in aclocal-fallback are copies of .m4 files from variousGuy Harris1-0/+125
packages, providing macros that we use in our configure script in case somebody building from SVN doesn't happen to have the package installed and thus doesn't happen to have those macros defined. In the case of Qt, there *isn't* such a .m4 file, so we had to create the macro. Move it to acinclude.m4, and rename it to AC_WIRESHARK_QT_CHECK to indicate that it's our own check. svn path=/trunk/; revision=50881
2013-07-02If the LHS of an "expr LHS : RHS" expression has an X added to avoidGuy Harris1-4/+4
confusing expr if the LHS is an empty string, the RHS needs it as well. Also, fix some typoes ("$X" rather than "X$"), and use lower-case "x", as that's what's used elsewhere when doing that sort of thing. svn path=/trunk/; revision=50331
2013-07-02Change additions from r50178 from if expr "$GCC_OPTION" to if exprStephen Fisher1-4/+4
"X$GCC_OPTION" so expr doesn't get confused by the GCC_OPTION that starts with a hyphen and spit out messages like this (on FreeBSD): checking whether we can add -fexcess-precision=fast to CXXFLAGS... expr: illegal option -- f expr: usage: expr [-e] expression expr: illegal option -- f expr: usage: expr [-e] expression no svn path=/trunk/; revision=50330
2013-06-28Rename AC_WIRESHARK_GCC_CFLAGS_CHECK toGuy Harris1-3/+3
AC_WIRESHARK_COMPILER_FLAGS_CHECK, because it doesn't just affect CFLAGS and it doesn't just affect the flags for GCC. svn path=/trunk/; revision=50222
2013-06-28Change formatting in the hopes of making the code a bit easier to figureGuy Harris1-104/+102
out, and update a comment. svn path=/trunk/; revision=50221
2013-06-28When checking whether a given option should be added to the compilerGuy Harris1-28/+16
flags, if the option should be added to the flags for both C and C++, test both the C and C++ compilers and, if the answers are different, print a warning; the user might have (intentionally or unintentionally) selected mismatched compilers, e.g. clang and g++ on OS X. svn path=/trunk/; revision=50219
2013-06-27Don't assume that compilers not named "clang" will, by default, reportGuy Harris1-5/+22
an error, or not issue warnings, by default if you give them an unknown -f flag. Instead, test that flag with all compilers, and use -Werror to force it to error out. As with C/C++ flags, so with C++-only flags. svn path=/trunk/; revision=50178
2013-06-26Don't assume that compilers that need an extra option to report errors,Guy Harris1-15/+35
rather than just warnings, for unknown warning options are named "clang"; they might not be. svn path=/trunk/; revision=50177
2013-06-26(Attempt to) fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8813 :Jeff Morriss1-5/+5
Enable INET6 checking on Solaris versions other than 5.8. (Yes, theoretically this should be checking for Solaris 5.7 or later. I'm going to go out on a limb and assume that no one is actually still using 5.7 or, if they are, they aren't trying to compile a modern Wireshark on it...) svn path=/trunk/; revision=50173
2013-03-06look for /usr/include/lua5.x directories to determine the lua versionMartin Kaiser1-1/+8
(Debian squeeze installs lua includes in /usr/include/lua5.1 and libs under /usr/lib, there's no --with-lua=<dir> setting for this configuration) see also https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8438 svn path=/trunk/; revision=48146
2013-02-04Add the warning flags to CFLAGS_FOR_BUILD, so any build tools we buildGuy Harris1-0/+10
are built with warnings. Also add compiler-specific flags (in this case, just the flags to enable ANSI C compilation) to CFLAGS_FOR_BUILD. svn path=/trunk/; revision=47479
2013-01-04In AC_WIRESHARK_GCC_CFLAGS_CHECK() don't check if $3 (the program to be run)Jeff Morriss1-4/+10
exists by doing: if test "x$3" != "x" ; then because if the program contains quotes it breaks the shell's parsing. Instead test for the existence of $4 (which is mandatory if $3 is given). Fix up the test program for -Wlogical-op so that it actually compiles warning-free (at least on my system) when the compiler doesn't have the bug we're checking for. svn path=/trunk/; revision=46926
2012-12-09Add some additional arguments to AC_WIRESHARK_GCC_CFLAGS_CHECK() to makeGuy Harris1-8/+77
it do an additional check, if it finds that a given compiler option is supported by the compiler, to see whether it's supported but undesirable. The arguments are a chunk of code to try to compile with -Werror, and a string to be used in the "checking..." message printed when trying to compile the cunk of code. Try enabling -Wshadow again, but have it check whether extern int atoi(char *p); int foo(char *p) { int (*fptr)(char *p) = atoi; return fptr(p) * 2; } compiles with -Wshadow and -Werror, so that we don't use -Wshadow with compilers that complain about that; some older versions of GCC complain about that, and it's really not worth our effort to eliminate or rename arguments in function prototypes to make -Wshadow work even with those compilers. svn path=/trunk/; revision=46475
2012-11-02From Jim Young and updated by Max Romanov:Anders Broman1-12/+18
The modification to acinclude.m4 adds a new test in the AC_WIRESHARK_OSX_INTEGRATION_CHECK section to first look for the library gtkmacintegration. "gtkmacintegration" is the new internal name for GTK+ MAC OSX library after the project was moved to www.gtk.org. Previously this library was known as igemacintegration. The patches to the three gtk/*.c files update the conditional #include <gtkmacintegration/gtkosxapplication.h> to use the new folder name. The Option 1 patch will break any build environment that expects to find the gtkosapplication.h file in the older igemacintegration folder. In addition the patch includes updates to gtk/main.c and gtk/main_menubar.c for a more standard looking App menu. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6702 svn path=/trunk/; revision=45869
2012-07-07Use -D_FORTIFY_SOURCE=2 only if the gc optimization level is greater than 0.Bill Meier1-0/+46
Fixes Bug #7449: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7449 ----- Issue: Building Wireshark with '-O0 -D_FORTIFY_SOURCE=2 ...' fails The warning [error] message: /usr/include/features.h:314:4: error: #warning _FORTIFY_SOURCE requires compiling with optimization (-O) [-Werror=cpp]` A bit of research shows that this warning was added to a recent version of glibc (on at least Fedora). See: http://sourceware.org/bugzilla/show_bug.cgi?id=13979 The warning message occurs if -D_FORTIFY_SOURCE=... is used and the gcc 'optimization level' == 0 (-O0). Unfortunately when building with -O0 this warning message: 1. Causes compiles to fail (if -Werror [stop on warning]) 2. Causes ./configure to fail with an (incorrect) message about the pcap header being older than the libpcap version. svn path=/trunk/; revision=43601
2012-06-25From Tony Trinh:Anders Broman1-2/+2
Update Lua from 5.1 to 5.2 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7400 svn path=/trunk/; revision=43482
2012-06-25From Tony Trinh:Anders Broman1-17/+26
Update autoconf script to check for Lua 5.2 https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7400 svn path=/trunk/; revision=43480
2012-06-17Whitespace fixJörg Mayer1-1/+1
svn path=/trunk/; revision=43305
2012-06-02If the user tries to save a capture file atop a file that has all itsGuy Harris1-0/+22
write bits turned off or, on 4.4-Lite-based systems, has its "user immutable" bit turned on, ask them if they really want to overwrite the file (as those are both used to say "this file is precious, don't let me easily accidentally trash it") and, if the "user immutable" bit is set, turn it off first so that the move in the "safe save" won't fail. svn path=/trunk/; revision=43006
2012-03-16Fix some comments and some indentation.Guy Harris1-9/+8
svn path=/trunk/; revision=41596
2012-03-16Put -D and -I flags into CPPFLAGS rather than into CFLAGS; that shouldGuy Harris1-79/+52
make them apply to C++ as well as C. That seems to be what the autoconf documentation suggests: - Variable: CFLAGS Debugging and optimization options for the C compiler. If it is not set in the environment when configure runs, the default value is set when you call AC_PROG_CC (or empty if you don't). configure uses this variable when compiling or linking programs to test for C features. If a compiler option affects only the behavior of the preprocessor (e.g., -Dname), it should be put into CPPFLAGS instead. If it affects only the linker (e.g., -Ldirectory), it should be put into LDFLAGS instead. If it affects only the compiler proper, CFLAGS is the natural home for it. If an option affects multiple phases of the compiler, though, matters get tricky. One approach to put such options directly into CC, e.g., CC='gcc -m64'. Another is to put them into both CPPFLAGS and LDFLAGS, but not into CFLAGS. ... - Variable: CPPFLAGS Preprocessor options for the C, C++, Objective C, and Objective C++ preprocessors and compilers. If it is not set in the environment when configure runs, the default value is empty. configure uses this variable when preprocessing or compiling programs to test for C, C++, Objective C, and Objective C++ features. This variable's contents should contain options like -I, -D, and -U that affect only the behavior of the preprocessor. Please see the explanation of CFLAGS for what you can do if an option affects other phases of the compiler as well. svn path=/trunk/; revision=41593
2012-03-16Have AC_WIRESHARK_GCC_CFLAGS_CHECK take an optional second flag toGuy Harris1-16/+74
indicate whether the flag is C-only, C++-only, or for both compilers; pass the appropriate value for C-only flags. Have the "Checking for..." message indicate whether we're adding to CFLAGS, CXXFLAGS, or both. (Yes, the macro should probably be renamed. "GCC" refers to the GNU Compiler Collection, which includes a C++ compiler, although that's also used for compilers that are more-or-less compatible with the ones from the GNU Compiler Collection, such as the clang compilers.) We set -Wformat-security whether or not --enable-extra-gcc-checks was specified, so we don't need to do it again if it was specified. svn path=/trunk/; revision=41586
2011-12-09Referring to pcap_version[] doesn't do what you want on at least someGuy Harris1-18/+0
UN*Xes (Fedora 16 and probably other Linux distributions, probably at least some if not all other ELF-based systems, and perhaps also Mac OS X), and causes problems if pcap_version[] has a different length in the libpcap with which the executable was built and the libpcap with which it's run, so we avoid using it for now. svn path=/trunk/; revision=40138
2011-10-30From Kevin Hildebrand:Anders Broman1-1/+2
Typo in acinclude.m4 breaks Heimdal kerberos builds https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6512 svn path=/trunk/; revision=39677
2011-10-05Add GeoIP IPv6 database support. Tested with GeoIP 1.4.7, but olderGerald Combs1-0/+7
versions *should* be supported. svn path=/trunk/; revision=39280
2011-08-23Remove support for libpcre, we use GRegex in GLib.Stig Bjørlykke1-106/+0
svn path=/trunk/; revision=38683
2011-08-09Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5607 :Jeff Morriss1-1/+1
When testing if we can add things to LDFLAGS, don't set LDFLAGS to CFLAGS if the test determines that the flag cannot be added to LDFLAGS. (Simple typo: LDFLAGS_saved was being set to CFLAGS instead of LDFLAGS.) svn path=/trunk/; revision=38434
2011-06-11Use spaces uniformly in AC_WIRESHARK_PYTHON_CHECK.Guy Harris1-18/+23
If we don't find python-config, set want_python to no, so the end-of-configuration message says we're not using the Python interpreter. Also fix some cases where we were setting want_zlib rather than want_python (cut-and-pasteo). svn path=/trunk/; revision=37654
2011-06-11Do the Python embedding similarly to other "default = yes, if available"Guy Harris1-0/+5
items. Add some quoting to the zlib tests, just in case the argument contains white space. Clean up capitalization of Lua and Python. Link programs that use libwireshark with the Python libraries, and build Epan with the Python cflags. svn path=/trunk/; revision=37652
2011-05-03Don't bother checking for gzgets(), as we don't use it, and don't evenGuy Harris1-80/+54
need to use its presence in zlib as a proxy for "not the crufty old zlib that comes with some versions of X11". Do, however, check for inflatePrime() there, instead, just in case the crufty old zlib that comes with some versions of X11 lack it; this is to prevent the configure script from assuming a shiny new zlib by testing with a non-X11 program, causing the build to fail when you build Wireshark. svn path=/trunk/; revision=36969
2011-04-28After testing for the presence of python-config, fix typo so that we actuallyJeff Morriss1-4/+20
test whether we found it or not. If the user asked for Python support, error out if we find we can't use it. svn path=/trunk/; revision=36924
2011-04-20By default, clang only warns about unknown -W options, it doesn'tGuy Harris1-0/+9
generate an error for them. Force them to be treated as errors, so we correctly test whether an option is supported. svn path=/trunk/; revision=36732
2011-04-20Instead of having GCC and CLANG variables, just haveGuy Harris1-14/+16
ac_supports_gcc_flags and ac_supports_W_linker_passthrough flags, the first of which, for now, we set for GCC and clang, and the latter of which we set for GCC, clang, and xlc (probably true for some other compilers as well). Rename AC_WIRESHARK_GCC_LDFLAGS_CHECK to AC_WIRESHARK_LDFLAGS_CHECK, as it's not checking for anything GCC-specific. (Leave AC_WIRESHARK_GCC_CFLAGS_CHECK unrenamed for now, as the flags we test with it are originally GCC flags that clang also supports for GCC compatibility.) Fix some string-equality tests to use = rather than ==; the former is what the test/[ command uses. Don't turn on "-no-cpp-precomp" for clang - it whines if you do. svn path=/trunk/; revision=36731
2011-04-20First cut at support for clang. We may want to have specific items forGuy Harris1-4/+6
"supports GCC-style -W flags", etc., and may want to improve the check for "is this clang", as well as deciding what other stuff should be done if we have clang as well. clang should, I think, largely be gcc-compatible at the command line. svn path=/trunk/; revision=36729
2010-07-13Add a "-d" flag to dumpcap, to print out the generated code for theGuy Harris1-1/+1
capture filter in human-readable form. (Well, readable by humans who know BPF machine language, at least. :-)) svn path=/trunk/; revision=33509
2010-06-05First check for the new GTK+/OS X integration functions, then the oldGuy Harris1-14/+16
ones; it appears that at least one user's -ligemacintegration has both (see bug 4823), and we should choose the new ones in that case. Also, always set have_ige_mac if we have the functions. Fix tpyoes while we're at it. svn path=/trunk/; revision=33106
2010-05-25From H.sivank: GtkOSXApplication support.Guy Harris1-3/+34
Call the various flavors of OS X integration just "OS X integration", not anything with "IGE" in it - it appears that, in some places, "ige-mac-integration" refers only to the older Carbon-based functions, although the library still appears to be called -ligemacintegration. Update the URLs for the information about the OS X integration libraries. Clean up help message for --with-pcap-remote. Clean up white space a bit. Speaking of white space, it's "Mac OS X", not "MacOS X". svn path=/trunk/; revision=32941