summaryrefslogtreecommitdiff
path: root/ext/extmk.rb
diff options
context:
space:
mode:
authorshirosaki <shirosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-10-17 12:20:57 +0000
committershirosaki <shirosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-10-17 12:20:57 +0000
commit14d59c122f3158356bc84b25829f752585480cb7 (patch)
tree2755b7404873d5af1f5a007b0edfe447cbc05413 /ext/extmk.rb
parentaef5f90281d470449fa785f8778b3223a02afd2e (diff)
extmk.rb: fix mingw make failure with make -jN
* common.mk (WPROGRAM): need same dependencies as PROGRAM. * cygwin/GNUmakefile.in (uncommon.mk): move include position below WPROGRAM definition to be defined in uncommon.mk. * ext/extmk.rb (all, static): fix make rubyw.exe failure with make -jN. If make of ruby.exe and rubyw.exe run in parallel, link dll and link exe run in parallel, which causes link failure on mingw. To fix this, we make ruby.exe and rubyw.exe in one make process. [ruby-core:48007] [Bug #7165] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37246 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/extmk.rb')
-rwxr-xr-xext/extmk.rb11
1 files changed, 7 insertions, 4 deletions
diff --git a/ext/extmk.rb b/ext/extmk.rb
index df86c0f..40c3f40 100755
--- a/ext/extmk.rb
+++ b/ext/extmk.rb
@@ -656,13 +656,11 @@ if $configure_only and $command_output
mf.puts "#{tgt}: $(extensions:/.=/#{tgt})"
end
mf.puts
- mf.puts "all: #{rubies.join(' ')}"
- mf.puts "static: #{rubies.join(' ')}"
mf.puts "clean:\n\t-$(Q)$(RM) ext/extinit.#{$OBJEXT}"
mf.puts "distclean:\n\t-$(Q)$(RM) ext/extinit.c"
mf.puts
mf.puts "#{rubies.join(' ')}: $(extensions:/.=/#{$force_static ? 'static' : 'all'})"
- rubies.each do |tgt|
+ (["all static"] + rubies).each_with_index do |tgt, i|
mf.print "#{tgt}:\n\t$(Q)$(MAKE) "
mf.print "$(MFLAGS) "
if enable_config("shared", $enable_shared)
@@ -671,7 +669,12 @@ if $configure_only and $command_output
else
mf.print %[EXTOBJS="$(EXTOBJS) $(ENCOBJS)" EXTLIBS="$(EXTLIBS)" ]
end
- mf.puts 'EXTLDFLAGS="$(EXTLDFLAGS)" $@'
+ mf.print 'EXTLDFLAGS="$(EXTLDFLAGS)" '
+ if i == 0
+ mf.puts rubies.join(' ')
+ else
+ mf.puts '$@'
+ end
end
mf.puts
exec = config_string("exec") {|str| str + " "}