dnl
-dnl Copyright 2004,2005,2007 Free Software Foundation, Inc.
+dnl Copyright 2004,2005,2007,2008 Free Software Foundation, Inc.
dnl
dnl This file is part of GNU Radio
dnl
AC_PREREQ(2.57)
AC_CONFIG_SRCDIR([src/lib/howto.i])
AM_CONFIG_HEADER(config.h)
-AC_CANONICAL_TARGET([])
+
+AC_CANONICAL_BUILD
+AC_CANONICAL_HOST
+AC_CANONICAL_TARGET
+
AM_INIT_AUTOMAKE(gr-howto-write-a-block,3.1.svn)
-GR_X86_64
-dnl LF_CONFIGURE_CC
+LF_CONFIGURE_CC
LF_CONFIGURE_CXX
+GR_LIB64 dnl check for lib64 suffix after choosing compilers
+
+
+dnl add ${prefix}/lib${gr_libdir_suffix}/pkgconfig to the head of the PKG_CONFIG_PATH
+if test x${PKG_CONFIG_PATH} = x; then
+ PKG_CONFIG_PATH=${prefix}/lib${gr_libdir_suffix}/pkgconfig
+else
+ PKG_CONFIG_PATH=${prefix}/lib${gr_libdir_suffix}/pkgconfig:${PKG_CONFIG_PATH}
+fi
+export PKG_CONFIG_PATH
+
LF_SET_WARNINGS
GR_SET_GPROF
GR_SET_PROF
AC_ENABLE_SHARED dnl do build shared libraries
AC_DISABLE_STATIC dnl don't build static libraries
m4_ifdef([LT_INIT],[LT_INIT],[AC_PROG_LIBTOOL])
+dnl GR_FORTRAN
-dnl Locate python, SWIG, etc
-GR_NO_UNDEFINED
-GR_SCRIPTING
+GR_NO_UNDEFINED dnl do we need the -no-undefined linker flag
+GR_SCRIPTING dnl Locate python, SWIG, etc
-dnl Checks for libraries.
+AC_CHECK_PROG([XMLTO],[xmlto],[yes],[])
+AM_CONDITIONAL([HAS_XMLTO], [test x$XMLTO = xyes])
-dnl check for threads (mandatory)
-GR_OMNITHREAD
-CFLAGS="${CFLAGS} $PTHREAD_CFLAGS"
-CXXFLAGS="${CXXFLAGS} $PTHREAD_CFLAGS"
+dnl Checks for libraries.
+dnl Set the c++ compiler that we use for the build system when cross compiling
if test "x$CXX_FOR_BUILD" = x
then
CXX_FOR_BUILD=${CXX}
AC_C_INLINE
AC_TYPE_SIZE_T
AC_HEADER_TIME
+AC_C_BIGENDIAN
+
dnl Checks for library functions.
AC_CHECK_FUNCS([])
PKG_CHECK_MODULES(GNURADIO_CORE, gnuradio-core >= 3)
LIBS="$LIBS $GNURADIO_CORE_LIBS"
-dnl Define where to find boost includes
-dnl defines BOOST_CFLAGS
-GR_REQUIRE_BOOST_INCLUDES
-
-STD_DEFINES_AND_INCLUDES="$GNURADIO_CORE_CFLAGS $BOOST_CFLAGS"
+dnl We pick up the boost cppflags, cxxflags and thread lib via GNURADIO_CORE
+dnl
+dnl If you need additional boost libraries, you'll need to
+dnl uncomment AX_BOOST_BASE, plus some of the following:
+dnl
+dnl calls AC_SUBST(BOOST_CPPFLAGS), AC_SUBST(BOOST_LDFLAGS) and defines HAVE_BOOST
+dnl AX_BOOST_BASE([1.35])
+dnl
+dnl All the rest of these call AC_SUBST(BOOST_<foo>_LIB) and define HAVE_BOOST_<foo>
+dnl
+dnl AX_BOOST_DATE_TIME
+dnl AX_BOOST_FILESYSTEM
+dnl AX_BOOST_IOSTREAMS
+dnl AX_BOOST_PROGRAM_OPTIONS
+dnl AX_BOOST_REGEX
+dnl AX_BOOST_SERIALIZATION
+dnl AX_BOOST_SIGNALS
+dnl AX_BOOST_SYSTEM
+dnl AX_BOOST_TEST_EXEC_MONITOR
+dnl AX_BOOST_UNIT_TEST_FRAMEWORK
+dnl AX_BOOST_WSERIALIZATION
+
+
+STD_DEFINES_AND_INCLUDES="$GNURADIO_CORE_CFLAGS"
AC_SUBST(STD_DEFINES_AND_INCLUDES)
AC_CONFIG_FILES([\