File:  [ELWIX - Embedded LightWeight unIX -] / mqtt / configure.in
Revision 1.3: download - view: text, annotated - select for diffs - revision graph
Fri Jan 18 09:43:27 2013 UTC (11 years, 5 months ago) by misho
Branches: MAIN
CVS tags: mqtt2_0, MQTT1_3, HEAD
version 1.3

    1: #
    2: # $Author: misho $
    3: # $Id: configure.in,v 1.3 2013/01/18 09:43:27 misho Exp $
    4: #
    5: AC_INIT(mqtt, 1.3, misho@elwix.org)
    6: AC_CONFIG_HEADERS(inc/config.h)
    7: AC_CONFIG_SRCDIR(src/mqttd.c)
    8: 
    9: # Checks for programs.
   10: AC_PROG_CC
   11: AC_PROG_RANLIB
   12: AC_PROG_INSTALL
   13: 
   14: AC_CANONICAL_HOST
   15: AC_CANONICAL_TARGET
   16: 
   17: AC_CHECK_TOOL(MKDEP, mkdep, no)
   18: AC_SUBST(MKDEP)
   19: 
   20: CFLAGS="-Wall -O2 -fPIC ${CFLAGS}"
   21: LDFLAGS="${LDFLAGS}"
   22: 
   23: 
   24: # Checks for libraries.
   25: AC_CHECK_LIB([util], openpty)
   26: AC_CHECK_LIB([crypto], BF_set_key)
   27: AC_CHECK_LIB([pthread], pthread_create)
   28: AC_CHECK_LIB([sqlite3], sqlite3_reset)
   29: AC_CHECK_LIB([aitcrc], crcFletcher16)
   30: AC_CHECK_LIB([aitio], io_allocVar)
   31: AC_CHECK_LIB([aitcfg], cfgLoadConfig)
   32: AC_CHECK_LIB([aitmqtt], mqtt_msgAlloc)
   33: AC_CHECK_LIB([aitsched], schedRun)
   34: 
   35: # Checks for header files.
   36: AC_CHECK_HEADERS([arpa/inet.h fcntl.h netdb.h netinet/in.h stdlib.h string.h sys/param.h sys/socket.h syslog.h unistd.h])
   37: 
   38: # Checks for typedefs, structures, and compiler characteristics.
   39: AC_C_INLINE
   40: 
   41: # Checks for library functions.
   42: AC_FUNC_FORK
   43: AC_FUNC_MALLOC
   44: AC_FUNC_MMAP
   45: AC_FUNC_REALLOC
   46: AC_CHECK_FUNCS([dup2 gettimeofday memmove memset mkdir munmap regcomp strchr strdup strerror strtol])
   47: 
   48: DEBUG=no
   49: AC_MSG_CHECKING(Debug Build)
   50: AC_ARG_ENABLE(debug,
   51: 	[  --enable-debug          Build library with debug information and additional messages],
   52: 	[ DEBUG=$enableval
   53: 		case "$enableval" in
   54: 			yes)
   55: 				AC_DEFINE(__DEBUG,, [Build libraries with debug information and additional messages])
   56: 				CFLAGS="-g ${CFLAGS}"
   57: 				;;
   58: 			*)
   59: 				AC_DEFINE(NDEBUG,, [Turn off debug asserts])
   60: 				;;
   61: 		esac ], AC_DEFINE(NDEBUG,, [Turn off debug asserts]))
   62: AC_MSG_RESULT($DEBUG)
   63: 
   64: SQLITE3DIR="/usr/local"
   65: AC_MSG_CHECKING(SQLite3 install directory)
   66: AC_ARG_WITH(sqlite3dir, 
   67: 	[  --with-sqlite3dir=<dir> Custom SQLite3 install directory ], 
   68: 	[ SQLITE3DIR="$withval" ], )
   69: AC_MSG_RESULT($SQLITE3DIR)
   70: AC_SUBST(SQLITE3DIR)
   71: 
   72: AC_CONFIG_FILES([Makefile
   73:                  bin/Makefile
   74:                  inc/Makefile
   75:                  lib/Makefile
   76:                  src/Makefile])
   77: AC_OUTPUT

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>