Changeset View
Changeset View
Standalone View
Standalone View
Mk/Uses/xfce.mk
# $FreeBSD$ | |||||
# | |||||
# Provide support for Xfce related ports. | |||||
# | |||||
# Feature: xfce | |||||
# Usage: USES=xfce or USES=xfce:ARGS | |||||
# Valid ARGS: gtk3 | |||||
# | |||||
# Variables, which can be set by the port: | |||||
# | |||||
# MASTER_SITE_SUBDIR Path | |||||
# USE_XFCE List of components | |||||
# | |||||
# MAINTAINER: xfce@FreeBSD.org | |||||
.if !defined(_INCLUDE_USES_XFCE_Mk) | |||||
_INCLUDE_USES_XFCE_Mk= yes | |||||
_USE_XFCE_ALL= garcon libexo libgui libmenu libutil panel thunar xfconf | |||||
MASTER_SITE_SUBDIR?= xfce/4.10/src | |||||
xfce_ARGS?= # empty | |||||
CONFIGURE_ENV+= CPPFLAGS="-I${LOCALBASE}/include" \ | |||||
LDFLAGS="-L${LOCALBASE}/lib" \ | |||||
ac_cv_prog_AWK="${AWK}" | |||||
garcon_LIB_DEPENDS= libgarcon-1.so:${PORTSDIR}/sysutils/garcon | |||||
garcon_USE_XFCE_REQ= libmenu | |||||
libexo_LIB_DEPENDS= libexo-1.so:${PORTSDIR}/x11/libexo | |||||
libexo_USE_XFCE_REQ= libmenu | |||||
libgui_LIB_DEPENDS= libxfcegui4.so:${PORTSDIR}/x11-toolkits/libxfce4gui | |||||
libgui_USE_XFCE_REQ= libutil | |||||
libmenu_LIB_DEPENDS= libxfce4ui-1.so:${PORTSDIR}/x11/libxfce4menu | |||||
libmenu_USE_XFCE_REQ= xfconf | |||||
libutil_LIB_DEPENDS= libxfce4util.so:${PORTSDIR}/x11/libxfce4util | |||||
panel_LIB_DEPENDS= libxfce4panel-1.0.so:${PORTSDIR}/x11-wm/xfce4-panel | |||||
panel_RUN_DEPENDS= xfce4-panel:${PORTSDIR}/x11-wm/xfce4-panel | |||||
panel_USE_XFCE_REQ= garcon libexo xfconf | |||||
thunar_LIB_DEPENDS= libthunarx-2.so:${PORTSDIR}/x11-fm/thunar | |||||
thunar_RUN_DEPENDS= Thunar:${PORTSDIR}/x11-fm/thunar | |||||
thunar_USE_XFCE_REQ= xfconf libmenu | |||||
xfconf_LIB_DEPENDS= libxfconf-0.so:${PORTSDIR}/x11/xfce4-conf | |||||
xfconf_USE_XFCE_REQ= libutil | |||||
.if defined(USE_XFCE) | |||||
# First, expand all USE_XFCE_REQ recursively. | |||||
.for comp in ${_USE_XFCE_ALL} | |||||
. for subcomp in ${${comp}_USE_XFCE_REQ} | |||||
${comp}_USE_XFCE_REQ+=${${subcomp}_USE_XFCE_REQ} | |||||
. endfor | |||||
.endfor | |||||
# Then, use already expanded USE_XFCE_REQ to expand USE_XFCE. | |||||
.for comp in ${USE_XFCE} | |||||
. if ${_USE_XFCE_ALL:M${comp}} == "" | |||||
IGNORE= cannot install: Unknown component ${comp} | |||||
. endif | |||||
_USE_XFCE+= ${${comp}_USE_XFCE_REQ} ${comp} | |||||
.endfor | |||||
# Remove duplicate components | |||||
USE_XFCE= ${_USE_XFCE:O:u} | |||||
.for comp in ${USE_XFCE} | |||||
. if defined(${comp}_BUILD_DEPENDS) | |||||
BUILD_DEPENDS+= ${${comp}_BUILD_DEPENDS} | |||||
. endif | |||||
. if defined(${comp}_LIB_DEPENDS) | |||||
LIB_DEPENDS+= ${${comp}_LIB_DEPENDS} | |||||
. endif | |||||
. if defined(${comp}_RUN_DEPENDS) | |||||
RUN_DEPENDS+= ${${comp}_RUN_DEPENDS} | |||||
. endif | |||||
.endfor | |||||
.if ${USE_XFCE:M*gui} == libgui | |||||
post-install: | |||||
antoine: Using post-install target for this is not good, if the port already has one only the 1st one… | |||||
@${ECHO_CMD} "" | |||||
@${ECHO_CMD} "WARNING: ${.CURDIR:S/${PORTSDIR}\///} depends of x11-toolkits/libxfce4gui," | |||||
@${ECHO_CMD} "which is not anymore maintained by upstream." | |||||
@${ECHO_CMD} "" | |||||
. endif | |||||
baptUnsubmitted Not Done Inline ActionsYou can avoid using a target by defining WARNING= "" \ "WARNING: ${.CURDIR:S/${PORTSDIR}\///} depends of x11-toolkits/libxfce4gui," \ "which is not anymore maintained by upstream." "" bapt: You can avoid using a target by defining
WARNING= "" \
"WARNING: ${. | |||||
.if ${xfce_ARGS} == gtk3 | |||||
. if exists(${LOCALBASE}/lib/libxfce4ui-1.so) && !exists(${LOCALBASE}/lib/libxfce4ui-2.so) | |||||
BROKEN= GTK3 option needs to be set in x11/libxfce4menu | |||||
. endif | |||||
.endif | |||||
.endif # end of defined(USE_XFCE) | |||||
.endif |
Using post-install target for this is not good, if the port already has one only the 1st one will be used
Also I'm not sure a target for this is good, maybe should be a