2 # Process this file with autoconf to produce a configure script.
5 AC_INIT(scss, 1.0.0, konn@users.sourceforge.jp)
7 AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
8 AC_CONFIG_SRCDIR([src/main.c])
9 AC_CONFIG_HEADER([include/config.h])
11 # Checks for programs.
13 AC_SUBST(LIBTOOL_DEPS)
16 # Checks for libraries.
17 AC_CHECK_LIB([apr-1], [main])
19 # Checks for header files.
21 AC_CHECK_HEADERS([string.h])
23 dnl ==================================================
27 dnl ==================================================
28 AC_ARG_WITH(apr-config, [ --with-apr-config=ARG Path of apr-config program file.])
29 if test "x$with_apr_config" = "xyes" ; then
31 Please specify the --with-apr-config option. And, please specify the place of the apr-config program.
35 dnl ==================================================
39 dnl ==================================================
40 AC_ARG_WITH(apu-config, [ --with-apu-config=ARG Path of apu-config program file.])
41 if test "x$with_apu_config" = "xyes" ; then
43 Please specify the --with-apu-config option. And, please specify the place of the apu-config program.
47 AC_PATH_PROG(LIBTOOL, libtool, no,
48 /usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin)
49 if test "x$LIBTOOL" = "xno"; then
50 AC_MSG_ERROR([libtool not found.])
54 if test "x$with_apr_config" = "x" ; then
55 AC_PATH_PROG(APR_CONFIG, apr-config, no, /usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin)
56 if test "x$APR_CONFIG" = "xno" ; then
57 AC_PATH_PROG(APR_1_CONFIG, apr-1-config, no, /usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin)
58 if test "x$APR_1_CONFIG" = "xno" ; then
59 AC_MSG_ERROR([apr-config and apr-1-config not found.])
61 APR_CONFIG="$APR_1_CONFIG"
65 if test "x$with_apr_config" != "x" ; then
66 APR_CONFIG=$with_apr_config
68 if test "x$with_apu_config" = "x" ; then
69 AC_PATH_PROG(APU_CONFIG, apu-config, no, /usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin)
70 if test "x$APU_CONFIG" = "xno" ; then
71 AC_PATH_PROG(APU_1_CONFIG, apu-1-config, no, /usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin)
72 if test "x$APU_1_CONFIG" = "xno" ; then
73 AC_MSG_ERROR([apu-config and apu-1-config not found.])
75 APU_CONFIG="$APU_1_CONFIG"
79 if test "x$with_apu_config" != "x" ; then
80 APU_CONFIG=$with_apu_config
84 if test "x$with_apu_config" != "x" ; then
85 APU_CONFIG=$with_apu_config
88 LIBS="${LIBS} `${APR_CONFIG} --ldflags` `${APR_CONFIG} --libs` "
89 LIBS="${LIBS} `${APU_CONFIG} --ldflags` `${APU_CONFIG} --libs` "
90 CFLAGS="${CFLAGS} `${APR_CONFIG} --includes` `${APR_CONFIG} --cflags` `${APR_CONFIG} --cppflags`"
91 CFLAGS="${CFLAGS} `${APU_CONFIG} --includes`"
94 # Checks for typedefs, structures, and compiler characteristics.
97 # Checks for library functions.
98 AC_CHECK_FUNCS([memset strcasecmp strncasecmp])
104 AC_CONFIG_FILES([Makefile src/Makefile])