diff options
| author | eban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-10-04 05:18:05 +0000 |
|---|---|---|
| committer | eban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-10-04 05:18:05 +0000 |
| commit | f4edf549b7b3362a187c4550e2e7c183b0123f07 (patch) | |
| tree | 287195e29184ce252439de17d083d85aadb0eaa7 /ext/extmk.rb | |
| parent | b404c024a0a3b55266da2f3f41231add5a1c9260 (diff) | |
| download | ruby-f4edf549b7b3362a187c4550e2e7c183b0123f07.tar.gz ruby-f4edf549b7b3362a187c4550e2e7c183b0123f07.tar.xz ruby-f4edf549b7b3362a187c4550e2e7c183b0123f07.zip | |
* configure.in (RUBY_PROG_GNU_LD): check whether the linker is GNU ld.
* ext/extmk.rb (create_makefile): add -Wl,-no-undefined to $DLDFLAGS
on Linux if GNU ld is used and --enable-shared is specified.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@2931 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/extmk.rb')
| -rw-r--r-- | ext/extmk.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/extmk.rb b/ext/extmk.rb index 06d46f106..50b2890a2 100644 --- a/ext/extmk.rb +++ b/ext/extmk.rb @@ -44,6 +44,7 @@ require 'shellwords' $topdir = File.expand_path(".") $top_srcdir = srcdir +# avoid warning for $VERBOSE mode Object.class_eval do remove_method :create_makefile end def create_makefile(target) @@ -64,6 +65,9 @@ def create_makefile(target) end $DLDFLAGS = CONFIG["DLDFLAGS"].dup + if /linux/ =~ RUBY_PLATFORM and $configure_args['--enable-shared'] and CONFIG["GNU_LD"] == "yes" + $DLDFLAGS << " -Wl,-no-undefined" + end if $configure_args['--enable-shared'] or CONFIG["LIBRUBY"] != CONFIG["LIBRUBY_A"] $libs = CONFIG["LIBRUBYARG"] + " " + $libs |
