summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-16 23:35:16 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-16 23:35:16 +0000
commitb743cc0d76f6f92e8ef77ba86a27a78160515343 (patch)
tree146ce877c1a03da3bccd8ba9ff0fdfcfa2ea683b
parentd6178649a1493aa7098311828aa1241d41f9de4a (diff)
* Makefile.in, configure.in, common.mk, */Makefile.sub (CHDIR): cd
using phisical directory. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@27373 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--Makefile.in3
-rw-r--r--bcc32/Makefile.sub1
-rw-r--r--common.mk2
-rw-r--r--configure.in17
-rw-r--r--win32/Makefile.sub1
6 files changed, 27 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 4d730b9a76..b37c0ed363 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sat Apr 17 08:35:14 2010 Nobuyoshi Nakada <[email protected]>
+
+ * Makefile.in, configure.in, common.mk, */Makefile.sub (CHDIR): cd
+ using phisical directory.
+
Sat Apr 17 07:02:37 2010 Nobuyoshi Nakada <[email protected]>
* test/ruby/test_thread.rb (TestThreadGroup#test_uninitialized):
diff --git a/Makefile.in b/Makefile.in
index 744030dc89..58c92de532 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,6 +1,7 @@
SHELL = /bin/sh
NULLCMD = :
RUNCMD = $(SHELL)
+CHDIR = @CHDIR@
#### Start of system configuration section. ####
@@ -151,7 +152,7 @@ config.status: $(srcdir)/configure
exec 3>&1; exit `exec 4>&1; { "$$@" 3>&- 4>&-; echo $$? 1>&4; } | fgrep -v '(cached)' 1>&3`
$(srcdir)/configure: $(srcdir)/configure.in
- unset PWD; cd $(srcdir) && exec $(AUTOCONF)
+ $(CHDIR) $(srcdir) && exec $(AUTOCONF)
lex.c: keywords
( gperf -C -p -j1 -i 1 -g -o -t -N rb_reserved_word -k1,3,$$ $? > [email protected] && mv [email protected] $@ ) || \
diff --git a/bcc32/Makefile.sub b/bcc32/Makefile.sub
index 46d9e6e932..153c2835f0 100644
--- a/bcc32/Makefile.sub
+++ b/bcc32/Makefile.sub
@@ -2,6 +2,7 @@
SHELL = $(COMSPEC)
MKFILES = Makefile
+CHDIR = cd
#### Start of system configuration section. ####
!ifndef OS
diff --git a/common.mk b/common.mk
index e7b9a9d73f..eca53d7105 100644
--- a/common.mk
+++ b/common.mk
@@ -496,7 +496,7 @@ $(REVISION_H): $(srcdir)/version.h $(srcdir)/ChangeLog revision.h.tmp $(REVISION
revision.h.tmp: $(REVISION_FORCE)
@set LC_MESSAGES=C
- -@{ cd "$(srcdir)" && $(SET_LC_MESSAGES) $(VCS) info | \
+ -@{ $(CHDIR) "$(srcdir)" && $(SET_LC_MESSAGES) $(VCS) info | \
sed -n \
-e '/^URL:/{' -e '/\/trunk$$/d' -e 's!.*/\([^/][^/]*\)$$!#define RUBY_BRANCH_NAME "\1"!p' -e '}' \
-e "s/.*Rev:/#define RUBY_REVISION/p"; } > "$@"
diff --git a/configure.in b/configure.in
index 54fa57c40e..49d1b51776 100644
--- a/configure.in
+++ b/configure.in
@@ -258,6 +258,23 @@ else
fi
AC_SUBST(MAKEDIRS)
+AC_MSG_CHECKING([for cd using phisical directory])
+rm -fr conf$$.dir
+mkdir conf$$.dir &&
+(cd conf$$.dir && mkdir src build && cd src &&
+$as_ln_s ../build . > /dev/null 2>&1 && cd build &&
+for chdir in 'cd -P' 'PWD= cd'; do
+ /bin/sh -c "$chdir ../src && echo '$chdir' > cdcmd" 2> /dev/null && break
+done)
+if test -e conf$$.dir/src/cdcmd; then
+ read CHDIR < conf$$.dir/src/cdcmd 2> /dev/null
+else
+ CHDIR=cd
+fi
+rm -fr conf$$.dir
+AC_MSG_RESULT([$CHDIR])
+AC_SUBST(CHDIR)
+
dnl check for large file stuff
mv confdefs.h confdefs1.h
: > confdefs.h
diff --git a/win32/Makefile.sub b/win32/Makefile.sub
index 9bfa1bd7f0..7f0b3f08b6 100644
--- a/win32/Makefile.sub
+++ b/win32/Makefile.sub
@@ -4,6 +4,7 @@ SHELL = $(COMSPEC)
RUNCMD = $(COMSPEC) /c
MKFILES = Makefile
NULL = nul
+CHDIR = cd
!ifndef MFLAGS
MFLAGS=-l