Commit a90642cd authored by Lynn Garren's avatar Lynn Garren
Browse files

using AM_CXXFLAGS and other configure improvements

parent 19627ab1
......@@ -64,7 +64,7 @@ while test $# -gt 0; do
;;
--cppflags)
echo @AM_CPPFLAGS@ @CPPFLAGS@ @Cast_CPPFLAGS@
echo @CPPFLAGS@ @Cast_CPPFLAGS@
;;
--cxxflags)
......@@ -72,7 +72,7 @@ while test $# -gt 0; do
;;
--ldflags)
echo @AM_LDFLAGS@ @LDFLAGS@ @Cast_LDFLAGS@
echo @LDFLAGS@ @Cast_LDFLAGS@
;;
--libs)
......
#! /bin/sh
# run autotool commands
set -x
# cleanup should not be necessary
# however, in some cases strange results are found if you do not start clean
rm -rf autom4te.cache
rm -f aclocal.m4
rm -f Makefile.in */Makefile.in */defs.h.in
rm -f autotools/config* autotools/depcomp autotools/install-sh autotools/m*
rm -f configure config.*
# run autotool commands
aclocal -I autotools
autoheader
automake --add-missing --copy
......
......@@ -51,9 +51,6 @@ AC_SUBST(Cast_CPPFLAGS)
AC_SUBST(Cast_LIBS)
AC_SUBST(Cast_LDFLAGS)
AC_SUBST(COPY_P)
AC_SUBST(DIFF_Q)
# ----------------------------------------------------------------------
# Supply boilerplate for Cast/defs.h source header:
# ----------------------------------------------------------------------
......@@ -117,72 +114,63 @@ AC_LANG(C++)
# Ensure we've found a preprocessor:
AC_REQUIRE_CPP
# worry about compiler flags
# copy and diff
case "$target" in
*-*-win32*)
case "$CXX" in
cl) CXXFLAGS="-DWIN32 -O -GX -GR -MD";COPY_P="copy -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O";COPY_P="copy -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O";COPY_P="copy -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="copy -p";DIFF_Q="diff -q -b"
;;
*-*-cygwin*)
case "$CXX" in
cl) CXXFLAGS="-DWIN32 -O -GX -GR -MD";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -q -b"
;;
*-*-solaris*)
case "$CXX" in
CC) CXXFLAGS="-O";COPY_P="cp -p";DIFF_Q="diff -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -b"
;;
*-*-linux*)
case "$CXX" in
g++) CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
alpha*-dec-osf*)
case "$CXX" in
cxx) CXXFLAGS="-O -std strict_ansi -timplicit_local";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-hpux*)
case "$CXX" in
aCC) CXXFLAGS="-O -Aa +DAportable +Onolimit";COPY_P="cp -p";DIFF_Q="diff -q -b";;
CC) CXXFLAGS="+O3 +DAportable +a1 -z -pta +Onolimit";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-aix*)
case "$CXX" in
xlC) CXXFLAGS="-O3 -qtwolink -+";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-irix*)
case "$CXX" in
CC) CXXFLAGS="-O -OPT:Olimit=0 -pta";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
powerpc-apple-darwin*)
case "$CXX" in
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -q -b"
;;
*)
COPY_P="cp -p";DIFF_Q="diff -q -b"
esac
AC_SUBST(COPY_P)
AC_SUBST(DIFF_Q)
# worry about compiler flags
case "$CXX" in
g++)
case "$target" in
*-*-linux*) AM_CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";;
*) AM_CXXFLAGS="-O -ansi -pedantic -Wall"
esac;;
c++)
case "$target" in
*-*-linux*) AM_CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";;
*) AM_CXXFLAGS="-O -ansi -pedantic -Wall"
esac;;
cl)
AM_CXXFLAGS="-EHsc"
;;
CC)
case "$target" in
*-*-solaris*) AM_CXXFLAGS="-O";DIFF_Q="diff -b";;
*-*-hpux*) AM_CXXFLAGS="+O3 +DAportable +a1 -z -pta +Onolimit";;
*-*-irix*) AM_CXXFLAGS="-O -OPT:Olimit=0 -pta";;
*) echo UNEXPECTED CHOICE OF OPERATING SYSTEM FOR $CXX: $target
esac;;
aCC)
AM_CXXFLAGS="-O -Aa +DAportable +Onolimit"
;;
cxx)
AM_CXXFLAGS="-O -std strict_ansi -timplicit_local"
;;
xlC)
AM_CXXFLAGS="-O3 -qtwolink -+"
;;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac
AC_SUBST(AM_CXXFLAGS)
# ----------------------------------------------------------------------
# Set system-dependent options:
# ----------------------------------------------------------------------
......
#! /bin/sh
# @configure_input@
prefix=@prefix@
exec_prefix=@exec_prefix@
includedir=@includedir@
usage()
{
cat <<EOF
Usage: Evaluator-config [OPTION]
Known values for OPTION are:
--prefix show installation prefix
--cxx print compilation command
--cppflags print pre-processor flags
--cxxflags print C++ compiler flags
--ldflags print linker flags
--libs print libraries to link against
--help display this help and exit
--version output version information
EOF
exit $1
}
if test $# -eq 0; then
usage 1
fi
while test $# -gt 0; do
case "$1" in
-*=*)
optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'`
;;
*)
optarg=
;;
esac
case "$1" in
--prefix=*)
prefix="$optarg"
;;
--prefix)
echo "$prefix"
;;
--version)
echo @PACKAGE@ @VERSION@
exit 0
;;
--help)
usage 0
;;
--cxx)
echo "CXX: " @CXX@
echo "CC: " @CC@
echo "CPP: " @CPP@
echo "CXXCPP: " @CXXCPP@
;;
--cppflags)
echo @CPPFLAGS@ @Evaluator_CPPFLAGS@
;;
--cxxflags)
echo @AM_CXXFLAGS@ @CXXFLAGS@
;;
--ldflags)
echo @LDFLAGS@ @Evaluator_LDFLAGS@
;;
--libs)
echo @LIBS@ @Evaluator_LIBS@ -lm
;;
*)
usage
exit 1
;;
esac
shift
done
exit 0
......@@ -4,6 +4,10 @@ includedir = $(prefix)/include/CLHEP
# put . first so that CLHEP directory is built before anything else
SUBDIRS = Evaluator . src test
# list all subdirectories - for distribution and cleaning
DIST_SUBDIRS = Evaluator . src test
bin_SCRIPTS = Evaluator-config
all-local: $(top_builddir)/CLHEP
......
#! /bin/sh
# run autotool commands
set -x
# cleanup should not be necessary
# however, in some cases strange results are found if you do not start clean
rm -rf autom4te.cache
rm -f aclocal.m4
rm -f Makefile.in */Makefile.in */defs.h.in
rm -f autotools/config* autotools/depcomp autotools/install-sh autotools/m*
rm -f configure config.*
# run autotool commands
aclocal -I autotools
autoheader
automake --add-missing --copy
......
......@@ -34,6 +34,9 @@ AC_CONFIG_FILES([test/Makefile])
AC_CONFIG_FILES([Evaluator-deps])
AC_CONFIG_FILES([Evaluator/copy-header.pl], [chmod +x Evaluator/copy-header.pl])
# Configuration inquiry program/script:
AC_CONFIG_FILES([Evaluator-config], [chmod +x Evaluator-config])
# Test driver program/script:
AC_CONFIG_FILES([test/testEvaluator.sh], [chmod +x test/testEvaluator.sh])
......@@ -49,9 +52,6 @@ AC_SUBST(Evaluator_CPPFLAGS)
AC_SUBST(Evaluator_LIBS)
AC_SUBST(Evaluator_LDFLAGS)
AC_SUBST(COPY_P)
AC_SUBST(DIFF_Q)
# ----------------------------------------------------------------------
# Supply boilerplate for Evaluator/defs.h source header:
# ----------------------------------------------------------------------
......@@ -116,73 +116,63 @@ AC_LANG(C++)
# Ensure we've found a preprocessor:
AC_REQUIRE_CPP
# worry about compiler flags
# copy and diff
case "$target" in
*-*-win32*)
case "$CXX" in
cl) CXXFLAGS="-DWIN32 -O -GX -GR -MD";COPY_P="copy -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O";COPY_P="copy -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O";COPY_P="copy -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="copy -p";DIFF_Q="diff -q -b"
;;
*-*-cygwin*)
case "$CXX" in
cl) CXXFLAGS="-DWIN32 -O -GX -GR -MD";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -q -b"
;;
*-*-solaris*)
case "$CXX" in
CC) CXXFLAGS="-O";COPY_P="cp -p";DIFF_Q="diff -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -b"
;;
*-*-linux*)
case "$CXX" in
g++) CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
alpha*-dec-osf*)
case "$CXX" in
cxx) CXXFLAGS="-O -std strict_ansi -timplicit_local";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-hpux*)
case "$CXX" in
aCC) CXXFLAGS="-O -Aa +DAportable +Onolimit";COPY_P="cp -p";DIFF_Q="diff -q -b";;
CC) CXXFLAGS="+O3 +DAportable +a1 -z -pta +Onolimit";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-aix*)
case "$CXX" in
xlC) CXXFLAGS="-O3 -qtwolink -+";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-irix*)
case "$CXX" in
CC) CXXFLAGS="-O -OPT:Olimit=0 -pta";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
powerpc-apple-darwin*)
case "$CXX" in
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -q -b"
;;
*)
COPY_P="cp -p";DIFF_Q="diff -q -b"
esac
AC_SUBST(COPY_P)
AC_SUBST(DIFF_Q)
# worry about compiler flags
case "$CXX" in
g++)
case "$target" in
*-*-linux*) AM_CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";;
*) AM_CXXFLAGS="-O -ansi -pedantic -Wall"
esac;;
c++)
case "$target" in
*-*-linux*) AM_CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";;
*) AM_CXXFLAGS="-O -ansi -pedantic -Wall"
esac;;
cl)
AM_CXXFLAGS="-EHsc"
;;
CC)
case "$target" in
*-*-solaris*) AM_CXXFLAGS="-O";DIFF_Q="diff -b";;
*-*-hpux*) AM_CXXFLAGS="+O3 +DAportable +a1 -z -pta +Onolimit";;
*-*-irix*) AM_CXXFLAGS="-O -OPT:Olimit=0 -pta";;
*) echo UNEXPECTED CHOICE OF OPERATING SYSTEM FOR $CXX: $target
esac;;
aCC)
AM_CXXFLAGS="-O -Aa +DAportable +Onolimit"
;;
cxx)
AM_CXXFLAGS="-O -std strict_ansi -timplicit_local"
;;
xlC)
AM_CXXFLAGS="-O3 -qtwolink -+"
;;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac
AC_SUBST(AM_CXXFLAGS)
# ----------------------------------------------------------------------
# Set system-dependent options:
# ----------------------------------------------------------------------
......
......@@ -64,7 +64,7 @@ while test $# -gt 0; do
;;
--cppflags)
echo @AM_CPPFLAGS@ @CPPFLAGS@ @Exceptions_CPPFLAGS@
echo @CPPFLAGS@ @Exceptions_CPPFLAGS@
;;
--cxxflags)
......@@ -72,7 +72,7 @@ while test $# -gt 0; do
;;
--ldflags)
echo @AM_LDFLAGS@ @LDFLAGS@ @Exceptions_LDFLAGS@
echo @LDFLAGS@ @Exceptions_LDFLAGS@
;;
--libs)
......
#! /bin/sh
# run autotool commands
set -x
# cleanup should not be necessary
# however, in some cases strange results are found if you do not start clean
rm -rf autom4te.cache
rm -f aclocal.m4
rm -f Makefile.in */Makefile.in */defs.h.in
rm -f autotools/config* autotools/depcomp autotools/install-sh autotools/m*
rm -f configure config.*
# run autotool commands
aclocal -I autotools
autoheader
automake --add-missing --copy
......
......@@ -61,9 +61,6 @@ AC_SUBST(Exceptions_CPPFLAGS)
AC_SUBST(Exceptions_LIBS)
AC_SUBST(Exceptions_LDFLAGS)
AC_SUBST(COPY_P)
AC_SUBST(DIFF_Q)
# ----------------------------------------------------------------------
# Supply boilerplate for Exceptions/defs.h source header:
# ----------------------------------------------------------------------
......@@ -127,72 +124,63 @@ AC_LANG(C++)
# Ensure we've found a preprocessor:
AC_REQUIRE_CPP
# worry about compiler flags
# copy and diff
case "$target" in
*-*-win32*)
case "$CXX" in
cl) CXXFLAGS="-DWIN32 -O -GX -GR -MD";COPY_P="copy -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O";COPY_P="copy -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O";COPY_P="copy -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="copy -p";DIFF_Q="diff -q -b"
;;
*-*-cygwin*)
case "$CXX" in
cl) CXXFLAGS="-DWIN32 -O -GX -GR -MD";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -q -b"
;;
*-*-solaris*)
case "$CXX" in
CC) CXXFLAGS="-O";COPY_P="cp -p";DIFF_Q="diff -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -b"
;;
*-*-linux*)
case "$CXX" in
g++) CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
alpha*-dec-osf*)
case "$CXX" in
cxx) CXXFLAGS="-O -std strict_ansi -timplicit_local";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-hpux*)
case "$CXX" in
aCC) CXXFLAGS="-O -Aa +DAportable +Onolimit";COPY_P="cp -p";DIFF_Q="diff -q -b";;
CC) CXXFLAGS="+O3 +DAportable +a1 -z -pta +Onolimit";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-aix*)
case "$CXX" in
xlC) CXXFLAGS="-O3 -qtwolink -+";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
*-*-irix*)
case "$CXX" in
CC) CXXFLAGS="-O -OPT:Olimit=0 -pta";COPY_P="cp -p";DIFF_Q="diff -q -b";;
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
powerpc-apple-darwin*)
case "$CXX" in
g++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
c++) CXXFLAGS="-O -ansi -pedantic -Wall";COPY_P="cp -p";DIFF_Q="diff -q -b";;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac;;
COPY_P="cp -p";DIFF_Q="diff -q -b"
;;
*)
COPY_P="cp -p";DIFF_Q="diff -q -b"
esac
AC_SUBST(COPY_P)
AC_SUBST(DIFF_Q)
# worry about compiler flags
case "$CXX" in
g++)
case "$target" in
*-*-linux*) AM_CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";;
*) AM_CXXFLAGS="-O -ansi -pedantic -Wall"
esac;;
c++)
case "$target" in
*-*-linux*) AM_CXXFLAGS="-O -ansi -pedantic -Wall -D_GNU_SOURCE";;
*) AM_CXXFLAGS="-O -ansi -pedantic -Wall"
esac;;
cl)
AM_CXXFLAGS="-EHsc"
;;
CC)
case "$target" in
*-*-solaris*) AM_CXXFLAGS="-O";DIFF_Q="diff -b";;
*-*-hpux*) AM_CXXFLAGS="+O3 +DAportable +a1 -z -pta +Onolimit";;
*-*-irix*) AM_CXXFLAGS="-O -OPT:Olimit=0 -pta";;
*) echo UNEXPECTED CHOICE OF OPERATING SYSTEM FOR $CXX: $target
esac;;
aCC)
AM_CXXFLAGS="-O -Aa +DAportable +Onolimit"
;;
cxx)
AM_CXXFLAGS="-O -std strict_ansi -timplicit_local"
;;
xlC)
AM_CXXFLAGS="-O3 -qtwolink -+"
;;
*) echo UNEXPECTED CHOICE OF C++ COMPILER: $CXX
esac
AC_SUBST(AM_CXXFLAGS)
# ----------------------------------------------------------------------
# Set system-dependent options:
# ----------------------------------------------------------------------
......
#! /bin/sh
# @configure_input@
prefix=@prefix@
exec_prefix=@exec_prefix@
includedir=@includedir@
usage()
{
cat <<EOF
Usage: GenericFunctions-config [OPTION]
Known values for OPTION are:
--prefix show installation prefix
--cxx print compilation command
--cppflags print pre-processor flags
--cxxflags print C++ compiler flags
--ldflags print linker flags
--libs print libraries to link against
--help display this help and exit
--version output version information
EOF
exit $1
}
if test $# -eq 0; then
usage 1
fi
while test $# -gt 0; do
case "$1" in
-*=*)
optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'`
;;
*)
optarg=
;;
esac
case "$1" in