This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] [libobjc] allow default/fallback in --with-target-bdw-gc-include configure option


This addresses PR libobjc/78697, allowing a common include dir for all multilib
variants.  Tested with a libgc installation in /opt/gcc/include, /opt/gcc/lib32,
/opt/gcc/lib64 and configured with

--prefix=/opt/gcc7 --enable-languages=c,c++,objc --disable-shared
--enable-objc-gc=yes --with-multilib-list=m32,m64 --enable-checking=release
--disable-bootstrap --with-target-bdw-gc-include=/opt/gcc/include
--with-target-bdw-gc-lib=/opt/gcc/lib64,32=/opt/gcc/lib32

Ok for the trunk?

Matthias

libobjc/

2016-12-24  Matthias Klose  <doko@ubuntu.com>

        PR libobjc/78697
        * configure.ac: Allow default for --with-target-bdw-gc-include.
        * configure: Regenerate.

libobjc/

2016-12-24  Matthias Klose  <doko@ubuntu.com>

        PR libobjc/78697
	* configure.ac: Allow default for --with-target-bdw-gc-include.
	* configure: Regenerate.

Index: libobjc/configure.ac
===================================================================
--- libobjc/configure.ac	(revision 243987)
+++ libobjc/configure.ac	(working copy)
@@ -256,16 +256,19 @@
       for i in `echo $with_target_bdw_gc_include | tr ',' ' '`; do
         case "$i" in
           *=*) sd=${i%%=*}; d=${i#*=} ;;
-          *) sd=.; d=$i ;;
+          *) sd=.; d=$i; fallback=$i ;;
         esac
         if test "$mldir" = "$sd"; then
           bdw_val=$d
         fi
       done
-      if test "x$bdw_val" = x; then
+      if test "x$bdw_val" = x && test "x$bdw_inc_dir" = x && test "x$fallback" != x; then
+        bdw_inc_dir="$fallback"
+      elif test "x$bdw_val" = x; then
         AC_MSG_ERROR([no multilib path ($mldir) found in --with-target-bdw-gc-include])
+      else
+        bdw_inc_dir="$bdw_val"
       fi
-      bdw_inc_dir="$bdw_val"
     fi
     bdw_val=
     if test "x$with_target_bdw_gc_lib" != x; then

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]