Artifact 78d14fc3bbeb6d0ad0926f84b43946a5cd8e876c6d44035dcbb50d09a2a30582:
- File
configure.ac
— part of check-in
[ce5d486e9a]
at
2016-05-06 18:04:28
on branch trunk
— Initial import.
Only templates for now. This is based on some code from 2013 and adds a
proper build system and tests. (user: js, size: 1735) [annotate] [blame] [check-ins using]
AC_INIT(ObjWeb, 0.1, js@heap.zone) BUILDSYS_INIT AC_CONFIG_SRCDIR(src) AC_CONFIG_MACRO_DIR(m4) AC_CONFIG_AUX_DIR(build-aux) AC_CHECK_TOOL(OBJFW_CONFIG, objfw-config) AS_IF([test x"$OBJFW_CONFIG" = x""], [ AC_MSG_ERROR(You need ObjFW and objfw-config installed!) ]) test x"$OBJC" = x"" && OBJC="$($OBJFW_CONFIG --objc)" AC_LANG([Objective C]) AC_PROG_OBJC AC_PROG_OBJCPP AC_PROG_LN_S AC_PROG_INSTALL AC_PATH_TOOL(AR, ar) AC_PROG_RANLIB CPP="$OBJCPP" CPPFLAGS="$CPPFLAGS $OBJCPPFLAGS $($OBJFW_CONFIG --cppflags)" OBJCFLAGS="$OBJCFLAGS -Wall $($OBJFW_CONFIG --objcflags)" LDFLAGS="$LDFLAGS $($OBJFW_CONFIG --ldflags --rpath)" LIBS="$LIBS $($OBJFW_CONFIG --libs)" AC_ARG_ENABLE(shared, AS_HELP_STRING([--disable-shared], [do not build shared library])) AS_IF([test x"$enable_shared" != x"no"], [ BUILDSYS_SHARED_LIB AC_SUBST(OBJWEB_SHARED_LIB, "${LIB_PREFIX}objweb${LIB_SUFFIX}") AC_SUBST(EXCEPTIONS_LIB_A, "exceptions.lib.a") AC_SUBST(EXCEPTIONS_EXCEPTIONS_LIB_A, "exceptions/exceptions.lib.a") ]) AC_ARG_ENABLE(static, AS_HELP_STRING([--enable-static], [build static library])) AS_IF([test x"$enable_static" = x"yes" -o x"$enable_shared" = x"no"], [ AC_SUBST(OBJWEB_STATIC_LIB, "libobjweb.a") AC_SUBST(EXCEPTIONS_A, "exceptions.a") AC_SUBST(EXCEPTIONS_EXCEPTIONS_A, "exceptions/exceptions.a") ]) AS_IF([test x"$GOBJC" = x"yes"], [ OBJCFLAGS="$OBJCFLAGS -Wwrite-strings -Wpointer-arith -Werror" ]) dnl We don't call AC_PROG_CPP, but only AC_PROG_OBJCPP and set CPP to OBJCPP dnl and add OBJCPPFLAGS to CPPFLAGS, thus we need to AC_SUBST these ourself. AC_SUBST(CPP) AC_SUBST(CPPFLAGS) AS_IF([test x"$cross_compiling" != x"yes"], [ AC_SUBST(RUN_TESTS, "run") ]) AC_CONFIG_FILES([buildsys.mk extra.mk]) AC_OUTPUT