ruby-changes:20724
From: yugui <ko1@a...>
Date: Sun, 31 Jul 2011 20:27:43 +0900 (JST)
Subject: [ruby-changes:20724] yugui:r32772 (ruby_1_9_3): * common.mk (ECHO1): ":" in a make variable replacement cause a syntax
yugui 2011-07-31 20:27:30 +0900 (Sun, 31 Jul 2011) New Revision: 32772 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=32772 Log: * common.mk (ECHO1): ":" in a make variable replacement cause a syntax error with /usr/ccs/bin/make on Solaris. Uses $(NULLCMD) instead. * configure.in (NULLCMD): new check. * Makefile.in (NULLCMD): Reflects checking in configure. * win32/Makefile.sub (NULLCMD): new assignment. Modified files: branches/ruby_1_9_3/ChangeLog branches/ruby_1_9_3/Makefile.in branches/ruby_1_9_3/common.mk branches/ruby_1_9_3/configure.in branches/ruby_1_9_3/win32/Makefile.sub Index: ruby_1_9_3/configure.in =================================================================== --- ruby_1_9_3/configure.in (revision 32771) +++ ruby_1_9_3/configure.in (revision 32772) @@ -2609,6 +2609,28 @@ gnumake=no]) AC_MSG_RESULT($gnumake) ]) +AS_IF([test "$gnumake" = yes], [ NULLCMD=: ], [ + AC_MSG_CHECKING([for safe null command for ${Make-make}]) + mkdir conftest.dir + echo 'A=1' > conftest.dir/Makefile + echo 'B=$(A:1=@:)' >> conftest.dir/Makefile + echo 'all:; $B 1 2 3 4 5 6 7 8 9' >> conftest.dir/Makefile + if (cd conftest.dir; ${Make-make} >/dev/null 2>/dev/null); then + NULLCMD=: + else + echo 'A=1' > conftest.dir/Makefile + echo 'B=$(A:1=@true)' >> conftest.dir/Makefile + echo 'all:; $B 1 2 3 4 5 6 7 8 9' >> conftest.dir/Makefile + if (cd conftest.dir; ${Make-make} >/dev/null 2>/dev/null); then + NULLCMD=true + else + AC_MSG_ERROR(no candidate for safe null command) + fi + fi + rm -fr conftest.dir + AC_MSG_RESULT($NULLCMD) +]) +AC_SUBST(NULLCMD) if test "${universal_binary-no}" = yes ; then AC_CACHE_CHECK([for architecture macros], rb_cv_architecture_macros, [ Index: ruby_1_9_3/ChangeLog =================================================================== --- ruby_1_9_3/ChangeLog (revision 32771) +++ ruby_1_9_3/ChangeLog (revision 32772) @@ -1,3 +1,14 @@ +Sun Jul 31 20:21:36 2011 "Yuki Sonoda (Yugui)" <yugui@y...> + + * common.mk (ECHO1): ":" in a make variable replacement cause a syntax + error with /usr/ccs/bin/make on Solaris. Uses $(NULLCMD) instead. + + * configure.in (NULLCMD): new check. + + * Makefile.in (NULLCMD): Reflects checking in configure. + + * win32/Makefile.sub (NULLCMD): new assignment. + Sun Jul 31 11:31:07 2011 Kazuki Tsujimoto <kazuki@c...> * backport r32768 from trunk. Index: ruby_1_9_3/common.mk =================================================================== --- ruby_1_9_3/common.mk (revision 32771) +++ ruby_1_9_3/common.mk (revision 32772) @@ -8,7 +8,7 @@ V = 0 Q1 = $(V:1=) Q = $(Q1:0=@) -ECHO1 = $(V:1=@:) +ECHO1 = $(V:1=@$(NULLCMD)) ECHO = $(ECHO1:0=@echo) RUBYLIB = - @@ -146,6 +146,7 @@ .PHONY: showflags exts enc trans: showflags showflags: + $(ECHO) test $(MESSAGE_BEGIN) \ " CC = $(CC)" \ " LD = $(LD)" \ Index: ruby_1_9_3/win32/Makefile.sub =================================================================== --- ruby_1_9_3/win32/Makefile.sub (revision 32771) +++ ruby_1_9_3/win32/Makefile.sub (revision 32772) @@ -1,6 +1,7 @@ # -*- makefile -*- SHELL = $(COMSPEC) +NULLCMD = : RUNCMD = $(COMSPEC) /c MKFILES = Makefile NULL = nul Index: ruby_1_9_3/Makefile.in =================================================================== --- ruby_1_9_3/Makefile.in (revision 32771) +++ ruby_1_9_3/Makefile.in (revision 32772) @@ -1,5 +1,5 @@ SHELL = /bin/sh -NULLCMD = : +NULLCMD = @NULLCMD@ RUNCMD = $(SHELL) CHDIR = @CHDIR@ exec = exec -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/