summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2020-04-02 21:32:36 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2020-04-02 21:32:36 +0900
commit5885550c8cb80fb8784598d3af1d90823f4f6604 (patch)
tree5d7c054bec024d39f0c1176e30d7a9f0605658ce
parent69f698d85ada116db5747873e53c597991bedff8 (diff)
[ruby/etc] Hack to get rid of linking against static library
-rw-r--r--ext/etc/extconf.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/ext/etc/extconf.rb b/ext/etc/extconf.rb
index b6ae7700da..5a0ce3c5f7 100644
--- a/ext/etc/extconf.rb
+++ b/ext/etc/extconf.rb
@@ -50,7 +50,13 @@ end
decl = [
"void rb_deprecate_constant(VALUE, const char *);",
]
-have_func('rb_deprecate_constant(Qnil, "None")', [decl])
+begin
+ # Hack to get rid of linking against static library
+ extmk, $extmk = $extmk, false
+ have_func('rb_deprecate_constant(Qnil, "None")', [decl])
+ensure
+ $extmk = extmk
+end
$distcleanfiles << "constdefs.h"