diff options
author | tcberner <tcberner@FreeBSD.org> | 2016-08-15 23:36:19 +0800 |
---|---|---|
committer | tcberner <tcberner@FreeBSD.org> | 2016-08-15 23:36:19 +0800 |
commit | fcca967cd7da755e20bf46668dd45fe4cc6acfa3 (patch) | |
tree | 846e4a8aef1ef6a96234bbd3dee3b2437dae21be /Mk/Uses | |
parent | 477a7c64d48c979a63e2b8ae84f2000248dfb22f (diff) | |
download | freebsd-ports-gnome-fcca967cd7da755e20bf46668dd45fe4cc6acfa3.tar.gz freebsd-ports-gnome-fcca967cd7da755e20bf46668dd45fe4cc6acfa3.tar.zst freebsd-ports-gnome-fcca967cd7da755e20bf46668dd45fe4cc6acfa3.zip |
New port: devel/grantlee5 and Uses/grantlee.mk
The upcoming KDE Frameworks ports need grantlee5
* Add devel/grantlee5 and move installed headers into a subdirectory include/grantlee5
* Move header files from devel/grantlee into a subdirectory
include/grantlee4
to make sure ports do not pick up the wrong headers
* Add Uses/grantlee.mk to handle the PLIST_SUB and LIB_DEEPENDS needed
by ports using grantlee (before we set the PLIST_SUB manual in very
of the depending ports, which now should not be needed anymore).
* The ports depending on devel/grantlee have been modified from
LIB_DEPENDS=libgrantlee_gui.so:devel/grantlee
to
USES=grantlee:4
as this does not affect the package no version bumped was made.
Reviewed by: mat, rakuco
Approved by: rakuco (mentor)
Differential Revision: https://reviews.freebsd.org/D7434
Diffstat (limited to 'Mk/Uses')
-rw-r--r-- | Mk/Uses/grantlee.mk | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/Mk/Uses/grantlee.mk b/Mk/Uses/grantlee.mk new file mode 100644 index 000000000000..ca68cd4b44fc --- /dev/null +++ b/Mk/Uses/grantlee.mk @@ -0,0 +1,66 @@ +# $FreeBSD$ +# +# Handle dependency on grantlee +# +# Feature: grantlee +# Usage: USES=grantlee:ARGS +# Valid ARGS: <version>,selfbuild +# +# version The chooseable versions are 4 and 5. +# USES=grantlee:4 # Use grantlee 0.x (qt4-based) +# USES=grantlee:5 # Use grantlee 5.x (qt5-based) +# +# selfbuild Used in devel/grantlee and devel/grantlee5 to suck in versions +# but not LIB_DEPENDS. +# +# Using USES=grantlee:ARGS will export some usesful variables and plist subs +# Variables: +# GRANTLEE_VERSION - the version of the chosen grantlee +# Subs: +# GRANTLEE_VERSION_FULL - full version of the chosen grantlee +# GRANTLEE_VERSION_SHORT - short version of the chosen grantlee +# +# Further it will also append the proper LIB_DEPENDS line. +# +# MAINTAINER: kde@FreeBSD.org +# + +.if ! defined(_INCLUDE_USES_GRANTLEE_MK) +_INCLUDE_USES_GRANTLEE_MK= YES + +GRANTLEE_SUPPORTED= 4 5 + +GRANTLEE4_VER= 0.5.1 +GRANTLEE5_VER= 5.1.0 + +GRANTLEE4_LIB_DEPEND= libgrantlee_gui.so:devel/grantlee +GRANTLEE5_LIB_DEPEND= libGrantlee_Templates.so:devel/grantlee5 + +_grantlee_version= # +. for ver in ${GRANTLEE_SUPPORTED:O:u} +. if ${grantlee_ARGS:M${ver}} +. if empty(_grantlee_version) +_grantlee_version= ${ver} +. else +IGNORE= Incorrect USES=grantlee:${grantlee_ARGS} - multiple versions defined +. endif +. endif +. endfor + +. if empty(_grantlee_version) +IGNORE= Incorrect USES=grantlee:${grantlee_ARGS} - no version defined +. endif + +# Export the version of the chosen grantlee port +GRANTLEE_VERSION= ${GRANTLEE${_grantlee_version}_VER} + +# Append the correct LIB_DEPENDS +. if empty(grantlee_ARGS:Mselfbuild) +LIB_DEPENDS+= ${GRANTLEE${_grantlee_version}_LIB_DEPEND} +. endif + +# Export the plist substitutions +PLIST_SUB+= GRANTLEE_VERSION_FULL=${GRANTLEE_VERSION} \ + GRANTLEE_VERSION_SHORT=${GRANTLEE_VERSION:R} + +.endif |