X-Git-Url: https://git.draconx.ca/gitweb/upkg.git/blobdiff_plain/a9b51e6d85e077f8e18c35ac3606d80b343927e0..382855dd3f69cdce3e3b4eb6da392f881e7825da:/configure.ac diff --git a/configure.ac b/configure.ac index debf262..f86b8dd 100644 --- a/configure.ac +++ b/configure.ac @@ -4,14 +4,33 @@ AC_CONFIG_SRCDIR([src/libupkg.c]) AC_CONFIG_HEADER([config.h]) AC_CONFIG_MACRO_DIR([m4]) -AM_INIT_AUTOMAKE([-Wall -Werror foreign]) +AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects]) AC_PROG_CC_C99 -LT_INIT +AC_ARG_WITH([gobject], + [AS_HELP_STRING([--with-gobject], + [build tools requiring libgobject [default=yes]] + )], + [], + [with_gobject=yes]) + +have_gobject=no +if test x$with_gobject = xyes; then +AM_PATH_GLIB_2_0(, [have_gobject=yes], [have_gobject=no], [gobject]) +fi + +AM_CONDITIONAL([BUILD_UPKG], [test x$have_gobject = xyes]) + +LT_CONFIG_LTDL_DIR([libltdl]) +LT_INIT([dlopen]) +LTDL_INIT([recursive]) + +AM_CONDITIONAL([BUNDLED_LIBLTDL], [test x$LTDLDEPS != x]) AC_CONFIG_FILES([ Makefile + libltdl/Makefile src/Makefile ]) AC_OUTPUT