Procházet zdrojové kódy

configure.ac: add option to disable fortran

Nathalie Furmento před 10 roky
rodič
revize
345da09a5c
1 změnil soubory, kde provedl 13 přidání a 6 odebrání
  1. 13 6
      configure.ac

+ 13 - 6
configure.ac

@@ -2020,6 +2020,19 @@ AC_SUBST(GLOBAL_AM_CFLAGS)
 pkglibdir="\${libdir}/$PACKAGE"
 AC_SUBST([pkglibdir])
 
+###############################################################################
+#                                                                             #
+#                               Fortran                                       #
+#                                                                             #
+###############################################################################
+
+AC_ARG_ENABLE(fortran, [AS_HELP_STRING([--disable-fortran],
+			[disable build of fortran examples])],
+			enable_build_fortran=$enableval, enable_build_fortran=yes)
+if test "x$FC" != "x" -a "x$enable_build_fortran" = "xyes" ; then
+  AC_DEFINE(STARPU_HAVE_FC, [], [Define this if a Fortran compiler is available])
+fi
+AM_CONDITIONAL([STARPU_HAVE_FC], [test "x$FC" != "x" -a "x$enable_build_fortran" = "xyes"])
 
 ###############################################################################
 #                                                                             #
@@ -2471,12 +2484,6 @@ if test "$enable_cuda" = "yes" -a "$ICC" != ""; then
    CFLAGS="$OLD_CFLAGS"
 fi
 
-# Fortran compiler
-if test "x$FC" != "x"; then
-  AC_DEFINE(STARPU_HAVE_FC, [], [Define this if a Fortran compiler is available])
-fi
-AM_CONDITIONAL([STARPU_HAVE_FC], [test "x$FC" != "x"])
-
 # Disable ICC on windows
 if test "x$ICC" != "x" -a "$starpu_windows" = "yes" ; then
     ICC=""