Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F132068632
D4157.id14630.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
4 KB
Referenced Files
None
Subscribers
None
D4157.id14630.diff
View Options
Index: CHANGES
===================================================================
--- CHANGES
+++ CHANGES
@@ -10,6 +10,18 @@
All ports committers are allowed to commit to this file.
+20160331:
+AUTHOR: jbeich@FreeBSD.org
+
+ Introducing CONFIGURE_OUTSOURCE. It affects HAS_CONFIGURE and GNU_CONFIGURE
+ by invoking configure script and later build outside of source tree e.g.,
+
+ $ mkdir build
+ $ cd build
+ $ ../configure
+ $ gmake
+ $ gmake install
+
20160301:
AUTHOR: mat@FreeBSD.org
Index: Mk/bsd.port.mk
===================================================================
--- Mk/bsd.port.mk
+++ Mk/bsd.port.mk
@@ -778,6 +778,7 @@
# configure stage will not do anything if this is not set.
# GNU_CONFIGURE - If set, you are using GNU configure (optional). Implies
# HAS_CONFIGURE.
+# CONFIGURE_OUTSOURCE - If set, this port builds outside of WRKSRC.
# CONFIGURE_WRKSRC
# - Directory to run configure in.
# Default: ${WRKSRC}
@@ -1552,6 +1553,14 @@
WRKSRC:= ${WRKSRC}/${WRKSRC_SUBDIR}
.endif
+.if defined(CONFIGURE_OUTSOURCE)
+CONFIGURE_CMD?= ${WRKSRC}/${CONFIGURE_SCRIPT}
+CONFIGURE_WRKSRC?= ${WRKDIR}/.build
+BUILD_WRKSRC?= ${CONFIGURE_WRKSRC}
+INSTALL_WRKSRC?= ${CONFIGURE_WRKSRC}
+TEST_WRKSRC?= ${CONFIGURE_WRKSRC}
+.endif
+
PATCH_WRKSRC?= ${WRKSRC}
CONFIGURE_WRKSRC?= ${WRKSRC}
BUILD_WRKSRC?= ${WRKSRC}
@@ -3332,6 +3341,7 @@
done
.endif
.if defined(HAS_CONFIGURE)
+ @${MKDIR} ${CONFIGURE_WRKSRC}
@(cd ${CONFIGURE_WRKSRC} && \
${SET_LATE_CONFIGURE_ARGS} \
if ! ${SETENV} CC="${CC}" CPP="${CPP}" CXX="${CXX}" \
Index: audio/oss/Makefile
===================================================================
--- audio/oss/Makefile
+++ audio/oss/Makefile
@@ -15,11 +15,12 @@
BUILD_DEPENDS= gawk:${PORTSDIR}/lang/gawk
USES= tar:bzip2 kmod pkgconfig
+HAS_CONFIGURE= yes
+CONFIGURE_OUTSOURCE= yes
+CONFIGURE_ENV= HOSTCC="${CC}"
ALL_TARGET= all install
USE_GNOME= gtk20
USE_RC_SUBR= oss
-WRKSRC= ${WRKDIR}/build
-PATCH_WRKSRC= ${WRKDIR}/${DISTNAME}
SUB_FILES= pkg-install pkg-deinstall
ONLY_FOR_ARCHS= amd64 i386
@@ -31,15 +32,13 @@
oss_sbpci oss_sbxfi oss_trident oss_usb oss_userdev \
oss_ymf7xx osscore
-PROTO_DIR= ${WRKSRC}/prototype
+PROTO_DIR= ${INSTALL_WRKSRC}/prototype
PROTO_ETCDIR= ${PROTO_DIR}/etc
PROTO_BINDIR= ${PROTO_DIR}/usr/bin
PROTO_SBINDIR= ${PROTO_DIR}/usr/sbin
PROTO_MANDIR= ${PROTO_DIR}/usr/share/man
PROTO_OSSLIBDIR=${PROTO_DIR}${PREFIX}/lib/oss
-CONFIGURE_ENV= CC="${CC}" HOSTCC="${CC}"
-
OPTIONS_DEFINE= VORBIS
OPTIONS_DEFAULT=VORBIS
@@ -59,11 +58,6 @@
-name make.local -or -name soundoff -or -name soundon | \
${XARGS} ${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g'
-do-configure:
- ${MKDIR} ${WRKSRC}
- (cd ${WRKSRC} && \
- ${SETENV} ${CONFIGURE_ENV} ${PATCH_WRKSRC}/configure)
-
do-install:
${INSTALL_PROGRAM} ${PROTO_BINDIR}/* ${STAGEDIR}${PREFIX}/bin/
# @${ECHO_CMD} "OSSLIBDIR=${PREFIX}/lib/oss" > ${PROTO_ETCDIR}/oss.conf
Index: devel/fb-adb/Makefile
===================================================================
--- devel/fb-adb/Makefile
+++ devel/fb-adb/Makefile
@@ -18,10 +18,11 @@
USE_GITHUB= yes
GH_ACCOUNT= facebook
-USES= autoreconf:outsource gmake ncurses perl5 python:3,build
+USES= autoreconf gmake ncurses perl5 python:3,build
USE_PERL5= build # pod2man
BASH_CMD?= bash # can be zsh
GNU_CONFIGURE= yes
+CONFIGURE_OUTSOURCE= yes
CONFIGURE_ENV= PYTHON3="${PYTHON_CMD}"
INSTALL_TARGET= install-strip
PLIST_FILES= bin/${PORTNAME} \
@@ -90,25 +91,6 @@
@${REINPLACE_CMD} -i '.aux.bak' -e 's/linux-android/aux-&/' \
${WRKSRC}/stub-*/configure
-# XXX D4157: Similar to USES=qmake:outsource, merge into Mk/Uses/autoreconf.mk
-.if defined(USES) && ${USES:Mautoreconf\:outsource}
-USES:= autoreconf:build ${USES:Nautoreconf*}
-CONFIGURE_CMD= ${AUTORECONF_WRKSRC}/${CONFIGURE_SCRIPT}
-CONFIGURE_WRKSRC= ${WRKDIR}/.build
-BUILD_WRKSRC= ${CONFIGURE_WRKSRC}
-INSTALL_WRKSRC= ${CONFIGURE_WRKSRC}
-AUTORECONF_WRKSRC?= ${WRKSRC}
-
-_USES_configure+= 470:do-autoreconf
-do-autoreconf:
-.for f in AUTHORS ChangeLog INSTALL NEWS README
-# Don't modify time stamps if the files already exist
- @test -e ${AUTORECONF_WRKSRC}/${f} || ${TOUCH} ${AUTORECONF_WRKSRC}/${f}
-.endfor
- @(cd ${AUTORECONF_WRKSRC} && ${LOCALBASE}/bin/autoreconf -f -i)
- @${MKDIR} ${CONFIGURE_WRKSRC}
-.endif
-
.include <bsd.port.mk>
# XXX Bug 204615: Teach USE_LINUX about build-only deps
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Oct 14, 9:29 AM (8 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
23717338
Default Alt Text
D4157.id14630.diff (4 KB)
Attached To
Mode
D4157: Add CONFIGURE_OUTSOURCE support
Attached
Detach File
Event Timeline
Log In to Comment