[前][次][番号順一覧][スレッド一覧]

ruby-changes:32781

From: usa <ko1@a...>
Date: Thu, 6 Feb 2014 14:21:00 +0900 (JST)
Subject: [ruby-changes:32781] usa:r44860 (ruby_1_9_3): * configure.in (POSTLINK): sign built program using RUBY_CODESIGN

usa	2014-02-06 14:20:52 +0900 (Thu, 06 Feb 2014)

  New Revision: 44860

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=44860

  Log:
    * configure.in (POSTLINK): sign built program using RUBY_CODESIGN
      identity.
      [Backport #9491]
    
    * Makefile.in (PROGRAM): ditto.
    
    * Makefile.in (LIBRUBY_SO): ditto.
    
    * lib/mkmf.rb (LINK_SO): sign extensions too.  replace empty line with
      default command.
    
    * enc/depend (link_so): prefix $(Q) for each commands.
    
    * tool/mkconfig.rb: restore embedded newlines.

  Modified files:
    branches/ruby_1_9_3/ChangeLog
    branches/ruby_1_9_3/Makefile.in
    branches/ruby_1_9_3/configure.in
    branches/ruby_1_9_3/enc/depend
    branches/ruby_1_9_3/lib/mkmf.rb
    branches/ruby_1_9_3/tool/mkconfig.rb
    branches/ruby_1_9_3/version.h
Index: ruby_1_9_3/configure.in
===================================================================
--- ruby_1_9_3/configure.in	(revision 44859)
+++ ruby_1_9_3/configure.in	(revision 44860)
@@ -1022,6 +1022,12 @@ main() https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/configure.in#L1022
                 if test "$rb_cv_broken_crypt" = yes; then
                   AC_DEFINE(BROKEN_CRYPT, 1)
                 fi
+		AC_CHECK_PROGS(codesign, codesign)
+		if test -n "$codesign"; then
+		    POSTLINK="test -z '\$(RUBY_CODESIGN)' || $codesign -s '\$(RUBY_CODESIGN)' -f \$@"
+		    LINK_SO="$LINK_SO
+\$(POSTLINK)"
+		fi
 		],
 [hpux*], [	LIBS="-lm $LIBS"
 		ac_cv_c_inline=no],
Index: ruby_1_9_3/ChangeLog
===================================================================
--- ruby_1_9_3/ChangeLog	(revision 44859)
+++ ruby_1_9_3/ChangeLog	(revision 44860)
@@ -1,3 +1,20 @@ https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/ChangeLog#L1
+Thu Feb  6 09:06:00 2014  Kenta Murata  <mrkn@c...>
+
+	* configure.in (POSTLINK): sign built program using RUBY_CODESIGN
+	  identity.
+	  [Backport #9491]
+
+	* Makefile.in (PROGRAM): ditto.
+
+	* Makefile.in (LIBRUBY_SO): ditto.
+
+	* lib/mkmf.rb (LINK_SO): sign extensions too.  replace empty line with
+	  default command.
+
+	* enc/depend (link_so): prefix $(Q) for each commands.
+
+	* tool/mkconfig.rb: restore embedded newlines.
+
 Wed Feb  5 13:43:02 2014  Nobuyoshi Nakada  <nobu@r...>
 
 	* string.c (rb_str_modify_expand): enable capacity and disable
Index: ruby_1_9_3/enc/depend
===================================================================
--- ruby_1_9_3/enc/depend	(revision 44859)
+++ ruby_1_9_3/enc/depend	(revision 44860)
@@ -103,7 +103,7 @@ $(TRANSOBJS): ruby.h intern.h config.h d https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/enc/depend#L103
 %   end
 
 % end
-% link_so = LINK_SO.gsub(/\n/, "\n\t")
+% link_so = LINK_SO.gsub(/([^\\])\n/, "\\1\n$(Q) ").gsub(/\n/, "\n\t")
 % link_so.gsub!(/(-(?:implib|pdb):\S+)-\$\(arch\)\./, '\1.')
 % dependencies.each do |e|
 %   obj = "enc/#{e}.$(OBJEXT)"
Index: ruby_1_9_3/lib/mkmf.rb
===================================================================
--- ruby_1_9_3/lib/mkmf.rb	(revision 44859)
+++ ruby_1_9_3/lib/mkmf.rb	(revision 44860)
@@ -2308,13 +2308,14 @@ COMPILE_CXX = config_string('COMPILE_CXX https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/lib/mkmf.rb#L2308
 TRY_LINK = config_string('TRY_LINK') ||
   "$(CC) #{OUTFLAG}conftest $(INCFLAGS) $(CPPFLAGS) " \
   "$(CFLAGS) $(src) $(LIBPATH) $(LDFLAGS) $(ARCH_FLAG) $(LOCAL_LIBS) $(LIBS)"
-LINK_SO = config_string('LINK_SO') ||
+LINK_SO = (config_string('LINK_SO') || "").sub(/^$/) do
   if CONFIG["DLEXT"] == $OBJEXT
     "ld $(DLDFLAGS) -r -o $@ $(OBJS)\n"
   else
     "$(LDSHARED) #{OUTFLAG}$@ $(OBJS) " \
     "$(LIBPATH) $(DLDFLAGS) $(LOCAL_LIBS) $(LIBS)"
   end
+end
 LIBPATHFLAG = config_string('LIBPATHFLAG') || ' -L"%s"'
 RPATHFLAG = config_string('RPATHFLAG') || ''
 LIBARG = config_string('LIBARG') || '-l%s'
Index: ruby_1_9_3/Makefile.in
===================================================================
--- ruby_1_9_3/Makefile.in	(revision 44859)
+++ ruby_1_9_3/Makefile.in	(revision 44860)
@@ -71,6 +71,7 @@ ARCHMINIOBJS = @MINIOBJS@ https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/Makefile.in#L71
 BUILTIN_ENCOBJS = @BUILTIN_ENCOBJS@
 BUILTIN_TRANSSRCS = @BUILTIN_TRANSSRCS@
 BUILTIN_TRANSOBJS = @BUILTIN_TRANSOBJS@
+POSTLINK = @POSTLINK@
 
 RUBY_BASE_NAME=@RUBY_BASE_NAME@
 RUBY_PROGRAM_VERSION=@RUBY_PROGRAM_VERSION@
@@ -169,6 +170,7 @@ $(PROGRAM): https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/Makefile.in#L170
 		@$(RM) $@
 		$(ECHO) linking $@
 		$(Q) $(PURIFY) $(CC) $(LDFLAGS) $(XLDFLAGS) $(MAINOBJ) $(EXTOBJS) $(LIBRUBYARG) $(MAINLIBS) $(LIBS) $(OUTFLAG)$@
+		$(Q) $(POSTLINK)
 
 # We must `rm' the library each time this rule is invoked because "updating" a
 # MAB library on Apple/NeXT (see --enable-fat-binary in configure) is not
@@ -184,6 +186,7 @@ $(LIBRUBY_SO): https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/Makefile.in#L186
 		$(ECHO) linking shared-library $@
 		$(Q) $(LDSHARED) $(DLDFLAGS) $(OBJS) $(DLDOBJS) $(SOLIBS) $(OUTFLAG)$@
 		-$(Q) $(OBJCOPY) -w -L '$(SYMBOL_PREFIX)Init_*' -L '$(SYMBOL_PREFIX)*_threadptr_*' $@
+		$(Q) $(POSTLINK)
 		@-$(MINIRUBY) -e 'ARGV.each{|link| File.delete link if File.exist? link; \
 						  File.symlink "$(LIBRUBY_SO)", link}' \
 				$(LIBRUBY_ALIASES) || true
Index: ruby_1_9_3/version.h
===================================================================
--- ruby_1_9_3/version.h	(revision 44859)
+++ ruby_1_9_3/version.h	(revision 44860)
@@ -1,10 +1,10 @@ https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/version.h#L1
 #define RUBY_VERSION "1.9.3"
-#define RUBY_PATCHLEVEL 514
+#define RUBY_PATCHLEVEL 515
 
-#define RUBY_RELEASE_DATE "2014-02-05"
+#define RUBY_RELEASE_DATE "2014-02-06"
 #define RUBY_RELEASE_YEAR 2014
 #define RUBY_RELEASE_MONTH 2
-#define RUBY_RELEASE_DAY 5
+#define RUBY_RELEASE_DAY 6
 
 #include "ruby/version.h"
 
Index: ruby_1_9_3/tool/mkconfig.rb
===================================================================
--- ruby_1_9_3/tool/mkconfig.rb	(revision 44859)
+++ ruby_1_9_3/tool/mkconfig.rb	(revision 44860)
@@ -62,6 +62,7 @@ File.foreach "config.status" do |line| https://github.com/ruby/ruby/blob/trunk/ruby_1_9_3/tool/mkconfig.rb#L62
     next if !continued_line
     continued_line << $1
     next if $2
+    continued_line.each {|s| s.sub!(/\\n\z/, "\n")}
     val = continued_line.join
     name = continued_name
     continued_line = nil

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]