]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
find gfortran compiler if installed
authorkanschat <kanschat@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 6 Aug 2006 21:57:53 +0000 (21:57 +0000)
committerkanschat <kanschat@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 6 Aug 2006 21:57:53 +0000 (21:57 +0000)
git-svn-id: https://svn.dealii.org/trunk@13608 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/aclocal.m4
deal.II/configure
deal.II/configure.in

index 8167820dbf7ad6194c42eaffcdf1caa6c744905a..4cfbdbb1bc84e23327247297bedea1ca0073a740 100644 (file)
@@ -1371,9 +1371,19 @@ AC_DEFUN(DEAL_II_SET_F77_FLAGS, dnl
                F77FLAGSPIC="-fPIC"
                 ;;
         esac
-
-        F77LIBS="$F77LIBS -lg2c"
-  
+        
+       case "$F77$" in
+          *gfortran* )
+               F77LIBS="$F77LIBS -lgfortran"
+               ;;
+          *g77* )
+               F77LIBS="$F77LIBS -lg2c"
+               ;;
+           * )
+               AC_MSG_ERROR([Error in configure script, please report a bug]) 
+               ;;
+       esac
+       
        ;;
 
     AIXF77)
index e939418d0257365a1b4e8e261d0e8b273bc408ff..fb83880a422f60f015f0d8b24197f1e6cacc9f65 100755 (executable)
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.in Revision: 1.233 .
+# From configure.in Revision: 13353 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.59 for deal.II 5.3.pre.
 #
@@ -9924,7 +9924,7 @@ echo "${ECHO_T}" >&6
 echo "$as_me:$LINENO: result: ----------------- configuring F77 compilers -----------------" >&5
 echo "${ECHO_T}----------------- configuring F77 compilers -----------------" >&6
 
-for ac_prog in f77 g77
+for ac_prog in f77 gfortran g77
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
@@ -10121,7 +10121,19 @@ echo "${ECHO_T}F77 compiler is unkown. no flags set!" >&6
                 ;;
         esac
 
-        F77LIBS="$F77LIBS -lg2c"
+       case "$F77$" in
+          *gfortran* )
+               F77LIBS="$F77LIBS -lgfortran"
+               ;;
+          *g77* )
+               F77LIBS="$F77LIBS -lg2c"
+               ;;
+           * )
+               { { echo "$as_me:$LINENO: error: Error in configure script, please report a bug" >&5
+echo "$as_me: error: Error in configure script, please report a bug" >&2;}
+   { (exit 1); exit 1; }; }
+               ;;
+       esac
 
        ;;
 
index 5d2ee1bfcc195214018b7abc0da0fa7e42377006..56a42377cc1443045b16da72621451ebfea67f94 100644 (file)
@@ -237,7 +237,7 @@ dnl
 dnl It is possible that no Fortran 77 compiler was found. Don't care,
 dnl it may be that we don't need one (but we check below, when we must
 dnl have it).
-AC_PATH_PROGS(F77, [f77 g77])
+AC_PATH_PROGS(F77, [f77 gfortran g77])
 
 dnl Next determine which f77 compiler we have here and set compilation
 dnl flags accordingly. Only do that if we have an F77 compiler at all.

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.