Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Apr 2013 22:25:20 +0000 (UTC)
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r316283 - in head: . Mk/Uses
Message-ID:  <201304222225.r3MMPKcw030555@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Mon Apr 22 22:25:20 2013
New Revision: 316283
URL: http://svnweb.freebsd.org/changeset/ports/316283

Log:
  Introduce USES= pkgconfig to replace USE_PKGCONFIG
  
  It can take 3 arguments:
  build (default,implicit) to add pkgconf into BUILD_DEPENDS
  run to add pkgconf into RUN_DEPENDS
  both to add pkgconf into both RUN and BUILD DEPENDS
  
  This deprecates USE_PKGCONFIG, please convert your ports.
  USE_PKGCONFIG will be removed as soon as it is no more used in
  the ports tree

Added:
  head/Mk/Uses/pkgconfig.mk   (contents, props changed)
Modified:
  head/CHANGES

Modified: head/CHANGES
==============================================================================
--- head/CHANGES	Mon Apr 22 22:16:28 2013	(r316282)
+++ head/CHANGES	Mon Apr 22 22:25:20 2013	(r316283)
@@ -10,6 +10,18 @@ in the release notes and/or placed into 
 
 All ports committers are allowed to commit to this file.
 
+20130323:
+AUTHOR: bapt@FreeBSD.org
+
+  * New USES macro to handle support for pkgconf (pkg-config) dependency:
+
+    USES= pkgconfig[:build] will add pkgconf into BUILD_DEPENDS
+    USES= pkgconfig:run will add pkgconf into RUN_DEPENDS
+    USES= pkgconfig:both will add pkgconf into both RUN and BUILD DEPENDS
+
+    It deprecates USE_PKGCONFIG which will be removed as soon as it is not
+    used anymore
+
 20130320:
 AUTHOR: jgh@FreeBSD.org
 

Added: head/Mk/Uses/pkgconfig.mk
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/Mk/Uses/pkgconfig.mk	Mon Apr 22 22:25:20 2013	(r316283)
@@ -0,0 +1,34 @@
+# $FreeBSD$
+#
+# handle dependency on the pkgconf port
+#
+# MAINTAINER: portmgr@FreeBSD.org
+#
+# Feature:	pkgconfig
+# Usage:	USES=pkgconfig or USES=pkgconfig:ARGS
+# Valid ARGS:	build (default, implicit), run, both
+#
+#
+.if !defined(_INCLUDE_USES_PKGCONFIG_MK)
+_INCLUDE_USES_PKGCONFIG_MK=	yes
+
+_PKGCONFIG_DEPENDS=	pkgconf:${PORTSDIR}/devel/pkgconf
+
+.if !defined(pkgconfig_ARGS)
+pkgconfig_ARGS=	build
+.endif
+
+.if ${pkgconfig_ARGS} == "build"
+BUILD_DEPENDS+=	${_PKGCONFIG_DEPENDS}
+CONFIGURE_ENV+=	PKG_CONFIG=pkgconf
+.elif ${pkgconfig_ARGS} == "run"
+RUN_DEPENDS+=	${_PKGCONFIG_DEPENDS}
+.elif ${pkgconfig_ARGS} == "both"
+CONFIGURE_ENV+=	PKG_CONFIG=pkgconf
+BUILD_DEPENDS+=	${_PKGCONFIG_DEPENDS}
+RUN_DEPENDS+=	${_PKGCONFIG_DEPENDS}
+.else
+IGNORE=	USES=pkgconfig - invalid args: [${pkgconfig_ARGS}] specifed
+.endif
+
+.endif



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201304222225.r3MMPKcw030555>