aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgcc/fixinc.sco11
-rwxr-xr-xgcc/fixinc.svr411
2 files changed, 18 insertions, 4 deletions
diff --git a/gcc/fixinc.sco b/gcc/fixinc.sco
index c28039d..ad84989 100755
--- a/gcc/fixinc.sco
+++ b/gcc/fixinc.sco
@@ -58,8 +58,15 @@ fi
ORIG_DIR=`pwd`
-# Make LIB absolute.
-cd $LIB; LIB=`pwd`
+# Make LIB absolute if it is relative.
+# Don't do this if not necessary, since may screw up automounters.
+case $LIB in
+/*)
+ ;;
+*)
+ cd $LIB; LIB=`${PWDCMD}`
+ ;;
+esac
echo 'Building fixincludes in ' ${LIB}
diff --git a/gcc/fixinc.svr4 b/gcc/fixinc.svr4
index d597bc6..b2572cb 100755
--- a/gcc/fixinc.svr4
+++ b/gcc/fixinc.svr4
@@ -53,8 +53,15 @@ fi
ORIG_DIR=`pwd`
-# Make LIB absolute.
-cd $LIB; LIB=`pwd`
+# Make LIB absolute if it is relative.
+# Don't do this if not necessary, since may screw up automounters.
+case $LIB in
+/*)
+ ;;
+*)
+ cd $LIB; LIB=`${PWDCMD}`
+ ;;
+esac
# This prevents /bin/ex from failing if the current terminal type is
# unrecognizable.