Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 26 Sep 2015 08:54:28 +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: r397943 - head/x11/slim
Message-ID:  <201509260854.t8Q8sS13054208@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Sat Sep 26 08:54:27 2015
New Revision: 397943
URL: https://svnweb.freebsd.org/changeset/ports/397943

Log:
  Convert to @sample
  Use options helpers

Modified:
  head/x11/slim/Makefile
  head/x11/slim/pkg-plist

Modified: head/x11/slim/Makefile
==============================================================================
--- head/x11/slim/Makefile	Sat Sep 26 08:43:53 2015	(r397942)
+++ head/x11/slim/Makefile	Sat Sep 26 08:54:27 2015	(r397943)
@@ -3,7 +3,7 @@
 
 PORTNAME=	slim
 PORTVERSION=	1.3.6
-PORTREVISION=	9
+PORTREVISION=	10
 CATEGORIES=	x11
 MASTER_SITES=	ftp://ftp.berlios.de/pub/slim/ \
 		SF/slim.berlios
@@ -32,33 +32,22 @@ CMAKE_ARGS=	-DUSE_CONSOLEKIT=yes \
 
 OPTIONS_DEFINE=		PAM UTF8 CONSOLEKIT
 OPTIONS_DEFAULT=	PAM CONSOLEKIT
+OPTIONS_SUB=	yes
 
 UTF8_DESC=	Support UTF-8 characters
 CONSOLEKIT_DESC=Enable support for consolekit
 
 PLIST_SUB+=	VERSION="${PORTVERSION}"
 
-.include <bsd.port.options.mk>
+PAM_CMAKE_ON=	-DUSE_PAM=yes
+PAM_CMAKE_OFF=	-DUSE_PAM=no
 
-.if ${PORT_OPTIONS:MPAM}
-CMAKE_ARGS+=	-DUSE_PAM=yes
-PLIST_SUB+=	PAM=""
-.else
-CMAKE_ARGS+=	-DUSE_PAM=no
-PLIST_SUB+=	PAM="@comment "
-.endif
-
-.if ${PORT_OPTIONS:MUTF8}
 # patch taken from slim-unicode in Arch User Repository
-EXTRA_PATCHES+=	${PATCHDIR}/extra-patch-utf8
-.endif
+UTF8_EXTRA_PATCHES+=	${PATCHDIR}/extra-patch-utf8
 
-.if ${PORT_OPTIONS:MCONSOLEKIT}
-CMAKE_ARGS+=	-DUSE_CONSOLEKIT=yes
-LIB_DEPENDS+=	libck-connector.so:${PORTSDIR}/sysutils/consolekit
-.else
-CMAKE_ARGS+=	-DUSE_CONSOLEKIT=no
-.endif
+CONSOLEKIT_CMAKE_ON=	-DUSE_CONSOLEKIT=yes
+CONSOLEKIT_LIB_DEPENDS=	libck-connector.so:${PORTSDIR}/sysutils/consolekit
+CONSOLEKIT_CMAKE_OFF=	-DUSE_CONSOLEKIT=no
 
 post-patch:
 	@${CP} ${WRKSRC}/slim.conf ${WRKSRC}/slim.conf.sample
@@ -67,9 +56,7 @@ post-patch:
 	@${REINPLACE_CMD} -e 's,%%PREFIX%%,${PREFIX},' \
 		${WRKSRC}/slim.1
 
-post-install:
-.	if ${PORT_OPTIONS:MPAM}
-	${INSTALL_DATA} ${FILESDIR}/pam.conf ${STAGEDIR}${PREFIX}/etc/pam.d/slim.default
-.	endif
+post-install-PAM-on:
+	${INSTALL_DATA} ${FILESDIR}/pam.conf ${STAGEDIR}${PREFIX}/etc/pam.d/slim.sample
 
 .include <bsd.port.mk>

Modified: head/x11/slim/pkg-plist
==============================================================================
--- head/x11/slim/pkg-plist	Sat Sep 26 08:43:53 2015	(r397942)
+++ head/x11/slim/pkg-plist	Sat Sep 26 08:54:27 2015	(r397943)
@@ -6,6 +6,4 @@ lib/libslim.so.%%VERSION%%
 %%DATADIR%%/themes/default/slim.theme
 man/man1/slim.1.gz
 @sample etc/slim.conf.sample
-%%PAM%%@unexec if cmp -s %D/etc/pam.d/slim.default %D/etc/pam.d/slim; then rm -f %D/etc/pam.d/slim; fi
-%%PAM%%etc/pam.d/slim.default
-%%PAM%%@exec if [ ! -f %D/etc/pam.d/slim ]; then cp -p %D/%F %B/slim; fi
+%%PAM%%@sample etc/pam.d/slim.sample



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