## ## Copyright (C) 2004-2006 Autodesk, Inc. ## ## This library is free software; you can redistribute it and/or ## modify it under the terms of version 2.1 of the GNU Lesser ## General Public License as published by the Free Software Foundation. ## ## This library is distributed in the hope that it will be useful, ## but WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ## Lesser General Public License for more details. ## ## You should have received a copy of the GNU Lesser General Public ## License along with this library; if not, write to the Free Software ## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA ## #------------------configure.in---------------------------------------- dnl Configure.in for OSGeo FDO SDF Provider #---------------------------------------------------------------------- # Variables # Following are the makefile directories #---------------------------------------------------------------------- AC_INIT(FDOSDF,3.2.0,http://www.fdo.osgeo.org) AC_CONFIG_SRCDIR(configure.in) AM_INIT_AUTOMAKE AC_PREFIX_DEFAULT(/usr/local/fdo-3.2.0) AC_LANG_C AC_PROG_CC AC_LANG_CPLUSPLUS AC_PROG_CXX AC_PROG_YACC AC_DISABLE_STATIC AM_PROG_LIBTOOL AC_SUBST(VERSION, "3.2.0") dnl ******************************************************* dnl FDO 3.2.0 Configuration dnl FDO / FDO Utilities / FDO Thirdpary paths dnl ******************************************************* # custom Fdo path specification AC_ARG_WITH([fdo], FDO_HELP_STRING([--with-fdo], [specifies directory for FDO API files [[default=DEFAULT]]]), [custom_fdo=$withval], [custom_fdo=DEFAULT]) if test $custom_fdo = "DEFAULT"; then if test -d $FDO && test ! $FDO = ""; then AC_MSG_NOTICE([Building with default location of FDO API files at $FDO]) else AC_MSG_ERROR([The default FDO API path $FDO is not a valid directory. Please use the custom option]) fi else if test -d $custom_fdo; then FDO="$custom_fdo" AC_MSG_NOTICE([Building with custom location of FDO API directory at $FDO]) else AC_MSG_ERROR([The specified FDO API path $custom_fdo is not a valid directory]) fi fi AC_ARG_WITH([fdo-utilities], FDO_HELP_STRING([--with-fdo-utilities], [specifies directory for FDO API Utility files [[default=DEFAULT]]]), [custom_fdo_utilities=$withval], [custom_fdo_utilities=DEFAULT]) if test $custom_fdo_utilities = "DEFAULT"; then if test -d $FDOUTILITIES && test ! $FDOUTILITIES = ""; then AC_MSG_NOTICE([Building with default location of FDO Utility files at $FDOUTILITIES]) else AC_MSG_ERROR([the default FDO Utilities path $FDOUTILITIES is not a valid directory. Please use the custom option]) fi else if test -d $custom_fdo_utilities; then FDOUTILITIES="$custom_fdo_utilities" AC_MSG_NOTICE([Building with custom location of FDO Utilities directory at $FDOUTILITIES]) else AC_MSG_ERROR([The specified FDO Utilities path $custom_fdo_utilities is not a valid directory]) fi fi AC_ARG_WITH([fdo-thirdparty], FDO_HELP_STRING([--with-fdo-thirdparty], [specifies directory for FDO API Thirdparty files [[default=DEFAULT]]]), [custom_fdo_thirdparty=$withval], [custom_fdo_thirdparty=DEFAULT]) if test $custom_fdo_thirdparty = "DEFAULT"; then if test -d $FDOTHIRDPARTY && test ! $FDOTHIRDPARTY = ""; then AC_MSG_NOTICE([Building with default location of FDO Thirdparty files at $FDOTHIRDPARTY]) else AC_MSG_ERROR([The default FDO Thirdparty path $custom_fdo_thirdparty is not a valid directory. Please use the custom option]) fi else if test -d $custom_fdo_thirdparty; then FDOTHIRDPARTY="$custom_fdo_thirdparty" AC_MSG_NOTICE([Building with custom location of FDO Thirdperty directory at $FDOTHIRDPARTY]) else AC_MSG_ERROR([The specified FDO Thirdparty path $custom_fdo_thirdparty is not a valid directory]) fi fi AC_SUBST(FDO) AC_SUBST(FDOUTILITIES) AC_SUBST(FDOTHIRDPARTY) # Check for Debug or Release build settings AC_ARG_ENABLE([debug], MAP_HELP_STRING([--enable-debug], [enable debug build [[default=no]]]), [enable_debug=$enableval], [enable_debug=no]) if test $enable_debug = yes; then AC_MSG_NOTICE([Using debug configuration]) CXXFLAGS="-g -MMD -MT " AC_SUBST(CXXFLAGS, ["-g -MMD -MT "]) CXXFLAGS_SDF="-g " AC_SUBST(CXXFLAGS_SDF, ["-g "]) else AC_MSG_NOTICE([Using optimized configuration]) CXXFLAGS="-MMD -MT " AC_SUBST(CXXFLAGS, ["-MMD -MT "]) CXXFLAGS_SDF="" AC_SUBST(CXXFLAGS_SDF, [""]) fi ##output Makefiles## AC_CONFIG_FILES(Makefile) AC_CONFIG_FILES([Inc/Makefile \ Src/Makefile \ Src/Message/Makefile \ Src/Utils/Makefile \ Src/Provider/Makefile \ Src/UnitTest/Makefile]) AC_CONFIG_FILES([Docs/Makefile \ Docs/doc_src/Makefile \ Docs/doc_src/group_and_page_definitions/Makefile \ Docs/doc_src/headers_and_footers/Makefile]) AC_OUTPUT