2 # Process this file with autoconf to produce a configure script.
5 AC_INIT([dlog], [1.0], yk.yun@samsung.com)
6 AM_INIT_AUTOMAKE([-Wall -Werror foreign])
7 AC_CONFIG_HEADERS([config.h:config.hin])
9 AC_CONFIG_MACRO_DIR([m4])
13 # Checks for programs.
15 m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
17 AC_PROG_GCC_TRADITIONAL
21 AM_CONDITIONAL(DEVELOP_VER, test $DEVELOP_VER = yes)
23 # check for libsystemd-journal
24 AC_ARG_WITH([systemd-journal],
25 AS_HELP_STRING([--with-systemd-journal], [check for systemd-journal]),
26 [], [with_systemd_journal=check])
27 have_systemd_journal=no
28 if test "x$with_systemd_journal" != "xno"; then
29 PKG_CHECK_MODULES(systemd_journal, [libsystemd-journal],
30 [AC_DEFINE(HAVE_SYSTEMD_JOURNAL, 1, [Define if systemd journal is available])
31 have_systemd_journal=yes],
32 have_systemd_journal=no)
33 if test "x$have_systemd_journal" = "xno" -a "x$with_systemd_journal" = "xyes"; then
34 AC_MSG_ERROR([systemd journal requested but libraries not found])
37 AM_CONDITIONAL(HAVE_SYSTEMD_JOURNAL, [test "x$have_systemd_journal" = "xyes"])
39 #AM_CONDITIONAL([ARCH_IS_ARM], [test "x$ARCH" = "xarm"])
40 if test "x$ARCH" = "xarm" ; then
41 DLOG_CFLAGS="-D__arm__"
49 dnl AC_SUBST(ACLOCAL_AMFLAGS, "-I m4")
50 # Checks for libraries.
51 # Checks for header files.
53 AC_CHECK_HEADERS([stdlib.h unistd.h ])
55 # Checks for typedefs, structures, and compiler characteristics.
64 # Checks for library functions.
67 AC_CHECK_FUNCS([memset])
70 AC_CONFIG_FILES([Makefile dlog.pc])