diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2021-07-03 01:02:46 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2021-07-03 12:52:46 +0900 |
commit | 6d8422659a4c8a51f37433b6e63cc98d8526abe9 (patch) | |
tree | 6d53acd195acd30e0c6deab48d90651e6ad89fda /ext/zlib/extconf.rb | |
parent | 287fb680e24aabc73102bc7a47366a48c77f3086 (diff) |
Fix linking bundled zlib
* Prefix "./" to the import library name to expanded when static
linking exts.
* Copy zlib shared library to the top build directory.
Diffstat (limited to 'ext/zlib/extconf.rb')
-rw-r--r-- | ext/zlib/extconf.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/zlib/extconf.rb b/ext/zlib/extconf.rb index 76cd34582e..13d0ee2052 100644 --- a/ext/zlib/extconf.rb +++ b/ext/zlib/extconf.rb @@ -46,7 +46,7 @@ else end m = File.read(m) zimplib = m[/^IMPLIB[ \t]*=[ \t]*(\S+)/, 1] - $LOCAL_LIBS << " " << zimplib + ($LOCAL_LIBS << " ./" << zimplib).strip! unless $nmake or /^TOP[ \t]/ =~ m m.gsub!(/win32\/zlib\.def/, '$(TOP)/\&') m.gsub!(/^(\t.*[ \t])(\S+\.rc)/, '\1-I$(<D) $<') @@ -62,7 +62,7 @@ else "$(TARGET_SO): $(ZIMPLIB)\n", "$(ZIMPLIB):\n", "#{zmk} $(ZOPTS) $@\n", - "install-so: $(topdir)/#{dll}", + "install-so static: $(topdir)/#{dll}", "$(topdir)/#{dll}: $(ZIMPLIB)\n", "\t$(Q) $(COPY) #{dll} $(@D)\n", "clean: clean-zsrc\n", |