aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorknu <knu@FreeBSD.org>2002-02-11 02:12:38 +0800
committerknu <knu@FreeBSD.org>2002-02-11 02:12:38 +0800
commit6f5dca37c57b4acc2580af134ce67ce0c9cfaf98 (patch)
tree2bcc9ded2ab46c27beafd074c34bcab24d75c95e
parent5663af42052eb2af6b98d3dae5dde209d6cdafde (diff)
downloadfreebsd-ports-gnome-6f5dca37c57b4acc2580af134ce67ce0c9cfaf98.tar.gz
freebsd-ports-gnome-6f5dca37c57b4acc2580af134ce67ce0c9cfaf98.tar.zst
freebsd-ports-gnome-6f5dca37c57b4acc2580af134ce67ce0c9cfaf98.zip
Prevent extconf.rb from getting patched for pthread more than once
when a port is built twice.
-rw-r--r--Mk/bsd.ruby.mk6
1 files changed, 3 insertions, 3 deletions
diff --git a/Mk/bsd.ruby.mk b/Mk/bsd.ruby.mk
index 150fafbfdd23..f75f3f90a4ab 100644
--- a/Mk/bsd.ruby.mk
+++ b/Mk/bsd.ruby.mk
@@ -277,13 +277,13 @@ ruby-extconf-configure:
.else
@${ECHO_MSG} "===> Running ${RUBY_EXTCONF} to configure"
.if defined(RUBY_WITH_PTHREAD)
- cd ${WRKSRC}; \
- ${RUBY} ${RUBY_FLAGS} -i -pe '~ /\brequire\s+[\047"]mkmf[\047"]/ \
+ cd ${WRKSRC}; if [ ! -e ${WRKSRC}/${RUBY_EXTCONF}.pth.orig ]; then \
+ ${RUBY} ${RUBY_FLAGS} -i.pth.orig -pe '~ /\brequire\s+[\047"]mkmf[\047"]/ \
and $$_ += %Q|\
$$libs.sub!(/-lc\\b/, "")\n \
$$libs += " " + with_config("pthread-libs") + " "\n \
$$CFLAGS += " " + with_config("pthread-cflags") + " "\n \
- |' ${RUBY_EXTCONF}
+ |' ${RUBY_EXTCONF}; fi
.endif
@cd ${WRKSRC}; \
${SETENV} ${CONFIGURE_ENV} ${RUBY} ${RUBY_FLAGS} ${RUBY_EXTCONF} ${CONFIGURE_ARGS}