Remove target-libgfortran from default targets 67/138767/3
authorSlava Barinov <v.barinov@samsung.com>
Thu, 13 Jul 2017 12:59:38 +0000 (15:59 +0300)
committerDongkyun Son <dongkyun.s@samsung.com>
Thu, 3 Aug 2017 00:32:27 +0000 (00:32 +0000)
       * configure.ac: Make target-libgfortran a configure option.
       * configure: Regenerate.

This fixes on-host build broken by 58909fae.

Now OBS build works as usual since it provides --enable-libgfortran explicitly
and on-host test builds are not broken with error
`GNU Fortran compiler is not working'

Change-Id: I39ea37ddb0e52c1e2b43e3d304da1389ce615010
Signed-off-by: Slava Barinov <v.barinov@samsung.com>
configure
configure.ac

index b29a724..a75a44f 100755 (executable)
--- a/configure
+++ b/configure
@@ -748,6 +748,7 @@ alphaieee_frag
 ospace_frag'
 ac_user_opts='
 enable_option_checking
+enable_libgfortran
 with_build_libsubdir
 with_system_zlib
 enable_as_accelerator_for
@@ -1469,6 +1470,8 @@ Optional Features:
   --disable-option-checking  ignore unrecognized --enable/--with options
   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
+  --enable-libgfortran[=ARG]
+                          build target libgfortran [ARG={default,yes,no}]
   --enable-as-accelerator-for=ARG
                           build as offload target compiler. Specify offload
                           host triple by ARG
@@ -2741,6 +2744,15 @@ libgcj="target-libffi \
        target-zlib \
        target-libjava"
 
+# libgfortran represents the runtime libraries only used by fortran.
+# Check whether --enable-libgfortran was given.
+if test "${enable_libgfortran+set}" = set; then :
+  enableval=$enable_libgfortran; libgfortran="target-libgfortran"
+else
+  libgfortran=""
+fi
+
+
 # these libraries are built for the target environment, and are built after
 # the host libraries and the host tools (which may be a cross compiler)
 # Note that libiberty is not a target library.
@@ -2759,7 +2771,7 @@ target_libraries="target-libgcc \
                target-libmpx \
                target-libssp \
                target-libquadmath \
-               target-libgfortran \
+               ${libgfortran} \
                target-boehm-gc \
                ${libgcj} \
                target-libobjc \
index f23463a..d720c20 100644 (file)
@@ -147,6 +147,13 @@ libgcj="target-libffi \
        target-zlib \
        target-libjava"
 
+# libgfortran represents the runtime libraries only used by fortran.
+AC_ARG_ENABLE(libgfortran,
+[AS_HELP_STRING([[--enable-libgfortran[=ARG]]],
+               [build target libgfortran @<:@ARG={default,yes,no}@:>@])],
+libgfortran="target-libgfortran",
+libgfortran="")
+
 # these libraries are built for the target environment, and are built after
 # the host libraries and the host tools (which may be a cross compiler)
 # Note that libiberty is not a target library.
@@ -165,7 +172,7 @@ target_libraries="target-libgcc \
                target-libmpx \
                target-libssp \
                target-libquadmath \
-               target-libgfortran \
+               ${libgfortran} \
                target-boehm-gc \
                ${libgcj} \
                target-libobjc \