[3c30b59] | 1 | AC_INIT([ABAC], [0.1.5], [faber@ISI.EDU]) |
---|
[4918535] | 2 | AC_CONFIG_SRCDIR([libabac/abac_role.c]) |
---|
| 3 | AM_INIT_AUTOMAKE([foreign subdir-objects]) |
---|
[6ede88c] | 4 | LT_INIT |
---|
| 5 | |
---|
| 6 | AC_CONFIG_MACRO_DIR([m4]) |
---|
| 7 | |
---|
| 8 | # Checks for programs. |
---|
| 9 | AC_PROG_CXX |
---|
| 10 | AC_PROG_CC |
---|
[b73c2538] | 11 | AC_PROG_LIBTOOL |
---|
[6ede88c] | 12 | |
---|
[48fa0ee] | 13 | # Explicitly hunt up perl |
---|
| 14 | AC_CHECK_PROGS(PERL, perl) |
---|
| 15 | |
---|
[43a5429] | 16 | # for python |
---|
| 17 | AM_PATH_PYTHON |
---|
[46a2dc3] | 18 | |
---|
[461541a] | 19 | # for openssl |
---|
| 20 | AX_CHECK_OPENSSL([], [AC_MSG_ERROR([openssl is required to build pacakge])] ) |
---|
| 21 | |
---|
| 22 | # for xmlsec1 |
---|
| 23 | AX_CHECK_XMLSEC1([], [AC_MSG_ERROR([xmlsec1 is required to build pacakge])] ) |
---|
| 24 | # for xml2 |
---|
| 25 | AX_CHECK_XML2([], [AC_MSG_ERROR([xml2 is required to build pacakge])] ) |
---|
| 26 | |
---|
| 27 | # for swig |
---|
[46a2dc3] | 28 | AX_PKG_SWIG(1.3.17, [], [AC_MSG_ERROR([SWIG is required to build package])] ) |
---|
| 29 | AX_SWIG_ENABLE_CXX |
---|
| 30 | AX_SWIG_PYTHON |
---|
[43a5429] | 31 | |
---|
[6ede88c] | 32 | AC_ARG_ENABLE(debug, |
---|
| 33 | [AC_HELP_STRING([--enable-debug], [build with debug symbols])], |
---|
| 34 | [CFLAGS+="-g "],[]) |
---|
| 35 | |
---|
| 36 | # Checks for libraries. |
---|
[48fa0ee] | 37 | AC_ARG_WITH( |
---|
| 38 | [site-perl], |
---|
| 39 | [AS_HELP_STRING([--with-site-perl=DIR], |
---|
| 40 | [directory in which to install perl modules])], |
---|
| 41 | [SITE_PERL="$withval"], [SITE_PERL=""]) |
---|
| 42 | |
---|
| 43 | |
---|
| 44 | # Ask perl for a likely site_perl directory. If the user has already specified |
---|
| 45 | # it using --with-site-perl, use that value. NB, this does not respect prefix, |
---|
| 46 | # so users wishing to do a local install must use --with-site-perl |
---|
| 47 | AC_MSG_CHECKING(for site_perl directory) |
---|
| 48 | if test -z "$SITE_PERL"; then |
---|
| 49 | SITE_PERL=`$PERL -e 'print((grep(/site_perl/ && !m#/mach#, @INC))[0], "\n");'` |
---|
| 50 | fi |
---|
| 51 | AC_MSG_RESULT($SITE_PERL) |
---|
| 52 | AC_SUBST(SITE_PERL) |
---|
| 53 | |
---|
[6ede88c] | 54 | # Checks for header files. |
---|
[2579c1a] | 55 | AC_CHECK_HEADERS([inttypes.h stddef.h stdlib.h string.h readpassphrase.h paths.h]) |
---|
[6ede88c] | 56 | |
---|
| 57 | # Checks for typedefs, structures, and compiler characteristics. |
---|
| 58 | AC_HEADER_STDBOOL |
---|
| 59 | AC_TYPE_SIZE_T |
---|
| 60 | AC_TYPE_UINT16_T |
---|
| 61 | AC_TYPE_UINT32_T |
---|
| 62 | AC_TYPE_UINT8_T |
---|
| 63 | AC_CHECK_TYPES([ptrdiff_t]) |
---|
| 64 | |
---|
[2579c1a] | 65 | AC_CHECK_DECL([_PATH_TTY],[],AC_DEFINE_UNQUOTED([_PATH_TTY],"/dev/tty",[Define to tty device node path]),[ |
---|
| 66 | #ifdef HAVE_PATHS_H |
---|
| 67 | # include <paths.h> |
---|
| 68 | #endif |
---|
| 69 | ]) |
---|
| 70 | |
---|
[6ede88c] | 71 | # Checks for library functions. |
---|
| 72 | AC_FUNC_MALLOC |
---|
[2579c1a] | 73 | AC_CHECK_FUNCS([atexit memset strchr strdup readpassphrase]) |
---|
[6ede88c] | 74 | |
---|
[4f79997] | 75 | AC_CONFIG_FILES([Makefile tests/Makefile tests/creddy_tests/Makefile tests/creddy_prover_tests/Makefile tests/attr_tests/Makefile tests/python_tests/Makefile tests/scaling_tests/Makefile tests/scaling_tests/daisychain/Makefile tests/scaling_tests/daisychain/likes_python/Makefile tests/scaling_tests/haystack/Makefile tests/scaling_tests/haystack/ralphs_prover/Makefile tests/example_scripts/Makefile tests/example_scripts/wiki/Makefile tests/example_scripts/c/Makefile tests/example_scripts/python/Makefile tests/example_scripts/perl/Makefile]) |
---|
[6ede88c] | 76 | AC_OUTPUT |
---|