aboutsummaryrefslogtreecommitdiffstats
path: root/Mk/bsd.port.mk
diff options
context:
space:
mode:
authormiwi <miwi@FreeBSD.org>2011-11-09 16:53:12 +0800
committermiwi <miwi@FreeBSD.org>2011-11-09 16:53:12 +0800
commitf8b6051c5c92aef1c2ea51fa8057a345f10a021b (patch)
tree4c0e4b60d5d7133b548e152d647e53ccf2a04021 /Mk/bsd.port.mk
parent099aa489f028ea3f08fabf7f756ea846bc08a5c7 (diff)
downloadfreebsd-ports-f8b6051c5c92aef1c2ea51fa8057a345f10a021b.tar.gz
freebsd-ports-f8b6051c5c92aef1c2ea51fa8057a345f10a021b.tar.zst
freebsd-ports-f8b6051c5c92aef1c2ea51fa8057a345f10a021b.zip
- Make WITH_FBSD10_FIX globally
- Add a new flag WITHOUT_FBSD10_FIX for maintainer testing Some additional notes: We are planing to make 10 exp-run after the 9.0 Release within 2 weeks to poke maintainers and upstream as to ensure that for the 10.0 Release, everything is fixed and we can remove the current workaround. Submitted by: bf@, rea@ (based on) Thanks to: beat, kwm, dough Reviewed by: erwin Tested via PH: 2x exp-run Approved by: portmgr (myself)
Diffstat (limited to 'Mk/bsd.port.mk')
-rw-r--r--Mk/bsd.port.mk30
1 files changed, 17 insertions, 13 deletions
diff --git a/Mk/bsd.port.mk b/Mk/bsd.port.mk
index 40f7b63bc973..82a77e3a1643 100644
--- a/Mk/bsd.port.mk
+++ b/Mk/bsd.port.mk
@@ -901,9 +901,8 @@ FreeBSD_MAINTAINER= portmgr@FreeBSD.org
# target has not been overwritten). This message
# will be passed through /usr/bin/fmt before
# being shown to the user.
-# WITH_FBSD10_FIX - Replace freebsd1*) and similar conditions
-# with freebsd1.*) in configure and libtool
-# scripts to fix build on FreeBSD 10 and above.
+#
+# WITHOUT_FBSD10_FIX Disable FreeBSD 10.0 autotools workaround.
#
# For build and install:
#
@@ -3662,16 +3661,21 @@ do-patch:
.if !target(run-autotools-fixup)
run-autotools-fixup:
-# Work around an issue where FreeBSD 10.0 is detected as FreeBSD 1.x.
-.if defined(WITH_FBSD10_FIX) && ${OSVERSION} >= 1000000
- /bin/test -d ${WRKSRC} && find ${WRKSRC} -type f \( -name config.libpath -o \
- -name config.rpath -o -name configure -o -name libtool.m4 \) \
- -exec sed -i '' -e 's|freebsd1\*)|freebsd1.\*)|g' \
- -e 's|freebsd\[12\]\*)|freebsd[12].*)|g' \
- -e 's|freebsd\[123\]\*)|freebsd[123].*)|g' \
- -e 's|freebsd\[\[12\]\]\*)|freebsd[[12]].*)|g' \
- -e 's|freebsd\[\[123\]\]\*)|freebsd[[123]].*)|g' \
- {} + || /usr/bin/true
+# Work around an issue where FreeBSD 10.0 is detected as FreeBSD 1.x.
+.if ${OSVERSION} >= 1000000 && !defined(WITHOUT_FBSD10_FIX)
+ -@for f in `${FIND} ${WRKSRC} -type f \( -name config.libpath -o \
+ -name config.rpath -o -name configure -o -name libtool.m4 -o \
+ -name ltconfig -o -name libtool -o -name aclocal.m4 -o \
+ -name acinclude.m4 \)` ; do \
+ ${SED} -i.fbsd10bak \
+ -e 's|freebsd1\*)|freebsd1.\*)|g' \
+ -e 's|freebsd\[12\]\*)|freebsd[12].*)|g' \
+ -e 's|freebsd\[123\]\*)|freebsd[123].*)|g' \
+ -e 's|freebsd\[\[12\]\]\*)|freebsd[[12]].*)|g' \
+ -e 's|freebsd\[\[123\]\]\*)|freebsd[[123]].*)|g' \
+ $${f} ; \
+ ${TOUCH} ${TOUCH_FLAGS} -mr $${f}.fbsd10bak $${f} ; \
+ done
.endif
.endif