Alien-Judy

 view release on metacpan or  search on metacpan

src/judy-1.0.5/configure.ac  view on Meta::CPAN

    AC_MSG_RESULT(Detected 64-bit Build Environment)
    CFLAGS="-DJU_64BIT $CFLAGS"
else 
    AC_MSG_RESULT(Detected 32-bit Build Environment)
      CFLAGS="-UJU_64BIT $CFLAGS"
fi

AC_ARG_ENABLE(32-bit, [  --enable-32-bit          Generate code for a 32-bit environment],
	      b32="$enableval", b32="no")
if test x"$b32" != "xno"; then
    AC_MSG_RESULT(Configured to Build 32-bit)
    if test x"$GCC" = xyes; then
      CFLAGS="-UJU_64BIT -m32 $CFLAGS"
    else
      CFLAGS="-UJU_64BIT $CFLAGS"
    fi
fi

AC_ARG_ENABLE(64-bit, [  --enable-64-bit          Generate code for a 64-bit environment],
              b64="$enableval", b64="no")
if test x"$b64" != "xno"; then
    AC_MSG_RESULT(Configured to Building 64-bit)
    if test x"$GCC" = xyes; then
      CFLAGS="-DJU_64BIT -m64 $CFLAGS"
    else
      CFLAGS="-DJU_64BIT $CFLAGS"
    fi
fi



#  dnl Determine whether or not we're compiling for a 64-bit system by looking
#  dnl at the size of a 'long'.  This will define SIZEOF_LONG in config.h.  We
#  dnl append some text to the bottom of config.h to set JU_64BIT appropriately.
#  dnl we try to do the correct thing if the user doesn't chose for us. 
#  AC_CHECK_SIZEOF(long)
#  AH_BOTTOM([/* Define JU_64BIT to 1 if we're on a 64-bit system. */
#  if SIZEOF_LONG == 8
#    define JU_64BIT 1
#  endif])
#fi

dnl==========================================================================
dnl Checks for Libraries
dnl==========================================================================

AC_FUNC_ERROR_AT_LINE
AC_FUNC_MALLOC
AC_FUNC_MEMCMP
AC_FUNC_MMAP
AC_FUNC_STAT
AC_FUNC_VPRINTF
AC_CHECK_FUNCS([getpagesize gettimeofday memset munmap pow strchr strcspn strerror strstr strtoul uname])

dnl These must be called before AM_PROG_LIBTOOL, because it may want
dnl to call AC_CHECK_PROG.
AC_CHECK_TOOL(AR, ar)
AC_CHECK_TOOL(LD, ld)
AC_CHECK_TOOL(RANLIB, ranlib, :)

dnl Checks for libtool - this must be done after we set cflags (abi issues)
dnl
AM_PROG_LIBTOOL

WARN_CFLAGS=""
build_warnings="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
AC_ARG_ENABLE([build-warnings],
	      [  --enable-build-warnings    Enable build-time compiler warnings for gcc])
if test x"$build_warnings" = xyes; then
    if test x"$GCC" = xyes; then
	WARN_CFLAGS="${build_warnings}"
    fi
fi

AC_SUBST(WARN_CFLAGS)

AC_CONFIG_FILES([Makefile
                 src/Judy1/Makefile
                 src/JudyCommon/Makefile
                 src/JudyHS/Makefile
                 src/JudyL/Makefile
                 src/JudySL/Makefile
                 src/Makefile
                 src/obj/Makefile
		 tool/Makefile
		 doc/Makefile
		 test/Makefile])


AC_OUTPUT



( run in 0.810 second using v1.01-cache-2.11-cpan-140bd7fdf52 )