diff options
author | timur <timur@FreeBSD.org> | 2014-03-13 10:10:51 +0800 |
---|---|---|
committer | timur <timur@FreeBSD.org> | 2014-03-13 10:10:51 +0800 |
commit | 9a5415f8774170856192f137fe5588fe42d78289 (patch) | |
tree | d9f2251efa65a16badd45570d18a8af5df5c849c /devel | |
parent | 615e50534142e31711aa0ad612ffac73a73c41cf (diff) | |
download | freebsd-ports-gnome-9a5415f8774170856192f137fe5588fe42d78289.tar.gz freebsd-ports-gnome-9a5415f8774170856192f137fe5588fe42d78289.tar.zst freebsd-ports-gnome-9a5415f8774170856192f137fe5588fe42d78289.zip |
Convert port to support STAGE
Diffstat (limited to 'devel')
-rw-r--r-- | devel/tevent/Makefile | 64 |
1 files changed, 40 insertions, 24 deletions
diff --git a/devel/tevent/Makefile b/devel/tevent/Makefile index dca320cd73de..5f7167e992c8 100644 --- a/devel/tevent/Makefile +++ b/devel/tevent/Makefile @@ -1,7 +1,7 @@ # $FreeBSD$ PORTNAME= tevent -PORTVERSION= 0.9.18 +PORTVERSION= 0.9.21 PORTREVISION= 0 PORTEPOCH= 0 CATEGORIES= devel @@ -15,14 +15,11 @@ LICENSE= LGPL3 CONFLICTS= +USES= compiler pkgconfig USE_PYTHON_BUILD= 2 USE_LDCONFIG= yes -HAS_CONFIGURE= yes WAF_TOOL= buildtools/bin/waf -CONFIGURE_SCRIPT= ${WAF_TOOL} configure CONFIGURE_LOG= bin/config.log -USES= pkgconfig - PKGCONFIGDIR?= ${PREFIX}/libdata/pkgconfig PLIST_SUB+= PKGCONFIGDIR=${PKGCONFIGDIR:S;${PREFIX}/;;} @@ -30,33 +27,42 @@ PLIST_SUB+= PKGCONFIGDIR=${PKGCONFIGDIR:S;${PREFIX}/;;} CONFIGURE_ARGS+= --prefix=${PREFIX} \ --mandir=${MANPREFIX}/man \ --infodir=${PREFIX}/${INFO_PATH}/${INFO_SUBDIR} +# Support staging +DESTDIRNAME= --destdir -OPTIONS_DEFINE= PYTHON -OPTIONS_DEFAULT= PYTHON - -NO_STAGE= yes .include <bsd.port.options.mk> +.include <bsd.port.pre.mk> + +.if ! ${PORT_OPTIONS:MMANPAGES} +CONFIGURE_ENV+= XSLTPROC="true" +.else +BUILD_DEPENDS+= ${LOCALBASE}/share/xsl/docbook/manpages/docbook.xsl:${PORTSDIR}/textproc/docbook-xsl \ + xsltproc:${PORTSDIR}/textproc/libxslt +.endif + PLIST_FILES= include/tevent.h \ lib/libtevent.so \ lib/libtevent.so.0 \ %%PKGCONFIGDIR%%/tevent.pc -CONFIGURE_ENV+= XSLTPROC="/usr/bin/true" -CONFIGURE_ENV+= NOCOLOR=yes -MAKE_ENV+= NOCOLOR=yes - -BUILD_DEPENDS+= talloc>=2.0.8:${PORTSDIR}/devel/talloc +BUILD_DEPENDS+= talloc>=2.1.0:${PORTSDIR}/devel/talloc RUN_DEPENDS:= ${BUILD_DEPENDS} CONFIGURE_ARGS+= --bundled-libraries=!talloc +# No fancy color error messages +.if ${COMPILER_TYPE} == "clang" +CFLAGS+= -fno-color-diagnostics +.endif +CONFIGURE_ENV+= NOCOLOR=yes +MAKE_ENV+= NOCOLOR=yes + .if !defined(DISABLE_MAKE_JOBS) && !defined(MAKE_JOBS_UNSAFE) CONFIGURE_ARGS+= --jobs=${MAKE_JOBS_NUMBER} -_MAKE_JOBS= --jobs=${MAKE_JOBS_NUMBER} +_MAKE_JOBS+= --jobs=${MAKE_JOBS_NUMBER} .endif -.if ${PORT_OPTIONS:MPYTHON} USE_PYTHON_RUN= yes PLIST_FILES+= %%PYTHON_SITELIBDIR%%/_tevent.so \ %%PYTHON_SITELIBDIR%%/tevent.py \ @@ -64,19 +70,14 @@ PLIST_FILES+= %%PYTHON_SITELIBDIR%%/_tevent.so \ %%PYTHON_SITELIBDIR%%/tevent.pyo PLIST_DIRSTRY+= %%PYTHON_SITELIBDIR%% \ %%PYTHON_LIBDIR%% -.else -CONFIGURE_ARGS+= --disable-python -.endif +CONFIGURE_TARGET= configure ALL_TARGET= build INSTALL_TARGET= install -.include <bsd.port.pre.mk> - IGNORE_NONTHREAD_PYTHON=needs port lang/python${PYTHON_SUFFIX} to be build with THREADS support post-patch: - @${REINPLACE_CMD} -e 's|python|python${PYTHON_VER}|' ${BUILD_WRKSRC}/${WAF_TOOL} @${REINPLACE_CMD} -e 's|%%PKGCONFIGDIR%%|${PKGCONFIGDIR}|g' \ ${BUILD_WRKSRC}/wscript @@ -89,6 +90,23 @@ pre-configure: ${FALSE}; \ fi +do-configure: + @(cd ${CONFIGURE_WRKSRC} && \ + ${SET_LATE_CONFIGURE_ARGS} \ + if ! ${SETENV} CC="${CC}" CPP="${CPP}" CXX="${CXX}" \ + CFLAGS="${CFLAGS}" CPPFLAGS="${CPPFLAGS}" CXXFLAGS="${CXXFLAGS}" \ + LDFLAGS="${LDFLAGS}" \ + INSTALL="/usr/bin/install -c ${_BINOWNGRP}" \ + INSTALL_DATA="${INSTALL_DATA}" \ + INSTALL_LIB="${INSTALL_LIB}" \ + INSTALL_PROGRAM="${INSTALL_PROGRAM}" \ + INSTALL_SCRIPT="${INSTALL_SCRIPT}" \ + ${CONFIGURE_ENV} ${PYTHON_CMD} ${CONFIGURE_WRKSRC}/${WAF_TOOL} ${CONFIGURE_ARGS} ${CONFIGURE_TARGET}; then \ + ${ECHO_MSG} "===> Script \"${CONFIGURE_SCRIPT}\" failed unexpectedly."; \ + (${ECHO_CMD} ${CONFIGURE_FAIL_MESSAGE}) | ${FMT} 75 79 ; \ + ${FALSE}; \ + fi) + do-build: @(cd ${BUILD_WRKSRC}; \ if ! ${SETENV} ${MAKE_ENV} ${PYTHON_CMD} ${BUILD_WRKSRC}/${WAF_TOOL} ${_MAKE_JOBS} ${MAKE_ARGS} ${ALL_TARGET}; then \ @@ -100,10 +118,8 @@ do-build: fi) post-build: -.if ${PORT_OPTIONS:MPYTHON} ${PYTHON_CMD} -m py_compile ${BUILD_WRKSRC}/tevent.py ${PYTHON_CMD} -O -m py_compile ${BUILD_WRKSRC}/tevent.py -.endif do-install: @(cd ${INSTALL_WRKSRC} && ${SETENV} ${MAKE_ENV} ${PYTHON_CMD} ${INSTALL_WRKSRC}/${WAF_TOOL} ${MAKE_ARGS} ${INSTALL_TARGET}) |