3 # Patch managed by http://www.holgerschurig.de/patcher.html
7 +++ nmap-3.77/acinclude.m4
9 +dnl Type of 6th argument to recvfrom(). Usually int or socklen_t.
10 +AC_DEFUN([RECVFROM_ARG6_TYPE],
13 + AC_MSG_CHECKING([for type of 6th argument to recvfrom()])
15 + for t in socklen_t int; do
19 +#include <sys/types.h>
20 +#include <sys/socket.h>],[
22 +recvfrom (0, NULL, 0, 0, NULL, &arg);],[
27 + if test "x$recvfrom6_t" = x; then
28 + AC_MSG_ERROR([Cannot find type for 6th argument to recvfrom()])
31 + AC_MSG_RESULT($recvfrom6_t)
32 + AC_DEFINE_UNQUOTED(recvfrom6_t, $recvfrom6_t,
33 + [Type of 6th argument to recvfrom()])
36 --- nmap-3.77/configure.ac~autofoo.patch
37 +++ nmap-3.77/configure.ac
39 if test -n "$GXX"; then
40 CXXFLAGS="$CXXFLAGS -Wall "
42 -AC_CHECK_PROG(CXXPROG, "$CXX", "AVAILABLE", "MISSING")
43 -if test $CXXPROG = "MISSING"; then
44 - AC_MSG_ERROR([Could not locate a C++ compiler. If it exists, add it to your PATH or give configure the CXX=path_to_compiler argument. Otherwise, install a C++ compiler such as g++ or install a binary package of Nmap (see http://www.insecure.org/nmap/nmap_download.html ))])
48 dnl AC_PATH_PROG(MAKEDEPEND, makedepend)
50 dnl equiv to '#define inline' to 'inline', '__inline__', '__inline' or ''
52 if test -n "$sgi_cc"; then
54 + AC_DEFINE(inline, , [Define if we need to declare our own inline])
62 +AH_TEMPLATE([NETBSD], [Define if building for a netbsd host])
63 +AH_TEMPLATE([LINUX], [Define if building for a linux host])
64 +AH_TEMPLATE([OPENBSD], [Define if building for an openbsd host])
65 +AH_TEMPLATE([SOLARIS], [Define if building for a solaris host])
66 +AH_TEMPLATE([IRIX], [Define if building for an irix host])
67 +AH_TEMPLATE([BSDI], [Define if building for a bsdi host])
68 +AH_TEMPLATE([FREEBSD], [Define if building for a freebsd host])
69 +AH_TEMPLATE([SUNOS], [Define if building for a sunos host])
70 +AH_TEMPLATE([MACOSX], [Define if building for a macosx host])
71 +AH_TEMPLATE([DEC], [Define if building for a digital unix host])
72 +AH_TEMPLATE([SPRINTF_RETURNS_STRING], [Define if sprintf() returns char *])
73 +AH_TEMPLATE([STUPID_SOLARIS_CHECKSUM_BUG], [Define to handle the solaris checksum bug])
74 +AH_TEMPLATE([PCAP_TIMEOUT_IGNORED], [Does the pcap library obey the timeout])
81 if test "$use_openssl" = "yes"; then
82 - AC_DEFINE(HAVE_OPENSSL)
83 + AC_DEFINE(HAVE_OPENSSL, 1, [Define this if we have openssl])
84 OPENSSL_LIBS="-lssl -lcrypto"
91 -if test $linux = yes; then
94 +# If I say I have pcap, damnit, I mean it, even if I am using linux. --CL
96 +# if test $linux = yes; then
100 if test $needs_cpp_precomp = yes; then
101 CXXFLAGS="-no-cpp-precomp $CXXFLAGS"
104 [AC_MSG_RESULT(yes); have_libpcap=yes],
105 [AC_MSG_RESULT(no); have_libpcap=no],
106 -[AC_MSG_RESULT(no); have_libpcap=no])
107 +[AC_MSG_RESULT(crosscompiling, assuming yes); have_libpcap=yes])
115 - AC_DEFINE(HAVE_LIBPCAP)
116 + AC_DEFINE(HAVE_LIBPCAP, 1, [Define if we have libpcap])
118 if test "${LIBPCAP_INC+set}" = "set"; then
119 LDFLAGS="-L$libpcapdir $_ldflags"
121 [AC_MSG_RESULT(no); bsd_networking=no]);
122 if test $bsd_networking = yes; then
124 - AC_DEFINE(BSD_NETWORKING)
125 + AC_DEFINE(BSD_NETWORKING, 1, [Define if we have bsd networking])
126 AC_MSG_CHECKING([ip_v in struct ip])
127 AC_TRY_COMPILE([#include <sys/types.h>
128 #include <netinet/in.h>
129 @@ -501,13 +512,14 @@
130 ac_cv_sockaddr_has_sa_len=yes,
131 ac_cv_sockaddr_has_sa_len=no))
132 if test $ac_cv_sockaddr_has_sa_len = yes ; then
133 - AC_DEFINE(HAVE_SOCKADDR_SA_LEN)
134 + AC_DEFINE(HAVE_SOCKADDR_SA_LEN, 1, [Define if sockaddr has a sa_len member])
140 AC_MSG_CHECKING([if struct in_addr is a wacky huge structure (some Sun boxes)])
141 +AH_TEMPLATE([IN_ADDR_DEEPSTRUCT], [Define if struct in_addr is a wacky huge structure])
143 AC_TRY_COMPILE([#include <netinet/in.h>], struct in_addr i; i._S_un._S_addr;, \
144 AC_DEFINE(IN_ADDR_DEEPSTRUCT) \
146 ac_cv_struct_icmp_exists=yes,
147 ac_cv_struct_icmp_exists=no))
148 if test $ac_cv_struct_icmp_exists = yes ; then
149 - AC_DEFINE(HAVE_STRUCT_ICMP)
150 + AC_DEFINE(HAVE_STRUCT_ICMP, 1, [Define if struct icmp exists])
153 AC_CACHE_CHECK(if struct ip exists, ac_cv_struct_ip_exists,
155 ac_cv_struct_ip_exists=yes,
156 ac_cv_struct_ip_exists=no))
157 if test $ac_cv_struct_ip_exists = yes ; then
158 - AC_DEFINE(HAVE_STRUCT_IP)
159 + AC_DEFINE(HAVE_STRUCT_IP, 1, [Define if struct ip exists])
162 AC_CACHE_CHECK(if struct ip has ip_sum member, ac_cv_ip_has_ip_sum,
164 ac_cv_ip_has_ip_sum=yes,
165 ac_cv_ip_has_ip_sum=no))
166 if test $ac_cv_ip_has_ip_sum = yes ; then
167 - AC_DEFINE(HAVE_IP_IP_SUM)
168 + AC_DEFINE(HAVE_IP_IP_SUM, 1, [Define if struct ip has ip_sum member])
173 extern "C" int usleep (unsigned int);],[
176 - AC_DEFINE(NEED_USLEEP_PROTO)],
177 + AC_DEFINE(NEED_USLEEP_PROTO, 1, [Define if we need a usleep prototype])],
178 AC_MSG_RESULT(not found))])
183 gethostname (buffer, 200);],[
185 - AC_DEFINE(NEED_GETHOSTNAME_PROTO)],
186 + AC_DEFINE(NEED_GETHOSTNAME_PROTO, 1, [Define if we need a gethostname prototype])],
187 AC_MSG_RESULT(not found))])
192 dnl AC_CHECK_FUNCS(gethostname gettimeofday select socket strdup strstr )
195 +use_included_nbase=no
196 AC_ARG_WITH(libnbase,
197 [ --with-libnbase=DIR Look for nbase include/libs in DIR],
198 [ case "$with_libnbase" in
200 NBASEDIR="$with_libnbase"
204 + use_included_nbase=yes
207 LDFLAGS="$LDFLAGS -L$NBASEDIR"
210 AC_SUBST(LIBNBASE_LIBS)
212 +use_included_nsock=no
214 AC_ARG_WITH(libnsock,
215 [ --with-libnsock=DIR Compile and link to libnsock in DIR],
218 NSOCKDIR="$with_nsock"
222 + use_included_nsock=yes
225 LDFLAGS="$LDFLAGS -L$NSOCKDIR/src/"
226 @@ -653,20 +669,11 @@
228 AC_SUBST(LIBNSOCK_LIBS)
230 -nmap_cfg_subdirs="$nmap_cfg_subdirs $NSOCKDIR/src"
232 dnl I need to configure nmapfe and libpcap here since the user might
233 dnl have specified special options (such as --prefix )
235 dnl But I only have to configure libpcap if I am going to use it
237 -if test $have_libpcap = yes ; then
238 - nmap_cfg_subdirs="$NBASEDIR $nmap_cfg_subdirs"
240 - nmap_cfg_subdirs="$NBASEDIR $libpcapdir $nmap_cfg_subdirs"
244 if test "${with_nmapfe}" = "yes"; then
246 AC_PATH_PROG(GTK_CONFIG, gtk-config, no)
248 You need at least version $GTK_MINVERSION.\n Subdir X-windows \
251 - nmap_cfg_subdirs="$nmap_cfg_subdirs nmapfe"
252 + AC_CONFIG_SUBDIRS(nmapfe)
253 dnl Maybe also define the flags to compile and link GTK+
254 dnl GTK_CXXFLAGS=`gtk-config --cflags`
255 dnl GTK_LIBS=`gtk-config --libs`
259 dnl all hell broke loose when the variable was named $subdirs
260 -AC_CONFIG_SUBDIRS( $nmap_cfg_subdirs )
261 +if test $have_libpcap != yes ; then
262 + AC_CONFIG_SUBDIRS(libpcap-possiblymodified)
265 +if test "$use_included_nbase" = yes; then
266 + AC_CONFIG_SUBDIRS(nbase)
269 +if test "$use_included_nsock" = "yes"; then
270 + AC_CONFIG_SUBDIRS(nsock/src)
273 dnl Configure libpcap if we need to since a lot of lamers don't
274 dnl already have it installed ...
276 +++ nmap-3.77/nbase/acinclude.m4
278 +dnl -----------------------------------------------------------------
279 +dnl Nbase local macros
280 +dnl $Id: configlocal.m4,v 1.3 2002/09/08 22:56:01 fyodor Exp $
281 +dnl -----------------------------------------------------------------
284 +dnl check for working getaddrinfo(). This check is from
287 +dnl Note that if the system doesn't have gai_strerror(), we
288 +dnl can't use getaddrinfo() because we can't get strings
289 +dnl describing the error codes.
291 +AC_DEFUN([APR_CHECK_WORKING_GETADDRINFO], [
292 + AC_CACHE_CHECK(for working getaddrinfo, ac_cv_working_getaddrinfo,[
297 +#ifdef HAVE_STRING_H
300 +#ifdef HAVE_SYS_TYPES_H
301 +#include <sys/types.h>
303 +#ifdef HAVE_SYS_SOCKET_H
304 +#include <sys/socket.h>
308 + struct addrinfo hints, *ai;
311 + memset(&hints, 0, sizeof(hints));
312 + hints.ai_family = AF_UNSPEC;
313 + hints.ai_socktype = SOCK_STREAM;
314 + error = getaddrinfo("127.0.0.1", NULL, &hints, &ai);
318 + if (ai->ai_addr->sa_family != AF_INET) {
324 + ac_cv_working_getaddrinfo="yes"
326 + ac_cv_working_getaddrinfo="no"
328 + ac_cv_working_getaddrinfo="yes"
330 +if test "$ac_cv_working_getaddrinfo" = "yes"; then
331 + if test "$ac_cv_func_gai_strerror" != "yes"; then
332 + ac_cv_working_getaddrinfo="no"
334 + AC_DEFINE(HAVE_GETADDRINFO, 1, [Define if getaddrinfo exists and works well enough for APR])
340 +dnl check for working getnameinfo() -- from Apache 2.0.40
342 +AC_DEFUN([APR_CHECK_WORKING_GETNAMEINFO],[
343 + AC_CACHE_CHECK(for working getnameinfo, ac_cv_working_getnameinfo,[
348 +#ifdef HAVE_STRING_H
351 +#ifdef HAVE_SYS_TYPES_H
352 +#include <sys/types.h>
354 +#ifdef HAVE_SYS_SOCKET_H
355 +#include <sys/socket.h>
357 +#ifdef HAVE_NETINET_IN_H
358 +#include <netinet/in.h>
362 + struct sockaddr_in sa;
366 + sa.sin_family = AF_INET;
368 + sa.sin_addr.s_addr = inet_addr("127.0.0.1");
370 + sa.sin_len = sizeof(sa);
373 + error = getnameinfo((const struct sockaddr *)&sa, sizeof(sa),
374 + hbuf, 256, NULL, 0,
383 + ac_cv_working_getnameinfo="yes"
385 + ac_cv_working_getnameinfo="no"
387 + ac_cv_working_getnameinfo="yes"
389 +if test "$ac_cv_working_getnameinfo" = "yes"; then
390 + AC_DEFINE(HAVE_GETNAMEINFO, 1, [Define if getnameinfo exists])
394 +AC_DEFUN([APR_CHECK_SOCKADDR_IN6],[
395 +AC_CACHE_CHECK(for sockaddr_in6, ac_cv_define_sockaddr_in6,[
397 +#ifdef HAVE_SYS_TYPES_H
398 +#include <sys/types.h>
400 +#ifdef HAVE_NETINET_IN_H
401 +#include <netinet/in.h>
404 +struct sockaddr_in6 sa;
406 + ac_cv_define_sockaddr_in6=yes
408 + ac_cv_define_sockaddr_in6=no
412 +if test "$ac_cv_define_sockaddr_in6" = "yes"; then
413 + have_sockaddr_in6=1
414 + AC_DEFINE(HAVE_SOCKADDR_IN6, 1, [Define if we have sockaddr_in6])
416 + have_sockaddr_in6=0
420 +AC_DEFUN([CHECK_AF_INET6_DEFINE],[
421 +AC_CACHE_CHECK(for AF_INET6 definition, ac_cv_define_af_inet6,[
423 +#ifdef HAVE_SYS_TYPES_H
424 +#include <sys/types.h>
426 +#ifdef HAVE_NETINET_IN_H
427 +#include <netinet/in.h>
429 +#ifdef HAVE_SYS_SOCKET_H
430 +#include <sys/socket.h>
435 + ac_cv_define_af_inet6=yes
437 + ac_cv_define_af_inet6=no
441 +if test "$ac_cv_define_af_inet6" = "yes"; then
443 + AC_DEFINE(HAVE_AF_INET6, 1, [Define if we have AF_INET6])
449 +AC_DEFUN([APR_CHECK_SOCKADDR_STORAGE],[
450 +AC_CACHE_CHECK(for sockaddr_storage, ac_cv_define_sockaddr_storage,[
452 +#ifdef HAVE_SYS_TYPES_H
453 +#include <sys/types.h>
455 +#ifdef HAVE_SYS_SOCKET_H
456 +#include <sys/socket.h>
458 +#ifdef HAVE_NETINET_IN_H
459 +#include <netinet/in.h>
462 +struct sockaddr_storage sa;
464 + ac_cv_define_sockaddr_storage=yes
466 + ac_cv_define_sockaddr_storage=no
470 +if test "$ac_cv_define_sockaddr_storage" = "yes"; then
471 + have_sockaddr_storage=1
472 + AC_DEFINE(HAVE_SOCKADDR_STORAGE, 1, [Define if we have struct sockaddr_storage])
474 + have_sockaddr_storage=0
478 +AC_DEFUN([AC_C___ATTRIBUTE__], [
479 +AC_MSG_CHECKING(for __attribute__)
480 +AC_CACHE_VAL(ac_cv___attribute__, [
485 +static void foo(void) __attribute__ ((noreturn));
493 +ac_cv___attribute__=yes,
494 +ac_cv___attribute__=no)])
495 +if test "$ac_cv___attribute__" = "yes"; then
496 + AC_DEFINE(HAVE___ATTRIBUTE__, 1, [define if your compiler has __attribute__])
498 +AC_MSG_RESULT($ac_cv___attribute__)
501 --- nmap-3.77/nbase/configure.ac~autofoo.patch
502 +++ nmap-3.77/nbase/configure.ac
504 # Require autoconf 2.13
507 -# Include my own macros
508 -sinclude(configlocal.m4)
512 AC_ARG_WITH(localdirs,
515 dnl use config.h instad of -D macros
516 AC_CONFIG_HEADER(nbase_config.h)
517 +AC_CONFIG_AUX_DIR(..)
519 dnl Checks for programs.
524 dnl AC_PATH_PROG(MAKEDEPEND, makedepend)
525 +AC_PATH_PROG(RANLIB, ranlib)
527 AC_SUBST(COMPAT_OBJS)
528 AC_SUBST(COMPAT_SRCS)
533 +AH_TEMPLATE([NETBSD], [Define if building for a netbsd host])
534 +AH_TEMPLATE([LINUX], [Define if building for a linux host])
535 +AH_TEMPLATE([OPENBSD], [Define if building for an openbsd host])
536 +AH_TEMPLATE([SOLARIS], [Define if building for a solaris host])
537 +AH_TEMPLATE([IRIX], [Define if building for an irix host])
538 +AH_TEMPLATE([BSDI], [Define if building for a bsdi host])
539 +AH_TEMPLATE([FREEBSD], [Define if building for a freebsd host])
540 +AH_TEMPLATE([SUNOS], [Define if building for a sunos host])
541 +AH_TEMPLATE([SPRINTF_RETURNS_STRING], [Define if sprintf() returns char *])
542 +AH_TEMPLATE([STUPID_SOLARIS_CHECKSUM_BUG], [Define to handle the solaris checksum bug])
543 +AH_TEMPLATE([PCAP_TIMEOUT_IGNORED], [Does the pcap library obey the timeout])
545 *-netbsd* | *-knetbsd*-gnu)
548 dnl equiv to '#define inline' to 'inline', '__inline__', '__inline' or ''
550 if test -n "$sgi_cc"; then
551 - AC_DEFINE(inline, )
552 + AC_DEFINE(inline, ,[Define this if we need to define inline ourselves])
559 if test "$use_openssl" = "yes"; then
560 - AC_DEFINE(HAVE_OPENSSL)
561 + AC_DEFINE(HAVE_OPENSSL, 1, [Define this if we have openssl])
568 if test "$have_ipv6" = "1"; then
569 - AC_DEFINE(HAVE_IPV6)
570 + AC_DEFINE(HAVE_IPV6, 1, [Define this if we have ipv6 support])
576 +++ nmap-3.77/nmapfe/m4/gtk.m4
578 +# Configure paths for GTK+
579 +# Owen Taylor 97-11-3
581 +dnl AM_PATH_GTK([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND [, MODULES]]]])
582 +dnl Test for GTK, and define GTK_CFLAGS and GTK_LIBS
584 +AC_DEFUN(AM_PATH_GTK,
586 +dnl Get the cflags and libraries from the gtk-config script
588 +AC_ARG_WITH(gtk-prefix,[ --with-gtk-prefix=PFX Prefix where GTK is installed (optional)],
589 + gtk_config_prefix="$withval", gtk_config_prefix="")
590 +AC_ARG_WITH(gtk-exec-prefix,[ --with-gtk-exec-prefix=PFX Exec prefix where GTK is installed (optional)],
591 + gtk_config_exec_prefix="$withval", gtk_config_exec_prefix="")
592 +AC_ARG_ENABLE(gtktest, [ --disable-gtktest Do not try to compile and run a test GTK program],
593 + , enable_gtktest=yes)
599 + gtk_config_args="$gtk_config_args gthread"
604 + if test x$gtk_config_exec_prefix != x ; then
605 + gtk_config_args="$gtk_config_args --exec-prefix=$gtk_config_exec_prefix"
606 + if test x${GTK_CONFIG+set} != xset ; then
607 + GTK_CONFIG=$gtk_config_exec_prefix/bin/gtk-config
610 + if test x$gtk_config_prefix != x ; then
611 + gtk_config_args="$gtk_config_args --prefix=$gtk_config_prefix"
612 + if test x${GTK_CONFIG+set} != xset ; then
613 + GTK_CONFIG=$gtk_config_prefix/bin/gtk-config
617 + AC_PATH_PROG(GTK_CONFIG, gtk-config, no)
618 + min_gtk_version=ifelse([$1], ,0.99.7,$1)
619 + AC_MSG_CHECKING(for GTK - version >= $min_gtk_version)
621 + if test "$GTK_CONFIG" = "no" ; then
624 + GTK_CFLAGS=`$GTK_CONFIG $gtk_config_args --cflags`
625 + GTK_LIBS=`$GTK_CONFIG $gtk_config_args --libs`
626 + gtk_config_major_version=`$GTK_CONFIG $gtk_config_args --version | \
627 + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'`
628 + gtk_config_minor_version=`$GTK_CONFIG $gtk_config_args --version | \
629 + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'`
630 + gtk_config_micro_version=`$GTK_CONFIG $gtk_config_args --version | \
631 + sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'`
632 + if test "x$enable_gtktest" = "xyes" ; then
633 + ac_save_CFLAGS="$CFLAGS"
634 + ac_save_LIBS="$LIBS"
635 + CFLAGS="$CFLAGS $GTK_CFLAGS"
636 + LIBS="$GTK_LIBS $LIBS"
638 +dnl Now check if the installed GTK is sufficiently new. (Also sanity
639 +dnl checks the results of gtk-config to some extent
643 +#include <gtk/gtk.h>
650 + int major, minor, micro;
653 + system ("touch conf.gtktest");
655 + /* HP/UX 9 (%@#!) writes to sscanf strings */
656 + tmp_version = g_strdup("$min_gtk_version");
657 + if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) {
658 + printf("%s, bad version string\n", "$min_gtk_version");
662 + if ((gtk_major_version != $gtk_config_major_version) ||
663 + (gtk_minor_version != $gtk_config_minor_version) ||
664 + (gtk_micro_version != $gtk_config_micro_version))
666 + printf("\n*** 'gtk-config --version' returned %d.%d.%d, but GTK+ (%d.%d.%d)\n",
667 + $gtk_config_major_version, $gtk_config_minor_version, $gtk_config_micro_version,
668 + gtk_major_version, gtk_minor_version, gtk_micro_version);
669 + printf ("*** was found! If gtk-config was correct, then it is best\n");
670 + printf ("*** to remove the old version of GTK+. You may also be able to fix the error\n");
671 + printf("*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing\n");
672 + printf("*** /etc/ld.so.conf. Make sure you have run ldconfig if that is\n");
673 + printf("*** required on your system.\n");
674 + printf("*** If gtk-config was wrong, set the environment variable GTK_CONFIG\n");
675 + printf("*** to point to the correct copy of gtk-config, and remove the file config.cache\n");
676 + printf("*** before re-running configure\n");
678 +#if defined (GTK_MAJOR_VERSION) && defined (GTK_MINOR_VERSION) && defined (GTK_MICRO_VERSION)
679 + else if ((gtk_major_version != GTK_MAJOR_VERSION) ||
680 + (gtk_minor_version != GTK_MINOR_VERSION) ||
681 + (gtk_micro_version != GTK_MICRO_VERSION))
683 + printf("*** GTK+ header files (version %d.%d.%d) do not match\n",
684 + GTK_MAJOR_VERSION, GTK_MINOR_VERSION, GTK_MICRO_VERSION);
685 + printf("*** library (version %d.%d.%d)\n",
686 + gtk_major_version, gtk_minor_version, gtk_micro_version);
688 +#endif /* defined (GTK_MAJOR_VERSION) ... */
691 + if ((gtk_major_version > major) ||
692 + ((gtk_major_version == major) && (gtk_minor_version > minor)) ||
693 + ((gtk_major_version == major) && (gtk_minor_version == minor) && (gtk_micro_version >= micro)))
699 + printf("\n*** An old version of GTK+ (%d.%d.%d) was found.\n",
700 + gtk_major_version, gtk_minor_version, gtk_micro_version);
701 + printf("*** You need a version of GTK+ newer than %d.%d.%d. The latest version of\n",
702 + major, minor, micro);
703 + printf("*** GTK+ is always available from ftp://ftp.gtk.org.\n");
705 + printf("*** If you have already installed a sufficiently new version, this error\n");
706 + printf("*** probably means that the wrong copy of the gtk-config shell script is\n");
707 + printf("*** being found. The easiest way to fix this is to remove the old version\n");
708 + printf("*** of GTK+, but you can also set the GTK_CONFIG environment to point to the\n");
709 + printf("*** correct copy of gtk-config. (In this case, you will have to\n");
710 + printf("*** modify your LD_LIBRARY_PATH enviroment variable, or edit /etc/ld.so.conf\n");
711 + printf("*** so that the correct libraries are found at run-time))\n");
716 +],, no_gtk=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
717 + CFLAGS="$ac_save_CFLAGS"
718 + LIBS="$ac_save_LIBS"
721 + if test "x$no_gtk" = x ; then
723 + ifelse([$2], , :, [$2])
726 + if test "$GTK_CONFIG" = "no" ; then
727 + echo "*** The gtk-config script installed by GTK could not be found"
728 + echo "*** If GTK was installed in PREFIX, make sure PREFIX/bin is in"
729 + echo "*** your path, or set the GTK_CONFIG environment variable to the"
730 + echo "*** full path to gtk-config."
732 + if test -f conf.gtktest ; then
735 + echo "*** Could not run GTK test program, checking why..."
736 + CFLAGS="$CFLAGS $GTK_CFLAGS"
737 + LIBS="$LIBS $GTK_LIBS"
739 +#include <gtk/gtk.h>
741 +], [ return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version)); ],
742 + [ echo "*** The test program compiled, but did not run. This usually means"
743 + echo "*** that the run-time linker is not finding GTK or finding the wrong"
744 + echo "*** version of GTK. If it is not finding GTK, you'll need to set your"
745 + echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
746 + echo "*** to the installed location Also, make sure you have run ldconfig if that"
747 + echo "*** is required on your system"
749 + echo "*** If you have an old version installed, it is best to remove it, although"
750 + echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
752 + echo "*** If you have a RedHat 5.0 system, you should remove the GTK package that"
753 + echo "*** came with the system with the command"
755 + echo "*** rpm --erase --nodeps gtk gtk-devel" ],
756 + [ echo "*** The test program failed to compile or link. See the file config.log for the"
757 + echo "*** exact error that occured. This usually means GTK was incorrectly installed"
758 + echo "*** or that you have moved GTK since it was installed. In the latter case, you"
759 + echo "*** may want to edit the gtk-config script: $GTK_CONFIG" ])
760 + CFLAGS="$ac_save_CFLAGS"
761 + LIBS="$ac_save_LIBS"
766 + ifelse([$3], , :, [$3])
768 + AC_SUBST(GTK_CFLAGS)
772 --- nmap-3.77/nsock/src/configure.ac~autofoo.patch
773 +++ nmap-3.77/nsock/src/configure.ac
777 if test "$use_openssl" = "yes"; then
778 - AC_DEFINE(HAVE_OPENSSL)
779 + AC_DEFINE(HAVE_OPENSSL, 1, [Define this if we have openssl])
784 [AC_MSG_RESULT(no); bsd_networking=no]);
785 if test $bsd_networking = yes; then
787 - AC_DEFINE(BSD_NETWORKING)
788 + AC_DEFINE(BSD_NETWORKING, 1, [Define if we have bsd networking])
789 AC_MSG_CHECKING([ip_v in struct ip])
790 AC_TRY_COMPILE([#include <sys/types.h>
791 #include <netinet/in.h>
793 ac_cv_sockaddr_has_sa_len=yes,
794 ac_cv_sockaddr_has_sa_len=no))
795 if test $ac_cv_sockaddr_has_sa_len = yes ; then
796 - AC_DEFINE(HAVE_SOCKADDR_SA_LEN)
797 + AC_DEFINE(HAVE_SOCKADDR_SA_LEN, 1, [Define if sockaddr has a sa_len member])
800 AC_CACHE_CHECK(if struct icmp exists, ac_cv_struct_icmp_exists,
802 ac_cv_struct_icmp_exists=yes,
803 ac_cv_struct_icmp_exists=no))
804 if test $ac_cv_struct_icmp_exists = yes ; then
805 - AC_DEFINE(HAVE_STRUCT_ICMP)
806 + AC_DEFINE(HAVE_STRUCT_ICMP, 1, [Define if struct icmp exists])
809 AC_CACHE_CHECK(if struct ip exists, ac_cv_struct_ip_exists,
811 ac_cv_struct_ip_exists=yes,
812 ac_cv_struct_ip_exists=no))
813 if test $ac_cv_struct_ip_exists = yes ; then
814 - AC_DEFINE(HAVE_STRUCT_IP)
815 + AC_DEFINE(HAVE_STRUCT_IP, 1, [Define if struct ip exists])
818 AC_CACHE_CHECK(if struct ip has ip_sum member, ac_cv_ip_has_ip_sum,
820 ac_cv_ip_has_ip_sum=yes,
821 ac_cv_ip_has_ip_sum=no))
822 if test $ac_cv_ip_has_ip_sum = yes ; then
823 - AC_DEFINE(HAVE_IP_IP_SUM)
824 + AC_DEFINE(HAVE_IP_IP_SUM, 1, [Define if struct ip has ip_sum member])