1#                                               -*- Autoconf -*-
2# Process this file with autoconf to produce a configure script.
3
4AC_PREREQ([2.61])
5m4_include([common_m4/versions.m4])
6AC_INIT([api], API_VERSION_NUMBER, [https://sourceforge.net/apps/trac/razorbacktm/])
7AC_CONFIG_AUX_DIR([.])
8AC_CONFIG_MACRO_DIR([m4])
9AC_CONFIG_SRCDIR([src/thread.c])
10AC_CONFIG_HEADERS([config.h])
11AM_INIT_AUTOMAKE([foreign no-define tar-ustar subdir-objects])
12
13APIVERSION=API_LIB_VERSION_NUMBER
14
15# Pull in the checks for the build tools.
16m4_include([common_m4/build_tools.m4])
17
18# Pull in the platform specific build/configure environment options.
19m4_include([common_m4/platform_flags.m4])
20
21# Pull in the dependancies on on the API (use the nugget way).
22m4_include([common_m4/api_deps.m4])
23
24# Pull in the standard header and function checks.
25m4_include([common_m4/standard_headers_functions.m4])
26
27# Pull in the standard options for all components
28m4_include([common_m4/standard_options.m4])
29
30AC_ARG_ENABLE([cnc_debug], [AS_HELP_STRING([--enable-cnc-debug],[Enable command and control debug])], [enable_cnc_debug=$enableval], [enable_cnc_debug="no"])
31if test "x$enable_cnc_debug" = "xyes"; then
32    AC_DEFINE([CNC_DEBUG], 1, [Command and Control Debug Mode])
33fi
34
35AC_ARG_ENABLE([stomp_debug], [AS_HELP_STRING([--enable-stomp-debug],[Enable stomp debug])], [enable_stomp_debug=$enableval], [enable_stomp_debug="no"])
36if test "x$enable_stomp_debug" = "xyes"; then
37    AC_DEFINE([STOMP_DEBUG], 1, [Stomp Debug Mode])
38fi
39
40AC_ARG_ENABLE([magic_debug], [AS_HELP_STRING([--enable-magic-debug],[Enable magic debug])], [enable_magic_debug=$enableval], [enable_magic_debug="no"])
41if test "x$enable_magic_debug" = "xyes"; then
42    AC_DEFINE([MIME_MAGIC_DEBUG], 1, [Magic Debug Mode])
43fi
44m4_include([libssh/configure.m4])
45
46AC_CHECK_HEADERS([sys/endian.h], [], [SYS_ENDIAN_HEADER="no"])
47# Pull in the compiler customisation options for different compilers.
48m4_include([common_m4/compiler_options.m4])
49
50# Pull in the standard compiler and linker flags.
51m4_include([common_m4/cflags.m4])
52
53AC_SUBST(XCCFLAGS)
54AC_SUBST(APIVERSION)
55AC_SUBST(LIBS)
56AC_SUBST(extra_incl)
57
58AC_CONFIG_FILES([ \
59razorback.pc \
60Makefile \
61m4/Makefile \
62etc/Makefile \
63include/Makefile \
64src/Makefile \
65libssh/Makefile \
66libssh/src/Makefile \
67libssh/src/threads/Makefile \
68libssh/include/Makefile \
69tests/Makefile \
70])
71AC_OUTPUT
72