From 354a86c70fe829be4290d87515fe384aebdc1482 Mon Sep 17 00:00:00 2001 From: Michael Meissner Date: Thu, 11 Jul 1996 23:28:28 +0000 Subject: [PATCH] Check whether $(TARGET_SUBDIR)/$${dir} exists before trying to output --print-multi-lib there --- Makefile.in | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/Makefile.in b/Makefile.in index 89b378129dc..17a3df056b8 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1013,18 +1013,21 @@ $(INSTALL_MODULES): install-dirs .PHONY: $(CONFIGURE_TARGET_MODULES) $(CONFIGURE_TARGET_MODULES): @dir=`echo $@ | sed -e 's/configure-target-//'`; \ - $(CC_FOR_TARGET) --print-multi-lib > $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \ - if [ -f $(TARGET_SUBDIR)/$${dir}/multilib.out ]; then \ - if cmp $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out > /dev/null; then \ - rm -f $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \ + if [ -d $(TARGET_SUBDIR)/$${dir} ]; then \ + $(CC_FOR_TARGET) --print-multi-lib > $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \ + if [ -f $(TARGET_SUBDIR)/$${dir}/multilib.out ]; then \ + if cmp $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out > /dev/null; then \ + rm -f $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \ + else \ + echo "Multilibs changed for $${dir}, reconfiguring"; \ + rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/Makefile; \ + mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \ + fi; \ else \ - echo "Multilibs changed for $${dir}, reconfiguring"; \ - rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/Makefile; \ mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \ fi; \ - else \ - mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \ - fi; \ + fi; exit 0 # break command into two pieces + @dir=`echo $@ | sed -e 's/configure-target-//'`; \ if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \ true; \ elif echo " $(TARGET_CONFIGDIRS) " | grep " $${dir} " >/dev/null 2>&1; then \ -- 2.30.2