From 6f5dca37c57b4acc2580af134ce67ce0c9cfaf98 Mon Sep 17 00:00:00 2001 From: knu Date: Sun, 10 Feb 2002 18:12:38 +0000 Subject: Prevent extconf.rb from getting patched for pthread more than once when a port is built twice. --- Mk/bsd.ruby.mk | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Mk/bsd.ruby.mk') 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} -- cgit