aboutsummaryrefslogtreecommitdiffstats
path: root/lang/ruby16_static
diff options
context:
space:
mode:
authorknu <knu@FreeBSD.org>2003-08-01 06:16:01 +0800
committerknu <knu@FreeBSD.org>2003-08-01 06:16:01 +0800
commit43e166e39baf41a3a4c903e870005cbf67141f07 (patch)
tree7595067750e5d756503bfe0a8cc36df27d89258c /lang/ruby16_static
parentba9e1483e1d4f57d571bba3da81036350e899ffa (diff)
downloadfreebsd-ports-gnome-43e166e39baf41a3a4c903e870005cbf67141f07.tar.gz
freebsd-ports-gnome-43e166e39baf41a3a4c903e870005cbf67141f07.tar.zst
freebsd-ports-gnome-43e166e39baf41a3a4c903e870005cbf67141f07.zip
Load rbconfig.rb before referring to Config and unbreak.
Diffstat (limited to 'lang/ruby16_static')
-rw-r--r--lang/ruby16_static/Makefile3
-rw-r--r--lang/ruby16_static/files/patch-ext+bdb1+extconf.rb25
2 files changed, 2 insertions, 26 deletions
diff --git a/lang/ruby16_static/Makefile b/lang/ruby16_static/Makefile
index e9670bebc1f0..40ef1786be21 100644
--- a/lang/ruby16_static/Makefile
+++ b/lang/ruby16_static/Makefile
@@ -81,10 +81,11 @@ PLIST_SUB+= IF_DEFAULT=${IF_DEFAULT}
do-fetch:
@${DO_NADA}
-.if defined(STATIC)
post-patch:
+.if defined(STATIC)
${RUBY} -i -pe 'gsub /-rdynamic/, "-static"' ${WRKSRC}/configure.in
.endif
+ ${RUBY} -i -pe '$$. == 1 and puts %q/require "rbconfig.rb"/' ${WRKSRC}/ext/bdb1/extconf.rb
do-extract:
${MKDIR} ${WRKDIR}
diff --git a/lang/ruby16_static/files/patch-ext+bdb1+extconf.rb b/lang/ruby16_static/files/patch-ext+bdb1+extconf.rb
deleted file mode 100644
index b49410f5700c..000000000000
--- a/lang/ruby16_static/files/patch-ext+bdb1+extconf.rb
+++ /dev/null
@@ -1,25 +0,0 @@
---- ext/bdb1/extconf.rb.orig Fri Dec 27 22:32:58 2002
-+++ ext/bdb1/extconf.rb Sun Apr 27 05:35:25 2003
-@@ -1,9 +1,10 @@
- #!/usr/bin/ruby
- require 'mkmf'
-+require 'rbconfig'
-
--$stat_lib = if CONFIG.key?("LIBRUBYARG_STATIC")
-+$stat_lib = if Config::CONFIG.key?("LIBRUBYARG_STATIC")
- $LDFLAGS += " -L#{CONFIG['libdir']}"
-- CONFIG["LIBRUBYARG_STATIC"]
-+ Config::CONFIG["LIBRUBYARG_STATIC"]
- else
- "-lruby"
- end
-@@ -40,8 +41,7 @@
-
- unknown: $(DLLIB)
- \t@echo "main() {}" > /tmp/a.c
--\t$(CC) -static /tmp/a.c $(OBJS) $(CPPFLAGS) $(DLDFLAGS) #$stat_lib #{CONFIG["LIBS"
--]} $(LIBS) $(LOCAL_LIBS)
-+\t$(CC) -static /tmp/a.c $(OBJS) $(CPPFLAGS) $(DLDFLAGS) #$stat_lib #{Config::CONFIG["LIBS"]} $(LIBS) $(LOCAL_LIBS)
- \t@-rm /tmp/a.c a.out
-
- test: $(DLLIB)