2006-12-23 18:43:34 +00:00
|
|
|
|
|
|
|
dnl library version info
|
|
|
|
m4_define([burn_interface_age], [0])
|
|
|
|
m4_define([burn_binary_age], [0])
|
|
|
|
|
|
|
|
dnl version info
|
|
|
|
m4_define([burn_major_version], [0])
|
|
|
|
m4_define([burn_minor_version], [2])
|
|
|
|
m4_define([burn_micro_version], [6])
|
2006-12-23 18:48:38 +00:00
|
|
|
m4_define([burn_nano_version], [3])
|
2006-12-23 18:43:34 +00:00
|
|
|
m4_define([burn_version], [burn_major_version().burn_minor_version().burn_micro_version()ifelse(burn_nano_version(), [], [], [.burn_nano_version()])])
|
|
|
|
|
2006-12-23 18:48:38 +00:00
|
|
|
AC_INIT([libburn], [burn_version], [http://libburnia.pykix.org])
|
2006-08-15 20:37:04 +00:00
|
|
|
AC_PREREQ([2.50])
|
|
|
|
dnl AC_CONFIG_HEADER([config.h])
|
|
|
|
|
2006-12-23 18:43:34 +00:00
|
|
|
AC_CANONICAL_HOST()
|
|
|
|
AC_CANONICAL_TARGET()
|
2006-08-15 20:37:04 +00:00
|
|
|
|
|
|
|
AM_INIT_AUTOMAKE([subdir-objects])
|
|
|
|
|
2006-11-01 17:19:37 +00:00
|
|
|
dnl A61101 This breaks Linux build (makes 32 bit off_t)
|
|
|
|
dnl http://sourceware.org/autobook/autobook/autobook_96.html says
|
|
|
|
dnl one must include some config.h and this was a pitfall.
|
|
|
|
dnl So why dig the pit at all ?
|
|
|
|
dnl AM_CONFIG_HEADER(config.h)
|
2006-10-19 08:12:29 +00:00
|
|
|
|
2006-08-15 20:37:04 +00:00
|
|
|
dnl Making releases:
|
|
|
|
dnl BURN_MICRO_VERSION += 1;
|
|
|
|
dnl BURN_INTERFACE_AGE += 1;
|
|
|
|
dnl BURN_BINARY_AGE += 1;
|
|
|
|
dnl if any functions have been added, set BURN_INTERFACE_AGE to 0.
|
|
|
|
dnl if backwards compatibility has been broken,
|
|
|
|
dnl set BURN_BINARY_AGE and BURN_INTERFACE_AGE to 0.
|
|
|
|
dnl
|
|
|
|
dnl if MAJOR or MINOR version changes, be sure to change AC_INIT above to match
|
|
|
|
dnl
|
2006-12-23 18:43:34 +00:00
|
|
|
BURN_MAJOR_VERSION=burn_major_version()
|
|
|
|
BURN_MINOR_VERSION=burn_minor_version()
|
|
|
|
BURN_MICRO_VERSION=burn_micro_version()
|
|
|
|
BURN_INTERFACE_AGE=burn_interface_age()
|
|
|
|
BURN_BINARY_AGE=burn_binary_age()
|
|
|
|
|
|
|
|
AC_SUBST([BURN_MAJOR_VERSION])
|
|
|
|
AC_SUBST([BURN_MINOR_VERSION])
|
|
|
|
AC_SUBST([BURN_MICRO_VERSION])
|
2006-08-15 20:37:04 +00:00
|
|
|
|
|
|
|
dnl Libtool versioning
|
|
|
|
LT_CURRENT=`expr $BURN_MICRO_VERSION - $BURN_INTERFACE_AGE`
|
|
|
|
LT_REVISION=$BURN_INTERFACE_AGE
|
|
|
|
LT_AGE=`expr $BURN_BINARY_AGE - $BURN_INTERFACE_AGE`
|
|
|
|
|
2006-12-23 18:43:34 +00:00
|
|
|
LT_VERSION_INFO=$LT_CURRENT:$LT_REVISION:$LT_AGE
|
|
|
|
AC_SUBST([LT_VERSION_INFO])
|
2006-08-15 20:37:04 +00:00
|
|
|
|
|
|
|
AC_PREFIX_DEFAULT([/usr/local])
|
|
|
|
test "$prefix" = "NONE" && prefix=$ac_default_prefix
|
|
|
|
|
2006-12-23 18:43:34 +00:00
|
|
|
AM_MAINTAINER_MODE()
|
2006-08-15 20:37:04 +00:00
|
|
|
|
2006-12-23 18:43:34 +00:00
|
|
|
AM_PROG_CC_C_O()
|
|
|
|
AC_C_CONST()
|
|
|
|
AC_C_INLINE()
|
|
|
|
AC_C_BIGENDIAN()
|
2006-08-15 20:37:04 +00:00
|
|
|
|
|
|
|
dnl Large file support
|
2006-12-23 18:43:34 +00:00
|
|
|
AC_SYS_LARGEFILE()
|
|
|
|
dnl AC_FUNC_FSEEKO()
|
|
|
|
AC_CHECK_FUNC([fseeko])
|
2006-08-15 20:37:04 +00:00
|
|
|
if test ! $ac_cv_func_fseeko; then
|
|
|
|
AC_ERROR([Libburn requires largefile support.])
|
|
|
|
fi
|
|
|
|
|
2006-12-23 18:43:34 +00:00
|
|
|
AC_PROG_LIBTOOL()
|
|
|
|
AC_SUBST([LIBTOOL_DEPS])
|
2006-08-15 20:37:04 +00:00
|
|
|
LIBTOOL="$LIBTOOL --silent"
|
|
|
|
|
2006-12-23 18:43:34 +00:00
|
|
|
AC_PROG_INSTALL()
|
2006-08-15 20:37:04 +00:00
|
|
|
|
|
|
|
AC_CHECK_HEADERS()
|
|
|
|
|
2006-10-19 08:12:29 +00:00
|
|
|
AC_CHECK_MEMBER([struct tm.tm_gmtoff],
|
|
|
|
[AC_DEFINE(HAVE_TM_GMTOFF, 1,
|
|
|
|
[Define this if tm structure includes a tm_gmtoff entry.])],
|
|
|
|
,
|
|
|
|
[#include <time.h>])
|
|
|
|
|
2006-08-15 20:37:04 +00:00
|
|
|
THREAD_LIBS=-lpthread
|
2006-12-23 18:43:34 +00:00
|
|
|
AC_SUBST([THREAD_LIBS])
|
2006-08-15 20:37:04 +00:00
|
|
|
|
|
|
|
TARGET_SHIZZLE
|
2006-12-23 18:43:34 +00:00
|
|
|
AC_SUBST([ARCH])
|
|
|
|
AC_SUBST([LIBBURN_ARCH_LIBS])
|
2006-08-15 20:37:04 +00:00
|
|
|
|
|
|
|
dnl Add compiler-specific flags
|
|
|
|
|
|
|
|
dnl See if the user wants aggressive optimizations of the code
|
|
|
|
AC_ARG_ENABLE(debug,
|
|
|
|
[ --enable-debug Disable aggressive optimizations [default=yes]],
|
|
|
|
, enable_debug=yes)
|
|
|
|
if test x$enable_debug != xyes; then
|
|
|
|
if test x$GCC = xyes; then
|
|
|
|
CFLAGS="$CFLAGS -O3"
|
|
|
|
CFLAGS="$CFLAGS -fexpensive-optimizations"
|
|
|
|
fi
|
|
|
|
CFLAGS="$CFLAGS -DNDEBUG"
|
|
|
|
else
|
|
|
|
if test x$GCC = xyes; then
|
|
|
|
CFLAGS="$CFLAGS -g -pedantic -Wall"
|
|
|
|
fi
|
|
|
|
CFLAGS="$CFLAGS -DDEBUG"
|
|
|
|
fi
|
|
|
|
|
|
|
|
AC_CONFIG_FILES([
|
|
|
|
Makefile
|
|
|
|
doc/doxygen.conf
|
|
|
|
version.h
|
|
|
|
libburn-1.pc
|
|
|
|
])
|
2006-12-23 18:43:34 +00:00
|
|
|
AC_OUTPUT()
|