Page MenuHomeFreeBSD

D4157.id14610.diff
No OneTemporary

D4157.id14610.diff

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 or 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 CONFIGURE_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}
@@ -2596,7 +2605,7 @@
CONFIGURE_ARGS+= --host=${X_BUILD_FOR}
.endif
CONFIGURE_ENV+= CONFIG_SITE=${CONFIG_SITE} lt_cv_sys_max_cmd_len=${CONFIGURE_MAX_CMD_LEN}
-HAS_CONFIGURE= yes
+HAS_CONFIGURE= ${GNU_CONFIGURE}
SET_LATE_CONFIGURE_ARGS= \
_LATE_CONFIGURE_ARGS="" ; \
@@ -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: 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
Index: multimedia/ffmpeg/Makefile
===================================================================
--- multimedia/ffmpeg/Makefile
+++ multimedia/ffmpeg/Makefile
@@ -17,6 +17,7 @@
${LOCALBASE}/bin/as:${PORTSDIR}/devel/binutils
HAS_CONFIGURE= yes
+CONFIGURE_OUTSOURCE= yes
USES= compiler cpe gmake perl5 pkgconfig tar:bzip2 shebangfix
USE_LDCONFIG= yes
USE_PERL5= build
@@ -441,16 +442,16 @@
-e "s|(EXTRALIBS[[:space:]]*=)|\1-L${LOCALBASE}/lib |g; \
s|%%LOCALBASE%%|${LOCALBASE}|g; \
s|gsm/gsm.h|gsm.h|g" \
- ${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
+ ${WRKSRC}/${CONFIGURE_SCRIPT}
@${REINPLACE_CMD} -e 's|-ldl||' \
-e 's|opencv opencv/cxcore.h|opencv-core opencv2/core/core_c.h|g' \
-e 's|freetype/freetype.h|freetype.h|g' \
- ${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
+ ${WRKSRC}/${CONFIGURE_SCRIPT}
post-patch-SDL-on:
@${REINPLACE_CMD} -E \
-e 's|sdl-config|${SDL_CONFIG}|g' \
- ${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
+ ${WRKSRC}/${CONFIGURE_SCRIPT}
@${FIND} ${WRKSRC} -type f | \
${XARGS} -n 10 ${REINPLACE_CMD} -E \
-e 's|#include <SDL|#include <SDL/SDL|'
@@ -458,7 +459,7 @@
post-configure-THEORA-off:
@${REINPLACE_CMD} -E \
-e 's|^(CONFIG_LIBTHEORA).*$$|\1=no|' \
- ${WRKSRC}/config.mak
+ ${CONFIGURE_WRKSRC}/config.mak
post-install:
(cd ${WRKSRC} && ${COPYTREE_SHARE} \
Index: sysutils/fusefs-simple-mtpfs/Makefile
===================================================================
--- sysutils/fusefs-simple-mtpfs/Makefile
+++ sysutils/fusefs-simple-mtpfs/Makefile
@@ -18,6 +18,7 @@
USES= autoreconf compiler:c++11-lib fuse localbase pkgconfig
GNU_CONFIGURE= yes
+CONFIGURE_OUTSOURCE= yes
CONFIGURE_ARGS= --disable-silent-rules
MAKEFILE= makefile
INSTALL_TARGET= install-strip

File Metadata

Mime Type
text/plain
Expires
Sun, May 24, 10:53 PM (12 h, 9 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33489147
Default Alt Text
D4157.id14610.diff (4 KB)

Event Timeline