+Sat Apr 3 17:57:35 1999 Alexandre Oliva <oliva@dcc.unicamp.br>
+
+ * Makefile.in (install-headers-tar, install-headers-cpio): avoid
+ problems with CDPATH
+ Reported by Ralf Canis <canis@bigfoot.com>
+
Sat Apr 3 13:50:16 1999 Jeffrey A Law (law@cygnus.com)
* fixinc.x86-linux-gnu: Deleted.
# Install the include directory using tar.
install-headers-tar: stmp-headers $(STMP_FIXPROTO) install-include-dir
- (cd include; \
+# We use `pwd`/include instead of just include to problems with CDPATH
+# Unless a full pathname is provided, some shells would print the new CWD,
+# found in CDPATH, corrupting the output. We could just redirect the
+# output of `cd', but some shells lose on redirection within `()'s
+ (cd `pwd`/include ; \
tar -cf - .; exit 0) | (cd $(libsubdir)/include; tar $(TAROUTOPTS) - )
# /bin/sh on some systems returns the status of the first tar,
# and that can lose with GNU tar which always writes a full block.
# Install the include directory using cpio.
install-headers-cpio: stmp-headers $(STMP_FIXPROTO) install-include-dir
- (cd include; find . -print) | (cd include; cpio -pdum $(libsubdir)/include)
+# See discussion about the use of `pwd` above
+ cd `pwd`/include ; \
+ find . -print | cpio -pdum $(libsubdir)/include
# Put assert.h where it won't override GNU libc's assert.h.
# It goes in a dir that is searched after GNU libc's headers;