1
Fork 0

Merge branch 'cxxmph' of ssh://cmph.git.sourceforge.net/gitroot/cmph/cmph into cxxmph

Conflicts:
	Makefile.am
	configure.ac
This commit is contained in:
Davi de Castro Reis 2011-05-15 19:44:28 -03:00
commit 7d5a62cb1a
3 changed files with 25 additions and 11 deletions

View File

@ -1,4 +1,4 @@
SUBDIRS = src tests examples cxxmph man SUBDIRS = src tests examples man $(CXXMPH)
EXTRA_DIST = cmph.spec configure.ac cmph.pc.in LGPL-2 MPL-1.1 EXTRA_DIST = cmph.spec configure.ac cmph.pc.in LGPL-2 MPL-1.1
pkgconfigdir = $(libdir)/pkgconfig pkgconfigdir = $(libdir)/pkgconfig

View File

@ -1,3 +1,11 @@
AC_DEFUN([AC_ENABLE_CXXMPH], [AC_ARG_ENABLE([cxxmph],
[ --enable-cxxmph enable the c++ cxxmph library ],
[case "${enableval}" in
yes) cxxmph=true ;;
no) cxxmph=false ;;
*) AC_MSG_ERROR([bad value ${enableval} for --enable-cxxmph]) ;;
esac],[cxxmph=false])])
AC_DEFUN([AC_CHECK_SPOON], [ AC_DEFUN([AC_CHECK_SPOON], [
AC_ARG_WITH(spoon, [ --with-spoon=SPOON this is inocuous, since the truth is that there is no spoon ]) AC_ARG_WITH(spoon, [ --with-spoon=SPOON this is inocuous, since the truth is that there is no spoon ])
AC_MSG_CHECKING(if there is spoon) AC_MSG_CHECKING(if there is spoon)

View File

@ -1,16 +1,16 @@
dnl Process this file with autoconf to produce a configure script. dnl Process this file with autoconf to produce a configure script.
AC_INIT(Makefile.am) AC_INIT
AM_INIT_AUTOMAKE(cmph, 1.1) AC_CONFIG_SRCDIR([Makefile.am])
AM_CONFIG_HEADER(config.h) AM_INIT_AUTOMAKE(cmph, 1.0)
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_MACRO_DIR([m4])
dnl Checks for programs. dnl Checks for programs.
AC_PROG_AWK AC_PROG_AWK
AC_PROG_CC AC_PROG_CC
AC_PROG_CXX
AC_PROG_INSTALL AC_PROG_INSTALL
AC_PROG_LN_S AC_PROG_LN_S
AC_PROG_LIBTOOL LT_INIT
AC_SYS_EXTRA_LARGEFILE AC_SYS_EXTRA_LARGEFILE
if test "x$ac_cv_sys_largefile_CFLAGS" = "xno" ; then if test "x$ac_cv_sys_largefile_CFLAGS" = "xno" ; then
ac_cv_sys_largefile_CFLAGS="" ac_cv_sys_largefile_CFLAGS=""
@ -26,17 +26,23 @@ CXXFLAGS='-std=c++0x'
LDFLAGS="$LDFLAGS $ac_cv_sys_largefile_LDFLAGS" LDFLAGS="$LDFLAGS $ac_cv_sys_largefile_LDFLAGS"
LIBS="$LIBS $ac_cv_sys_largefile_LIBS" LIBS="$LIBS $ac_cv_sys_largefile_LIBS"
dnl Checks for headers dnl Checks for headers
AC_CHECK_HEADERS([getopt.h math.h]) AC_CHECK_HEADERS([getopt.h math.h])
dnl Checks for libraries. dnl Checks for libraries.
AC_CHECK_LIBM LT_LIB_M
LDFLAGS="$LIBM $LDFLAGS" LDFLAGS="$LIBM $LDFLAGS"
CFLAGS="-Wall -Werror" CFLAGS="-Wall -Werror"
dnl Checks for library functions. AC_PROG_CXX
AC_ENABLE_CXXMPH
if test x$cxxmph = xtrue; then
CXXFLAGS="$CXXFLAGS -std=c++0x"
AC_SUBST([CXXMPH], "cxxmph")
fi
AC_CHECK_SPOON AC_CHECK_SPOON
dnl AC_OUTPUT(Makefile tests/Makefile samples/Makefile) dnl AC_CONFIG_FILES([Makefile tests/Makefile samples/Makefile])
AC_OUTPUT(Makefile src/Makefile cxxmph/Makefile tests/Makefile examples/Makefile man/Makefile cmph.pc) AC_OUTPUT
AC_CONFIG_FILES([Makefile src/Makefile cxxmph/Makefile tests/Makefile examples/Makefile man/Makefile cmph.pc])
AC_OUTPUT