X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=configure.ac;h=d2a6939b33b34d4bf40eb6176d1db0fe76dc9c8e;hb=aaa3fa556962845e925dbe5dabc8987584422734;hp=c12b2f4142b28434e29178e1da18f3fd68a723e7;hpb=af1933bbcbdf53ddca24012832c0ba32fe712fdc;p=oweals%2Fgnunet.git diff --git a/configure.ac b/configure.ac index c12b2f414..d2a6939b3 100644 --- a/configure.ac +++ b/configure.ac @@ -22,13 +22,13 @@ # AC_PREREQ(2.61) # Checks for programs. -AC_INIT([gnunet], [0.9.0pre4],[bug-gnunet@gnu.org]) +AC_INIT([gnunet], [0.9.1],[bug-gnunet@gnu.org]) AC_CANONICAL_TARGET AC_CANONICAL_HOST AC_CANONICAL_SYSTEM -AM_INIT_AUTOMAKE([gnunet], [0.9.0pre4]) +AM_INIT_AUTOMAKE([gnunet], [0.9.1]) m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) AC_CONFIG_HEADERS([gnunet_config.h]) AH_TOP([#define _GNU_SOURCE 1]) @@ -141,8 +141,8 @@ netbsd*) AC_DEFINE_UNQUOTED(WINDOWS,1,[This is a Windows system]) AC_DEFINE_UNQUOTED(_WIN32,1,[This is a Windows system]) AC_CHECK_LIB(intl, gettext) - LDFLAGS="$LDFLAGS -no-undefined -Wl,--export-all-symbols" - LIBS="$LIBS -lws2_32 -lplibc" + LDFLAGS="$LDFLAGS -Wl,-no-undefined -Wl,--export-all-symbols" + LIBS="$LIBS -lws2_32 -lplibc -lgnurx -lole32" CFLAGS="-mms-bitfields $CFLAGS" CPPFLAGS="-D_WIN32_WINNT=0x0501 $CPPFLAGS" build_target="mingw" @@ -183,6 +183,14 @@ AC_CHECK_LIB(c, getloadavg, AC_DEFINE(HAVE_GETLOADAVG,1,[getloadavg supported])) # will be more selective! SAVE_LIBS=$LIBS +# libgnurx (regex library for W32) +gnurx=0 +AC_CHECK_LIB(gnurx, regexec, gnurx=1) +if test "x$gnurx" = "x0" -a "x$build_target" = "xmingw" +then + AC_MSG_ERROR([on W32 GNUnet needs libgnurx]) +fi + # libgcrypt gcrypt=0 AM_PATH_LIBGCRYPT(1.2.0, gcrypt=1) @@ -193,6 +201,27 @@ then AC_MSG_ERROR([GNUnet needs libgcrypt]) fi +# Adam shostack suggests the following for Windows: +# -D_FORTIFY_SOURCE=2 -fstack-protector-all +AC_ARG_ENABLE(gcc-hardening, + AS_HELP_STRING(--enable-gcc-hardening, enable compiler security checks), +[if test x$enableval = xyes; then + CFLAGS="$CFLAGS -D_FORTIFY_SOURCE=2 -fstack-protector-all" + CFLAGS="$CFLAGS -fwrapv -fPIE -Wstack-protector" + CFLAGS="$CFLAGS --param ssp-buffer-size=1" + LDFLAGS="$LDFLAGS -pie" +fi]) + + +# Linker hardening options +# Currently these options are ELF specific - you can't use this with MacOSX +AC_ARG_ENABLE(linker-hardening, + AS_HELP_STRING(--enable-linker-hardening, enable linker security fixups), +[if test x$enableval = xyes; then + LDFLAGS="$LDFLAGS -z relro -z now" +fi]) + + extra_logging=GNUNET_NO AC_ARG_ENABLE([logging], AS_HELP_STRING([--enable-logging@<:@=value@:>@],[Enable logging calls. Possible values: yes,no,verbose,veryverbose ('yes' is the default)]), @@ -339,6 +368,18 @@ fi # restore LIBS LIBS=$SAVE_LIBS +# test for libunistring +gl_LIBUNISTRING +if test $HAVE_LIBUNISTRING != yes; then + AC_MSG_ERROR([GNUnet requires libunistring]) +fi +if test $gl_libunistring_hexversion -le 2305; then + AC_MSG_ERROR([GNUnet requires libunistring >= 0.9.1.1]) +fi +# restore LIBS +LIBS=$SAVE_LIBS + + # Checks for standard header files. AC_HEADER_DIRENT @@ -554,7 +595,7 @@ AC_DEFINE_UNQUOTED([HAVE_MHD], $lmhd, [We have libmicrohttpd]) LIBS=$SAVE_LIBS # check for python & pexpect (used for some testcases only) -AM_PATH_PYTHON([2.5],, [:]) +AM_PATH_PYTHON([2.6],, [:]) AM_CONDITIONAL([HAVE_PYTHON], [test "$PYTHON" != :]) if test "$PYTHON" != : @@ -605,7 +646,6 @@ AC_CHECK_MEMBER([struct sockaddr_in.sin_len], # Checks for library functions. AC_FUNC_CLOSEDIR_VOID AC_FUNC_FORK -AC_FUNC_VFORK AC_PROG_GCC_TRADITIONAL AC_FUNC_MEMCMP AC_FUNC_SELECT_ARGTYPES @@ -618,7 +658,7 @@ AC_FUNC_VPRINTF AC_HEADER_SYS_WAIT AC_TYPE_OFF_T AC_TYPE_UID_T -AC_CHECK_FUNCS([floor gethostname memmove rmdir strncasecmp strrchr strtol atoll dup2 fdatasync ftruncate gettimeofday memset mkdir mkfifo select socket strcasecmp strchr strdup strerror strstr clock_gettime getrusage rand uname setlocale getcwd mktime gmtime_r gmtime strlcpy strlcat ftruncate stat64 sbrk mmap mremap setrlimit sysconf gethostbyaddr initgroups getifaddrs freeifaddrs getnameinfo getaddrinfo inet_ntoa localtime_r nl_langinfo putenv realpath strndup gethostbyname2 gethostbyname getpeerucred getpeereid]) +AC_CHECK_FUNCS([floor gethostname memmove rmdir strncasecmp strrchr strtol atoll dup2 fdatasync ftruncate gettimeofday memset mkdir mkfifo select socket strcasecmp strchr strdup strerror strstr clock_gettime getrusage rand uname setlocale getcwd mktime gmtime_r gmtime strlcpy strlcat ftruncate stat64 sbrk mmap mremap setrlimit sysconf gethostbyaddr initgroups getifaddrs freeifaddrs getnameinfo getaddrinfo inet_ntoa localtime_r nl_langinfo putenv realpath strndup gethostbyname2 gethostbyname getpeerucred getpeereid setresuid]) # restore LIBS LIBS=$SAVE_LIBS @@ -676,6 +716,27 @@ AC_SUBST(DLLDIR) AC_SUBST(EXT_LIB_PATH) +# test for sudo +AC_MSG_CHECKING(for sudo) +AC_ARG_WITH(sudo, + [ --with-sudo=PATH path to sudo binary (or just yes)], + [AC_MSG_RESULT("$with_sudo") + case $with_sudo in + no) + SUDO_BINARY= + ;; + yes) + SUDO_BINARY=sudo + ;; + *) + SUDO_BINARY=$with_sudo + ;; + esac + ], + [AC_MSG_RESULT([no])]) +AC_SUBST(SUDO_BINARY) + + # should 'make check' run tests? AC_MSG_CHECKING(whether to run tests) AC_ARG_ENABLE([testruns], @@ -759,6 +820,7 @@ src/core/Makefile src/datacache/Makefile src/datastore/Makefile src/dht/Makefile +src/dns/Makefile src/dv/Makefile src/fragmentation/Makefile src/fs/Makefile @@ -779,6 +841,7 @@ src/transport/Makefile src/util/Makefile src/vpn/Makefile src/chat/Makefile +src/integration-tests/Makefile pkgconfig/Makefile pkgconfig/gnunetarm.pc pkgconfig/gnunetblock.pc