summaryrefslogtreecommitdiff
path: root/ext/extmk.rb.in
diff options
context:
space:
mode:
authoreban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-04-03 01:16:14 +0000
committereban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-04-03 01:16:14 +0000
commite2de605439f6538c95b66381c74f591eec2040bd (patch)
treead97368f42da386c36755c3cbcdfdb386235532d /ext/extmk.rb.in
parent57ca9e547b2c1edf243146ade29b0dc480e6d900 (diff)
* ext/extmk.rb.in (create_makefile): create def file only if
it does not yet exist. * lib/mkmf.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1304 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/extmk.rb.in')
-rw-r--r--ext/extmk.rb.in6
1 files changed, 4 insertions, 2 deletions
diff --git a/ext/extmk.rb.in b/ext/extmk.rb.in
index a4d4c57..3b40772 100644
--- a/ext/extmk.rb.in
+++ b/ext/extmk.rb.in
@@ -381,8 +381,10 @@ def create_makefile(target)
defflag = ''
if RUBY_PLATFORM =~ /cygwin|mingw/ and not $static
- open(target + '.def', 'wb') do |f|
- f.print "EXPORTS\n", "Init_", target, "\n"
+ if not File.exist? target + '.def'
+ open(target + '.def', 'wb') do |f|
+ f.print "EXPORTS\n", "Init_", target, "\n"
+ end
end
defflag = "--def=" + target + ".def"
end