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]

sh portability question


This change eliminates leftover support for non-autoconfiscated subdirectories.
But before I test and submit it properly (I anticipate some changes), 
I want to check that the use of {} is portable.  Can someone who knows more 
about shellology verify?

--Nathanael

--- Makefile.tpl	2002-11-23 17:31:50.000000000 -0500
+++ Makefile.tpl.new	2002-11-23 17:42:29.000000000 -0500
@@ -864,17 +864,11 @@
 	      srcdiroption="--srcdir=$${topdir}/[+module+]"; \
 	      libsrcdir="$$s/[+module+]"; \
 	    fi; \
-	    if [ -f $${libsrcdir}/configure ] ; then \
-	      rm -f no-such-file skip-this-dir; \
+	    { rm -f no-such-file skip-this-dir; \
 	      CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
 		$(BUILD_CONFIGARGS) $${srcdiroption} \
 		--with-build-subdir="$(BUILD_SUBDIR)"; \
-	    else \
-	      rm -f no-such-file skip-this-dir; \
-	      CONFIG_SITE=no-such-file $(SHELL) $$s/configure \
-		$(BUILD_CONFIGARGS) $${srcdiroption} \
-		--with-build-subdir="$(BUILD_SUBDIR)"; \
-	    fi || exit 1; \
+	    } || exit 1; \
 	    if [ -f skip-this-dir ] ; then \
 	      sh skip-this-dir; \
 	      rm -f skip-this-dir; \
@@ -1029,17 +1023,11 @@
 	      srcdiroption="--srcdir=$${topdir}/[+module+]"; \
 	      libsrcdir="$$s/[+module+]"; \
 	    fi; \
-	    if [ -f $${libsrcdir}/configure ] ; then \
-	      rm -f no-such-file skip-this-dir; \
+	    { rm -f no-such-file skip-this-dir; \
 	      CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
 		$(TARGET_CONFIGARGS) $${srcdiroption} \
 		--with-target-subdir="$(TARGET_SUBDIR)"; \
-	    else \
-	      rm -f no-such-file skip-this-dir; \
-	      CONFIG_SITE=no-such-file $(SHELL) $$s/configure \
-		$(TARGET_CONFIGARGS) $${srcdiroption} \
-		--with-target-subdir="$(TARGET_SUBDIR)"; \
-	    fi || exit 1; \
+	    } || exit 1; \
 	    if [ -f skip-this-dir ] ; then \
 	      sh skip-this-dir; \
 	      rm -f skip-this-dir; \


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