1 AC_INIT([Haskell zlib package], [1.1], [libraries@haskell.org], [zlib])
3 # Safety check: Ensure that we are in the correct source directory.
4 AC_CONFIG_SRCDIR([zlib.cabal])
6 # Header file to place defines in
7 AC_CONFIG_HEADERS([include/HsZlibConfig.h])
9 # Check for zlib include
10 AC_CHECK_HEADER(zlib.h, [ZLIB_HEADER=yes], [], [])
12 # Check that flag assignment has been propagated correctly
13 if test "$CABAL_FLAG_true_flag" != "1"; then
14 echo "true flag incorrectly set: got '$CABAL_FLAG_true_flag'"
17 if test "$CABAL_FLAG_false_flag" != "0"; then
18 echo "false flag incorrectly set: got '$CABAL_FLAG_false_flag'"
22 if test "$CABAL_FLAGS" != "+con-flict +con_flict -false-flag +true-flag"; then
23 echo "CABAL_FLAGS incorrectly set: got '$CABAL_FLAGS'"
27 # Build the package if we found X11 stuff
28 if test "x$ZLIB_HEADER" = "x"
29 then BUILD_PACKAGE_BOOL=False
30 else BUILD_PACKAGE_BOOL=True
32 AC_SUBST([BUILD_PACKAGE_BOOL])
34 AC_CONFIG_FILES([zlib.buildinfo])