CC = @CC@
CXX = @CXX@
GXX-VERSION = @GXX_VERSION@
+LDFLAGS = @LDFLAGS@
+LIBS = @LIBS@
PERL = @PERL@
enable-multithreading= @enablemultithreading@
with-multithreading = @withmultithreading@
LIBPATH += $(addprefix -L,$(lib-path-base) $(lib-path-lac) $(lib-path-deal2))
+# DEAL.II libraries are found by the Makefile, so no -L option is needed
+#LIBS += $(LIBPATH)
# add search path for libraries for make dependencies
$(include-path-deal2))
# compiler flags for debug and optimized mode
-CXXFLAGS.g = @DEFS@ @CXXFLAGSG@ $(INCLUDE) $(LIBPATH)
-CXXFLAGS.o = @DEFS@ @CXXFLAGSO@ $(INCLUDE) $(LIBPATH)
+CXXFLAGS.g = @DEFS@ @CXXFLAGSG@ $(INCLUDE)
+CXXFLAGS.o = @DEFS@ @CXXFLAGSO@ $(INCLUDE)
# if multithread support in the library is requested, then set the
+++ /dev/null
-############################################################
-# Directory with the DEAL distribution
-############################################################
-
-D = please/enter/here/path/to/newdeal
-
-
-############################################################
-# Include general settings for including DEAL libraries
-############################################################
-
-include $D/common/Make.global_options
-
-
-############################################################
-# Set debug-mode as a default
-############################################################
-
-debug-mode = on
-
-
-############################################################
-# Define library names
-############################################################
-
-libs = -ldeal_II_2d -llac -lbase
-libs.g = -ldeal_II_2d.g -llac.g -lbase.g
-
-
-############################################################
-# Select compiler flags according to debug-mode
-############################################################
-
-ifeq ($(debug-mode),on)
-libraries = $(libs.g)
-flags = $(CXXFLAGS.g)
-endif
-
-ifeq ($(debug-mode),off)
-libraries = $(libs)
-flags = $(CXXFLAGS.o)
-endif
-
-
-############################################################
-# Typical block for building a running program
-#
-# 1. provide a list of source files in ...-cc-files
-#
-# 2. generate the list of object files according to debug-mode
-#
-# 3. make executable
-#
-# 4. Explicit dependencies of object files (will be automatic soon)
-#
-############################################################
-
-target1-cc-files = t1.cc t2.cc t3.cc
-
-ifeq ($(debug-mode),on)
-target1-o-files = $(target1-cc-files:.cc=.go)
-else
-target1-o-files = $(target1-cc-files:.cc=.o)
-endif
-
-target1: $(target1-o-files) $(libraries)
- $(CXX) $(CXXFLAGS) $(flags) -o $@ $^
-
-############################################################
-# Continue with other targets if needed
-############################################################
-
-
-
-
-############################################################
-# Cleanup targets
-############################################################
-
-clean:
- rm -f *.o *.go
-
-veryclean: clean
- rm -f target1 *.inp *.gpl *.eps *.gnuplot
-
-############################################################
-# Automatic generation of dependencies
-############################################################
-
-all-cc-files = $(target1-cc-files) # $(target2-cc-files) ...
-
-Make.depend: $(all-cc-files)
- @echo =====Dependecies=== Make.depend
- @$(CXX) $(flags) $^ -M > $@
- @perl -pi~ -e 's/(^[^.]+)\.o:/\1.o \1.go:/;' $@
-
-include Make.depend
--- /dev/null
+# Directory with the DEAL distribution
+
+D = @DEAL2_DIR@
+
+
+# Include general rules for making deal.II object files
+
+include $D/common/Make.rules
+
+# Set debug-mode as a default.
+# You may replace this by by a command line argument debug-mode=off
+
+debug-mode = on
+
+
+# Define library names. Using these variables automatically selects
+# the proper names for shared or static libraries.
+#
+# Here, the version for 2d. Replace 2d by 3d or add $(lib-deal2-3d.o)
+# when needed.
+
+libs = $(lib-deal2-2d.o) $(lib-lac.o) $(lib-base.o)
+libs.g = $(lib-deal2-2d.g) $(lib-lac.g) $(lib-base.g)
+
+# Select compiler flags according to debug-mode
+# and allow for additional CXXFLAGS.
+
+
+ifeq ($(debug-mode),on)
+libraries = $(libs.g)
+flags = $(CXXFLAGS.g) $(CXXFLAGS)
+endif
+
+ifeq ($(debug-mode),off)
+libraries = $(libs)
+flags = $(CXXFLAGS.o) $(CXXFLAGS)
+endif
+
+
+# Typical block for building a running program called target1
+#
+# 1. provide a list of source files in ...-cc-files
+# If you have several targets in one directory, replace
+# the shell command by an explicit list of .cc-files.
+
+target1-cc-files = $(shell echo *.cc)
+
+# 2. generate the list of object files according to debug-mode
+
+ifeq ($(debug-mode),on)
+target1-o-files = $(target1-cc-files:.cc=.g.o)
+else
+target1-o-files = $(target1-cc-files:.cc=.o)
+endif
+
+# 3. make executable
+# Use extra libraries and linker flags as configured. We
+# always add -g to keep debug symbols. Use strip for smaller
+# executables.
+
+target1: $(target1-o-files) $(libraries)
+ $(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
+
+# Copy this block for all your targets and replace "target1" by a proper name.
+
+# Cleanup targets
+
+clean:
+ rm -f *.o *.go
+
+veryclean: clean
+ rm -f target1 *.inp *.gpl *.eps *.gnuplot
+
+
+
ac_help=
ac_default_prefix=/usr/local
# Any additions from configure.in:
+ac_help="$ac_help
+ --enable-shared Set compiler flags to generate shared libraries"
ac_help="$ac_help
--enable-multithreading Set compiler flags to allow for multithreaded programs"
ac_help="$ac_help
--with-multithreading=DIR use DIR as path to the ACE library"
ac_help="$ac_help
- --enable-shared Set compiler flags to generate shared libraries"
+ --with-blas=LIB use the BLAS-library file LIB"
+ac_help="$ac_help
+ --with-lapack=LIB use the LAPACK-library file LIB"
ac_help="$ac_help
--enable-multigrid Include multigrid code in library"
ac_help="$ac_help
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:607: checking host system type" >&5
+echo "configure:611: checking host system type" >&5
host_alias=$host
case "$host_alias" in
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:628: checking target system type" >&5
+echo "configure:632: checking target system type" >&5
target_alias=$target
case "$target_alias" in
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:646: checking build system type" >&5
+echo "configure:650: checking build system type" >&5
build_alias=$build
case "$build_alias" in
+# Check whether --enable-shared or --disable-shared was given.
+if test "${enable_shared+set}" = set; then
+ enableval="$enable_shared"
+ enableshared=$enableval
+else
+ enableshared=yes
+fi
+
+
+case "$target" in
+ *-aix* | alpha*-linux* )
+ echo "configure: warning: Shared libraries not supported on $target. Using static libs instead" 1>&2
+ enableshared=no
+ ;;
+esac
+
+
+if test $enableshared = yes ; then
+ echo "$ac_t""Configuring for shared libraries" 1>&6
+ CFLAGS="$CFLAGS -fPIC"
+ CXXFLAGS="$CXXFLAGS -fPIC"
+ LDFLAGS="$LDFLAGS -fPIC"
+
+ lib_suffix=.so;
+else
+ echo "$ac_t""Configuring for static libraries" 1>&6
+ CFLAGS="$CFLAGS "
+ CXXFLAGS="$CXXFLAGS "
+ LDFLAGS="$LDFLAGS "
+
+ lib_suffix=.a;
+fi
+
+
+
+
+
+
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:685: checking for $ac_word" >&5
+echo "configure:727: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:715: checking for $ac_word" >&5
+echo "configure:757: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:766: checking for $ac_word" >&5
+echo "configure:808: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:798: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:840: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 809 "configure"
+#line 851 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:814: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:856: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:840: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:882: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:845: checking whether we are using GNU C" >&5
+echo "configure:887: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:854: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:896: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:873: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:915: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$CC", so it can be a program name with args.
set dummy $CC; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:907: checking for $ac_word" >&5
+echo "configure:949: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
+
for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:946: checking for $ac_word" >&5
+echo "configure:989: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:978: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
+echo "configure:1021: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 989 "configure"
+#line 1032 "configure"
#include "confdefs.h"
int main(){return(0);}
EOF
-if { (eval echo configure:994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cxx_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1020: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1063: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
cross_compiling=$ac_cv_prog_cxx_cross
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
-echo "configure:1025: checking whether we are using GNU C++" >&5
+echo "configure:1068: checking whether we are using GNU C++" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1034: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1077: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gxx=yes
else
ac_cv_prog_gxx=no
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS=
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
-echo "configure:1053: checking whether ${CXX-g++} accepts -g" >&5
+echo "configure:1096: checking whether ${CXX-g++} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$CXX", so it can be a program name with args.
set dummy $CXX; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1087: checking for $ac_word" >&5
+echo "configure:1130: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_CXX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1146: checking for $ac_word" >&5
+echo "configure:1189: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test $GXX = yes ; then
- CXXFLAGSO="-O2 -Wuninitialized -felide-constructors -fnonnull-objects -ftemplate-depth-32"
- CXXFLAGSG="-DDEBUG -ggdb -ansi -pedantic -Wall -W -Wtraditional -Wpointer-arith -Wbad-function-cast -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline -Woverloaded-virtual -Wstrict-prototypes -Wsynth -Wsign-compare -Wconversion -ftemplate-depth-32"
+ CXXFLAGSO="$CXXFLAGS -O2 -Wuninitialized -felide-constructors -fnonnull-objects -ftemplate-depth-32"
+ CXXFLAGSG="$CXXFLAGS -DDEBUG -ggdb -ansi -pedantic -Wall -W -Wtraditional -Wpointer-arith -Wbad-function-cast -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline -Woverloaded-virtual -Wstrict-prototypes -Wsynth -Wsign-compare -Wconversion -ftemplate-depth-32"
case "$GXXVERSION" in
if test $enablemultithreading = yes ; then
echo $ac_n "checking for platform specific thread flags""... $ac_c" 1>&6
-echo "configure:1231: checking for platform specific thread flags" >&5
+echo "configure:1274: checking for platform specific thread flags" >&5
for i in threads mt pthread pthreads mthreads Kthread kthread; do
CXXFLAGS="$CXXFLAGSG -$i"
cat > conftest.$ac_ext <<EOF
-#line 1236 "configure"
+#line 1279 "configure"
#include "confdefs.h"
int main() {
;
; return 0; }
EOF
-if { (eval echo configure:1243: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1286: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
thread_flag=$i
echo $ac_n "checking for platform specific multi-threading defines""... $ac_c" 1>&6
-echo "configure:1262: checking for platform specific multi-threading defines" >&5
+echo "configure:1305: checking for platform specific multi-threading defines" >&5
cat > conftest.$ac_ext <<EOF
-#line 1265 "configure"
+#line 1308 "configure"
#include "confdefs.h"
#if !defined (_REENTRANT) && !defined (_THREAD_SAFE)
; return 0; }
EOF
-if { (eval echo configure:1279: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1322: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo "$ac_t"""not necessary"" 1>&6
rm -f conftest*
- CXXFLAGSG="$CXXFLAGSG -D__USE_MALLOC"
- CXXFLAGSO="$CXXFLAGSO -D__USE_MALLOC"
+ cat >> confdefs.h <<\EOF
+#define __USE_MALLOC 1
+EOF
+
CXXFLAGSG="`echo $CXXFLAGSG | perl -pi -e 's/-ansi//g;'`"
fi
if test $withmultithreading != no ; then
echo $ac_n "checking for ACE""... $ac_c" 1>&6
-echo "configure:1315: checking for ACE" >&5
+echo "configure:1360: checking for ACE" >&5
if test -d $withmultithreading ; then
echo "$ac_t""found" 1>&6
else
{ echo "configure: error: Invalid ACE path" 1>&2; exit 1; }
fi
- CXXFLAGSG="$CXXFLAGSG -DDEAL_II_USE_MT"
- CXXFLAGSO="$CXXFLAGSO -DDEAL_II_USE_MT"
+ cat >> confdefs.h <<\EOF
+#define DEAL_II_USE_MT 1
+EOF
+
fi
+# Check whether --with-blas or --without-blas was given.
+if test "${with_blas+set}" = set; then
+ withval="$with_blas"
+ if test $withval != no ; then
+ echo $ac_n "checking for BLAS""... $ac_c" 1>&6
+echo "configure:1380: checking for BLAS" >&5
+ if test -r $withval ; then
+ echo "$ac_t""found" 1>&6
+ else
+ echo "$ac_t""not found" 1>&6
+ { echo "configure: error: BLAS library $withval not readable" 1>&2; exit 1; }
+ fi
+ cat >> confdefs.h <<\EOF
+#define HAVE_LIBBLAS 1
+EOF
+ LIBS="$withval -lg2c $LIBS";
+ fi
+
+else
+ echo $ac_n "checking for main in -lblas""... $ac_c" 1>&6
+echo "configure:1396: checking for main in -lblas" >&5
+ac_lib_var=`echo blas'_'main | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ ac_save_LIBS="$LIBS"
+LIBS="-lblas $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1404 "configure"
+#include "confdefs.h"
-# Check whether --enable-shared or --disable-shared was given.
-if test "${enable_shared+set}" = set; then
- enableval="$enable_shared"
- enableshared=$enableval
+int main() {
+main()
+; return 0; }
+EOF
+if { (eval echo configure:1411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=yes"
else
- enableshared=yes
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=no"
fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ LIBS="-lblas -lg2c $LIBS" ; cat >> confdefs.h <<\EOF
+#define HAVE_LIBBLAS 1
+EOF
-case "$target" in
- *-aix* | alpha*-linux* )
- echo "configure: warning: Shared libraries not supported on $target. Using static libs instead" 1>&2
- enableshared=no
- ;;
-esac
+else
+ echo "$ac_t""no" 1>&6
+fi
-if test $enableshared = yes ; then
- echo "$ac_t""Configuring for shared libraries" 1>&6
- CXXFLAGSG="$CXXFLAGSG -fPIC"
- CXXFLAGSO="$CXXFLAGSO -fPIC"
+fi
- lib_suffix=.so;
+
+# Check whether --with-lapack or --without-lapack was given.
+if test "${with_lapack+set}" = set; then
+ withval="$with_lapack"
+ if test $withval != no ; then
+ echo $ac_n "checking for LAPACK""... $ac_c" 1>&6
+echo "configure:1443: checking for LAPACK" >&5
+ if test -r $withval ; then
+ echo "$ac_t""found" 1>&6
+ else
+ echo "$ac_t""not found" 1>&6
+ { echo "configure: error: LAPACK library $withval not readable" 1>&2; exit 1; }
+ fi
+ cat >> confdefs.h <<\EOF
+#define HAVE_LIBLAPACK 1
+EOF
+
+ LIBS="$withval $LIBS";
+ fi
+
else
- echo "$ac_t""Configuring for static libraries" 1>&6
+ echo $ac_n "checking for dgels_ in -llapack""... $ac_c" 1>&6
+echo "configure:1459: checking for dgels_ in -llapack" >&5
+ac_lib_var=`echo lapack'_'dgels_ | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ ac_save_LIBS="$LIBS"
+LIBS="-llapack $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1467 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char dgels_();
- lib_suffix=.a;
+int main() {
+dgels_()
+; return 0; }
+EOF
+if { (eval echo configure:1481: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=yes"
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=no"
fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_tr_lib=HAVE_LIB`echo lapack | sed -e 's/^a-zA-Z0-9_/_/g' \
+ -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
+ cat >> confdefs.h <<EOF
+#define $ac_tr_lib 1
+EOF
+ LIBS="-llapack $LIBS"
+else
+ echo "$ac_t""no" 1>&6
+$LIBS
+fi
-
+fi
fi
echo $ac_n "checking for kdoc""... $ac_c" 1>&6
-echo "configure:1401: checking for kdoc" >&5
+echo "configure:1548: checking for kdoc" >&5
if test $kdocdir != ${DEAL2_DIR}/contrib/kdoc/bin ; then
if test -r $kdocdir/kdoc ; then
echo "$ac_t""found" 1>&6
# Extract the first word of ""doc++"", so it can be a program name with args.
set dummy "doc++"; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1437: checking for $ac_word" >&5
+echo "configure:1584: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_docxx'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
else
echo $ac_n "checking for doc++""... $ac_c" 1>&6
-echo "configure:1471: checking for doc++" >&5
+echo "configure:1618: checking for doc++" >&5
if test -x "$docxx" ; then
echo "$ac_t""yes" 1>&6
else
echo $ac_n "checking whether getrusage is properly declared""... $ac_c" 1>&6
-echo "configure:1486: checking whether getrusage is properly declared" >&5
+echo "configure:1633: checking whether getrusage is properly declared" >&5
ac_ext=C
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
ac_cpp='$CXXCPP $CPPFLAGS'
cat > conftest.$ac_ext <<EOF
-#line 1496 "configure"
+#line 1643 "configure"
#include "confdefs.h"
#include <sys/resource.h>
; return 0; }
EOF
-if { (eval echo configure:1508: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1655: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo "$ac_t"""yes"" 1>&6
rm -f conftest*
echo $ac_n "checking whether isnan is declared with debug flags""... $ac_c" 1>&6
-echo "configure:1526: checking whether isnan is declared with debug flags" >&5
+echo "configure:1673: checking whether isnan is declared with debug flags" >&5
CXXFLAGS=$CXXFLAGSG
cat > conftest.$ac_ext <<EOF
-#line 1530 "configure"
+#line 1677 "configure"
#include "confdefs.h"
#include <cmath>
; return 0; }
EOF
-if { (eval echo configure:1542: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1689: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo "$ac_t"""yes"" 1>&6
for testflag in -D_ISOC99_SOURCE -D__EXTENSIONS__ ; do
CXXFLAGS="$CXXFLAGSG $testflag"
cat > conftest.$ac_ext <<EOF
-#line 1556 "configure"
+#line 1703 "configure"
#include "confdefs.h"
#include <cmath>
; return 0; }
EOF
-if { (eval echo configure:1568: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1715: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
deal_II_isnan_flag=$testflag
rm -f conftest*
echo $ac_n "checking whether isnan is declared with optimized flags""... $ac_c" 1>&6
-echo "configure:1596: checking whether isnan is declared with optimized flags" >&5
+echo "configure:1743: checking whether isnan is declared with optimized flags" >&5
CXXFLAGS=$CXXFLAGSO
cat > conftest.$ac_ext <<EOF
-#line 1600 "configure"
+#line 1747 "configure"
#include "confdefs.h"
#include <cmath>
; return 0; }
EOF
-if { (eval echo configure:1612: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1759: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo "$ac_t"""yes"" 1>&6
for testflag in -D_ISOC99_SOURCE -D__EXTENSIONS__ ; do
CXXFLAGS="$CXXFLAGSO $testflag"
cat > conftest.$ac_ext <<EOF
-#line 1626 "configure"
+#line 1773 "configure"
#include "confdefs.h"
#include <cmath>
; return 0; }
EOF
-if { (eval echo configure:1638: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1785: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
deal_II_isnan_flag=$testflag
case "$target" in
alpha*-linux*)
- CXXFLAGSG="$CXXFLAGSG -DNO_THROW"
- CXXFLAGSO="$CXXFLAGSO -DNO_THROW"
+ cat >> confdefs.h <<\EOF
+#define NO_THROW 1
+EOF
+
;;
esac
-echo $ac_n "checking for consistency of CXXFLAGSG flags""... $ac_c" 1>&6
-echo "configure:1681: checking for consistency of CXXFLAGSG flags" >&5
CXXFLAGS="$CXXFLAGSG"
+echo $ac_n "checking for consistency of CXXFLAGSG flags""... $ac_c" 1>&6
+echo "configure:1831: checking for consistency of CXXFLAGSG flags" >&5
cat > conftest.$ac_ext <<EOF
-#line 1684 "configure"
+#line 1833 "configure"
#include "confdefs.h"
int main() {
;
; return 0; }
EOF
-if { (eval echo configure:1691: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1840: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo "$ac_t""yes" 1>&6
fi
rm -f conftest*
-echo $ac_n "checking for consistency of CXXFLAGSO flags""... $ac_c" 1>&6
-echo "configure:1708: checking for consistency of CXXFLAGSO flags" >&5
CXXFLAGS="$CXXFLAGSO"
+echo $ac_n "checking for consistency of CXXFLAGSO flags""... $ac_c" 1>&6
+echo "configure:1858: checking for consistency of CXXFLAGSO flags" >&5
cat > conftest.$ac_ext <<EOF
-#line 1711 "configure"
+#line 1860 "configure"
#include "confdefs.h"
int main() {
;
; return 0; }
EOF
-if { (eval echo configure:1718: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1867: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo "$ac_t""yes" 1>&6
-
-
-
-
subdirs="tests contrib"
ac_given_srcdir=$srcdir
-trap 'rm -fr `echo "common/Make.global_options doc/Makefile doc/auto/Makefile doc/auto/kdoc/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+trap 'rm -fr `echo "common/Make.global_options common/Makefile.template doc/Makefile doc/auto/Makefile doc/auto/kdoc/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
EOF
cat >> $CONFIG_STATUS <<EOF
s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
+s%@enableshared@%$enableshared%g
+s%@lib_suffix@%$lib_suffix%g
s%@CC@%$CC%g
s%@CXX@%$CXX%g
s%@GXX_VERSION@%$GXX_VERSION%g
s%@CXXFLAGSO@%$CXXFLAGSO%g
s%@enablemultithreading@%$enablemultithreading%g
s%@withmultithreading@%$withmultithreading%g
-s%@enableshared@%$enableshared%g
-s%@lib_suffix@%$lib_suffix%g
s%@enablemultigrid@%$enablemultigrid%g
s%@kdocdir@%$kdocdir%g
s%@kdocversion@%$kdocversion%g
cat >> $CONFIG_STATUS <<EOF
-CONFIG_FILES=\${CONFIG_FILES-"common/Make.global_options doc/Makefile doc/auto/Makefile doc/auto/kdoc/Makefile"}
+CONFIG_FILES=\${CONFIG_FILES-"common/Make.global_options common/Makefile.template doc/Makefile doc/auto/Makefile doc/auto/kdoc/Makefile"}
EOF
cat >> $CONFIG_STATUS <<\EOF
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
+dnl -------------------------------------------------------------
+dnl Test whether shared libraries support is requested.
+dnl Default is yes, but value will be adjusted to operating system
+dnl below.
+dnl This has been moved before the compiler section, so CXXFLAGS and
+dnl LDFLAGS can be set accordingly
+dnl -------------------------------------------------------------
+AC_ARG_ENABLE(shared,
+[ --enable-shared Set compiler flags to generate shared libraries],
+ enableshared=$enableval,
+ enableshared=yes)
+
+dnl On AIX and alpha, shared libs don't work for us at present, so
+dnl disable them (we should probably use libtool there)
+case "$target" in
+ *-aix* | alpha*-linux* )
+ AC_MSG_WARN(Shared libraries not supported on $target. Using static libs instead)
+ enableshared=no
+ ;;
+esac
+
+
+dnl Set compile flags accordingly
+if test $enableshared = yes ; then
+ AC_MSG_RESULT(Configuring for shared libraries)
+ CFLAGS="$CFLAGS -fPIC"
+ CXXFLAGS="$CXXFLAGS -fPIC"
+ LDFLAGS="$LDFLAGS -fPIC"
+
+ lib_suffix=.so;
+else
+ AC_MSG_RESULT(Configuring for static libraries)
+dnl Define these variables so they are not filled with default values later
+ CFLAGS="$CFLAGS "
+ CXXFLAGS="$CXXFLAGS "
+ LDFLAGS="$LDFLAGS "
+
+ lib_suffix=.a;
+fi
+
+
+AC_SUBST(enableshared)
+AC_SUBST(lib_suffix)
+
+
dnl -------------------------------------------------------------
dnl Find external programs
dnl -------------------------------------------------------------
AC_PATH_PROG(CC,$CC)
+
dnl Find the right C++ compiler. This modifies the following
dnl variables: CXX, GXX, CXXFLAGS
AC_PROG_CXX
dnl -------------------------------------------------------------
if test $GXX = yes ; then
- CXXFLAGSO="-O2 -Wuninitialized -felide-constructors -fnonnull-objects -ftemplate-depth-32"
- CXXFLAGSG="-DDEBUG -ggdb -ansi -pedantic -Wall -W -Wtraditional -Wpointer-arith -Wbad-function-cast -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline -Woverloaded-virtual -Wstrict-prototypes -Wsynth -Wsign-compare -Wconversion -ftemplate-depth-32"
+ CXXFLAGSO="$CXXFLAGS -O2 -Wuninitialized -felide-constructors -fnonnull-objects -ftemplate-depth-32"
+ CXXFLAGSG="$CXXFLAGS -DDEBUG -ggdb -ansi -pedantic -Wall -W -Wtraditional -Wpointer-arith -Wbad-function-cast -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline -Woverloaded-virtual -Wstrict-prototypes -Wsynth -Wsign-compare -Wconversion -ftemplate-depth-32"
dnl set some flags that are specific to some versions of the
dnl compiler:
DEAL_II_GET_THREAD_FLAGS
DEAL_II_THREAD_CPPFLAGS
- CXXFLAGSG="$CXXFLAGSG -D__USE_MALLOC"
- CXXFLAGSO="$CXXFLAGSO -D__USE_MALLOC"
+ AC_DEFINE(__USE_MALLOC)
CXXFLAGSG="`echo $CXXFLAGSG | perl -pi -e 's/-ansi//g;'`"
fi
AC_MSG_ERROR(Invalid ACE path)
fi
- CXXFLAGSG="$CXXFLAGSG -DDEAL_II_USE_MT"
- CXXFLAGSO="$CXXFLAGSO -DDEAL_II_USE_MT"
+ AC_DEFINE(DEAL_II_USE_MT)
fi
AC_SUBST(withmultithreading)
-
-
-dnl -------------------------------------------------------------
-dnl Test whether shared libraries support is requested.
-dnl Default is yes, but value will be adjusted to operating system
-dnl below.
-dnl -------------------------------------------------------------
-AC_ARG_ENABLE(shared,
-[ --enable-shared Set compiler flags to generate shared libraries],
- enableshared=$enableval,
- enableshared=yes)
-
-dnl On AIX and alpha, shared libs don't work for us at present, so
-dnl disable them (we should probably use libtool there)
-case "$target" in
- *-aix* | alpha*-linux* )
- AC_MSG_WARN(Shared libraries not supported on $target. Using static libs instead)
- enableshared=no
- ;;
-esac
-
-
-dnl Set compile flags accordingly
-if test $enableshared = yes ; then
- AC_MSG_RESULT(Configuring for shared libraries)
- CXXFLAGSG="$CXXFLAGSG -fPIC"
- CXXFLAGSO="$CXXFLAGSO -fPIC"
-
- lib_suffix=.so;
-else
- AC_MSG_RESULT(Configuring for static libraries)
-
- lib_suffix=.a;
-fi
-
-
-AC_SUBST(enableshared)
-AC_SUBST(lib_suffix)
-
-
-
+dnl ------------------------------------------------------------
+dnl Check for LAPACK and BLAS
+dnl Consider this part experimental!
+dnl ------------------------------------------------------------
+AC_ARG_WITH(blas,
+[ --with-blas=LIB use the BLAS-library file LIB],
+ if test $withval != no ; then
+ AC_MSG_CHECKING(for BLAS)
+ if test -r $withval ; then
+ AC_MSG_RESULT(found)
+ else
+ AC_MSG_RESULT(not found)
+ AC_MSG_ERROR(BLAS library $withval not readable)
+ fi
+ AC_DEFINE(HAVE_LIBBLAS)
+ LIBS="$withval -lg2c $LIBS";
+ fi
+ ,
+ AC_CHECK_LIB(blas,
+ main,
+ LIBS="-lblas -lg2c $LIBS" ; AC_DEFINE(HAVE_LIBBLAS))
+)
+
+AC_ARG_WITH(lapack,
+[ --with-lapack=LIB use the LAPACK-library file LIB],
+ if test $withval != no ; then
+ AC_MSG_CHECKING(for LAPACK)
+ if test -r $withval ; then
+ AC_MSG_RESULT(found)
+ else
+ AC_MSG_RESULT(not found)
+ AC_MSG_ERROR(LAPACK library $withval not readable)
+ fi
+ AC_DEFINE(HAVE_LIBLAPACK)
+ LIBS="$withval $LIBS";
+ fi
+ ,
+ AC_CHECK_LIB(lapack, dgels_,,$LIBS)
+)
dnl -------------------------------------------------------------
dnl Multigrid
dnl -------------------------------------------------------------
dnl Test if multigrid should be enabled
-dnl default is no
-dnl
-dnl ??Is this still the present state??
-dnl
+dnl default is yes if multigrid directory present
AC_ARG_ENABLE(multigrid,
[ --enable-multigrid Include multigrid code in library],
enablemultigrid=$enableval,
dnl On Alpha, there was an internal compiler error in exceptions.h.
dnl Disable "throw" for this platform
alpha*-linux*)
- CXXFLAGSG="$CXXFLAGSG -DNO_THROW"
- CXXFLAGSO="$CXXFLAGSO -DNO_THROW"
+ AC_DEFINE(NO_THROW)
;;
esac
dnl -------------------------------------------------------------
dnl Last check: test whether CXXFLAGS are ok
dnl -------------------------------------------------------------
-AC_MSG_CHECKING(for consistency of CXXFLAGSG flags)
CXXFLAGS="$CXXFLAGSG"
+AC_MSG_CHECKING(for consistency of CXXFLAGSG flags)
AC_TRY_COMPILE(
[],
[;],
exit 1;
])
-AC_MSG_CHECKING(for consistency of CXXFLAGSO flags)
CXXFLAGS="$CXXFLAGSO"
+AC_MSG_CHECKING(for consistency of CXXFLAGSO flags)
AC_TRY_COMPILE(
[],
[;],
-
-
-
-
dnl -------------------------------------------------------------
dnl Configure other packages
dnl -------------------------------------------------------------
dnl -------------------------------------------------------------
dnl Write output to the global options file
-AC_OUTPUT(common/Make.global_options doc/Makefile doc/auto/Makefile doc/auto/kdoc/Makefile)
+AC_OUTPUT(common/Make.global_options common/Makefile.template doc/Makefile doc/auto/Makefile doc/auto/kdoc/Makefile)
include $D/common/Make.global_options
-default: makefiles.html makefile.small.html makefile.large.html
+default: makefiles.html makefile.small.html makefile.large.html makefile.rules.html
makefiles.html: Makefile makefiles.1.html $D/common/Make.global_options makefiles.2.html
@echo '<li><code>INCLUDE=$(INCLUDE)</code>' >> $@
@echo '<li><code>CXXFLAGS.g=$(CXXFLAGS.g)</code>' >> $@
@echo '<li><code>CXXFLAGS.o=$(CXXFLAGS.o)</code>' >> $@
+ @echo '<li><code>LDFLAGS=$(LDFLAGS)</code>' >> $@
+ @echo '<li><code>LIBS=$(LIBS)</code>' >> $@
@echo '<li><code>ACE_ROOT=$(ACE_ROOT)</code>' >> $@
@echo '<li><code>lib-ACE=$(lib-ACE)</code>' >> $@
@echo '<li><code>with-multithreading=$(with-multithreading)</code>' >> $@
makefile.large.html: Makefile.large
@$(PERL) makefile2html < $< > $@
+makefile.rules.html: $D/common/Makefile.template
+ @$(PERL) makefile2html < $< > $@
validate-xrefs:
$(PERL) $D/doc/auto/scripts/validate-xrefs.pl \
# Next define how to link the executable
$(target) : $(libraries) Makefile
@echo =====waves=======$(deal_II_dimension)d==============$(MT)== Linking $(@F)
- @$(CXX) $(flags) -o $(target) $(libraries) $(user-libs)
+ @$(CXX) $(LDFLAGS) -o $(target) $(libraries) $(LIBS)
# if you call it without arguments.
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS)
# To make running the application somewhat independent of the actual
your project to use the same compiler flags and to access the pathes
to libraries. This page documents <a href="#flags">available
flags</a>, documents the <a href="#values">values which are used
- in your local installation</a>, and shows two
+ in your local installation</a>, and shows
<a href="#generic">generic Makefiles</a> which you may want to use
in your own projects.
</p>
+ <li><h4>Linker flags</h4>
+
+ <dl>
+ <dt> <code>LDFLAGS</code> </dt>
+ <dd> <p>
+ General linker flags
+ </p>
+ </dd>
+
+ <dt> <code>LIBS</code> </dt>
+ <dd> <p>
+ Additional libraries found by configure
+ </p>
+ </dd>
+ </dl>
+
<li><h4>Variables in multithreading mode</h4>
<p>
</p>
<p>
- At present, we have two Makefiles, one for
- <a href="makefile.small.html" target="body">small projects</a>
- consisting of only one C++ file, and one for
- <a href="makefile.large.html" target="body">large projects</a>.
- Both Makefiles need slight modifications before they will work in
- your project. The places for modifications are marked.
+ At present, we have three Makefiles, one for <a
+ href="makefile.small.html" target="body">small projects</a>
+ consisting of only one C++ file, and one for <a
+ href="makefile.large.html" target="body">large projects</a>.
+ Furthermore, there is a Makefile in a <a
+ href="makefile.rules.html" target="body">different style</a>. Have
+ a look at them and see what seem convenient to you. All Makefiles
+ need slight modifications before they will work in your
+ project. The places for modifications are marked.
<ul>
<li> <p>
You can find this Makefile
<a href="Makefile.large" target="_top">here</a>.
</p>
- </ul>
+ <li> <p>
+
+ The <a href="makefile.rules.html" target="body">third
+ Makefile</a> is <code>common/Makefile.template</code> in
+ the <acronum>deal.II</acronym> directory tree.
+
+ It was designed for several targets in one directory and
+ makes use of the compilation rules in
+ <code>common/Make.rules</code>. All object files and
+ executables will be in the same directory.
+ </ul>
<hr>
active cell: a triangulation cell that is not refined further
-cell: element of a subdivision, being of the same dimension as the
-domain of computation
-
boundary component: part of the domain in physical space. Denotes
either function for a curved boundary or the selection of a <<boundary
condition>>
boundary indicator: data of lower dimensional <<triangulation
object>>s, indicating the number of a <<boundary component>>
+cell: element of a subdivision, being of the same dimension as the
+domain of computation
+
+DG: see <<Discontinuous Galerkin>>
+
+DGFEM: <<Discontinuous Galerkin>> finite element method.
+
+Discontinuous Galerkin: A Galerkin discretization with all degrees of
+freedom in the interior of the grid cells. Continuity between grid
+cells is established by jump terms on the cell interfaces.
+
hex: hexahedron, mapping of the unit cube into the domain
locally finest level: all <<active cell>>s, i.e. the finest cell at each
#include <base/smartpointer.h>
#include <base/logstream.h>
+void abort()
+{}
+
class Test : public Subscriptor
{
const char* name;
}
}
-void abort()
-{}
# if you call it without arguments.
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS)
# To make running the application somewhat independent of the actual
# if you call it without arguments.
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS)
# To make running the application somewhat independent of the actual
# if you call it without arguments.
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS)
# To make running the application somewhat independent of the actual
# if you call it without arguments.
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS)
# To make running the application somewhat independent of the actual
# if you call it without arguments.
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS)
# To make running the application somewhat independent of the actual
# make rule for the target
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^ $(user-libs)
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS) $(user-libs)
# rule how to run the program
run: $(target)
#rather for libnumerics.a(tria.o)
Makefile.dep: $(cc-files) $(h-files) $(lib-h-files)
@echo ============================ Remaking Makefile
- @$(PERL) $D/common/scripts/Make_dep.pl ./Obj $(INCLUDE) $(cc-files) \
+ @$(PERL) $D/common/scripts/make_dependencies.pl ./Obj $(INCLUDE) $(cc-files) \
> Makefile.dep
# make rule for the target
$(target) : $(libraries)
@echo ============================ Linking $@
- @$(CXX) $(flags) -o $@ $^ $(user-libs)
+ @$(CXX) $(LDFLAGS) -o $@ $^ $(LIBS) $(user-libs)
# rule how to run the program
run: $(target)
#rather for libnumerics.a(tria.o)
Makefile.dep: $(cc-files) $(h-files) $(lib-h-files)
@echo ============================ Remaking Makefile
- @perl $D/common/scripts/Make_dep.pl ./Obj $(INCLUDE) $(cc-files) \
+ @perl $D/common/scripts/make_dependencies.pl ./Obj $(INCLUDE) $(cc-files) \
> Makefile.dep
template.testcase: $(template-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
constraints.testcase: $(constraints-o-files) $(libdeal3d) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
dof_test.testcase: $(dof_test-o-files) $(libdeal3d) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
fe_tables.testcase: $(fe_tables-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
gradients.testcase: $(gradients-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
grid_test.testcase: $(grid_test-o-files) $(libdeal3d) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
grid_generator.testcase: $(grid_generator-o-files) $(libdeal3d) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
second_derivatives.testcase: $(second_derivatives-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
wave-test-3.testcase: $(wave-test-3-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
mglocal.testcase: $(mglocal-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
mg.testcase: $(mg-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
block_matrices.testcase: $(block_matrices-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
endif
benchmark.testcase: $(benchmark-o-files) $(libraries)
- $(CXX) $(flags) -o $@ $^
+ $(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
# Continue with other targets if needed
endif
target1: $(target1-o-files) $(libraries)
- $(CXX) $(flags) -o $@ $^
+ $(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
Make.depend: $(all-cc-files)
@echo =====Dependencies== Make.depend
- @$(CXX) $(flags) $^ -M > $@
+ @$(CXX) $(CXXFLAGS.g) $^ -M > $@
@perl -pi -e 's/(^[^.]+)\.o:/\1.o \1.go:/;' $@
include Make.depend
endif
show_shapes: $(show_shapes-o-files) $(libraries)
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
endif
show_transform: $(show_transform-o-files) $(libraries)
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
# Continue with other targets if needed
solver.testcase: $(solver-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
full_matrix.testcase: $(full_matrix-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
mgbase.testcase: $(mgbase-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
mg.testcase: $(mg-o-files) $(libraries)
@echo =====linking======= $<
- @$(CXX) $(flags) -o $@ $^
+ @$(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
endif
benchmark.testcase: $(benchmark-o-files) $(libraries)
- $(CXX) $(flags) -o $@ $^
+ $(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
# Continue with other targets if needed
endif
target1: $(target1-o-files) $(libraries)
- $(CXX) $(flags) -o $@ $^
+ $(CXX) $(LDFLAGS) -g -o $@ $^ $(LIBS)
############################################################
SolverControl control(1,1.e-300,false,false);
PrimitiveVectorMemory<> mem;
SolverRichardson<> rich(control, mem);
- PreconditionRelaxation<>
- prec((*matrices)[level], &SparseMatrix<double> ::template precondition_SSOR<double>, 1.);
+ PreconditionSSOR<> prec;
+ prec.initialize((*matrices)[level], 1.);
rich.solve((*matrices)[level], u, rhs, prec);
}
SparseMatrix<double> A(structure);
testproblem.laplacian(A);
- PreconditionIdentity
- prec_no;
- PreconditionRelaxation<>
- prec_sor(A, &SparseMatrix<double>::template precondition_SOR<double>, 1.2);
- PreconditionRelaxation<>
- prec_ssor(A, &SparseMatrix<double>::template precondition_SSOR<double>, 1.2);
+ PreconditionIdentity prec_no;
+ PreconditionSOR<> prec_sor;
+ prec_sor.initialize(A, 1.2);
+ PreconditionSSOR<> prec_ssor;
+ prec_ssor.initialize(A, 1.2);
Vector<double> f(dim);
Vector<double> u(dim);