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
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_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)

View File

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