Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 5 Jun 2014 22:57:50 +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: r356721 - head/sysutils/fcron
Message-ID:  <201406052257.s55Mvoq2035742@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Thu Jun  5 22:57:49 2014
New Revision: 356721
URL: http://svnweb.freebsd.org/changeset/ports/356721
QAT: https://qat.redports.org/buildarchive/r356721/

Log:
  Support stage
  Modernisation:
  - Use @sample
  - Install pam files into prefix
  - Use USERS/GROUPS framework
  - Remove now useless pkg-install/pkg-deinstall scripts
  
  PR:		190162
  Submitted by:	Zsolt Udvari

Deleted:
  head/sysutils/fcron/pkg-deinstall
  head/sysutils/fcron/pkg-install
Modified:
  head/sysutils/fcron/Makefile
  head/sysutils/fcron/pkg-plist

Modified: head/sysutils/fcron/Makefile
==============================================================================
--- head/sysutils/fcron/Makefile	Thu Jun  5 22:41:56 2014	(r356720)
+++ head/sysutils/fcron/Makefile	Thu Jun  5 22:57:49 2014	(r356721)
@@ -3,7 +3,7 @@
 
 PORTNAME=	fcron
 PORTVERSION=	3.0.6
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	sysutils
 MASTER_SITES=	${MASTER_SITE_SUNSITE} \
 		http://fcron.free.fr/archives/ \
@@ -14,6 +14,8 @@ DISTNAME=	${PORTNAME}-${PORTVERSION}.src
 MAINTAINER=	rde@tavi.co.uk
 COMMENT=	A periodic command scheduler
 
+OPTIONS_DEFINE=	DOCS EXAMPLES
+
 GNU_CONFIGURE=	yes
 USES=		perl5 gmake
 USE_PERL5=	build
@@ -24,13 +26,12 @@ CONFIGURE_ARGS=	--with-etcdir=${PREFIX}/
 
 WRKSRC=		${WRKDIR}/fcron-${PORTVERSION}
 
+USERS=		fcron
+GROUPS=		fcron
+
 USE_RC_SUBR=	fcron
 SUB_FILES=	pkg-message
 
-MAN1=		fcrontab.1
-MAN5=		fcron.conf.5 fcrontab.5
-MAN8=		fcron.8
-
 PAMDIR?=	/etc/pam.d
 PLIST_SUB+=	PAMDIR=etc/pam.d
 
@@ -42,37 +43,25 @@ DOCSRC=		${WRKSRC}/doc/${MANLANG}
 DOCSRC=		${WRKSRC}/doc/en
 .endif
 
-LICENSE=	GPLv2
-
-NO_STAGE=	yes
-pre-su-install:
-	@PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
-
 do-install:
-	${INSTALL_PROGRAM} ${WRKSRC}/fcron ${PREFIX}/sbin
-	${INSTALL_PROGRAM} -g fcron -o fcron -m 6111 ${WRKSRC}/fcrontab ${PREFIX}/bin
-	${INSTALL_PROGRAM} -g fcron -o fcron -m 6111 ${WRKSRC}/fcrondyn ${PREFIX}/bin
-	${INSTALL_PROGRAM} -g fcron -m 4110 ${WRKSRC}/fcronsighup ${PREFIX}/bin
+	${INSTALL_PROGRAM} ${WRKSRC}/fcron ${STAGEDIR}${PREFIX}/sbin
+	${INSTALL_PROGRAM} ${WRKSRC}/fcrontab ${STAGEDIR}${PREFIX}/bin
+	${INSTALL_PROGRAM} ${WRKSRC}/fcrondyn ${STAGEDIR}${PREFIX}/bin
+	${INSTALL_PROGRAM} ${WRKSRC}/fcronsighup ${STAGEDIR}${PREFIX}/bin
 .for f in fcron.allow fcron.conf fcron.deny
-	${INSTALL_DATA} -g fcron -m 640 ${WRKSRC}/files/${f} ${PREFIX}/etc/${f}.dist
+	${INSTALL_DATA} -m 640 ${WRKSRC}/files/${f} ${STAGEDIR}${PREFIX}/etc/${f}.sample
 .endfor
-	${MKDIR} ${EXAMPLESDIR}
-	${INSTALL_DATA} ${FILESDIR}/fcrontab-* ${WRKSRC}/files/*.pam ${EXAMPLESDIR}
-	${MKDIR} ${PAMDIR}
-	[ -f ${PAMDIR}/fcron ] || ${INSTALL_DATA} ${WRKSRC}/files/fcron.pam ${PAMDIR}/fcron
-	[ -f ${PAMDIR}/fcrontab ] || ${INSTALL_DATA} ${WRKSRC}/files/fcrontab.pam ${PAMDIR}/fcrontab
+	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+	${INSTALL_DATA} ${FILESDIR}/fcrontab-* ${WRKSRC}/files/*.pam ${STAGEDIR}${EXAMPLESDIR}
+	${INSTALL_DATA} ${WRKSRC}/files/fcron.pam ${STAGEDIR}${PREFIX}${PAMDIR}/fcron
+	${INSTALL_DATA} ${WRKSRC}/files/fcrontab.pam ${STAGEDIR}${PREFIX}${PAMDIR}/fcrontab
+	install -d -m 770 ${STAGEDIR}/var/spool/fcron
 .for n in 1 5 8
-	${INSTALL_MAN} ${MAN${n}:S|^|${DOCSRC}/man/|} ${PREFIX}/man/man${n}
+	${INSTALL_MAN} ${DOCSRC}/man/*.${n} ${STAGEDIR}${PREFIX}/man/man${n}
+.endfor
+.for d in txt HTML
+	${MKDIR} ${STAGEDIR}${DOCSDIR}/${d}
+	${INSTALL_DATA} ${DOCSRC}/${d}/* ${STAGEDIR}${DOCSDIR}/${d}
 .endfor
-.if !defined(NOPORTDOCS)
-.  for d in txt HTML
-	${MKDIR} ${DOCSDIR}/${d}
-	${INSTALL_DATA} ${DOCSRC}/${d}/* ${DOCSDIR}/${d}
-.  endfor
-.endif
-
-post-install:
-	@PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
-	@${CAT} ${PKGMESSAGE}
 
 .include <bsd.port.mk>

Modified: head/sysutils/fcron/pkg-plist
==============================================================================
--- head/sysutils/fcron/pkg-plist	Thu Jun  5 22:41:56 2014	(r356720)
+++ head/sysutils/fcron/pkg-plist	Thu Jun  5 22:57:49 2014	(r356721)
@@ -1,16 +1,33 @@
-bin/fcronsighup
-bin/fcrontab
+%%PAMDIR%%/fcron
+%%PAMDIR%%/fcrontab
+@mode 6111
+@owner fcron
+@group fcron
 bin/fcrondyn
-etc/fcron.allow.dist
-etc/fcron.conf.dist
-etc/fcron.deny.dist
+bin/fcrontab
+@mode 4110
+bin/fcronsighup
+@mode
+@sample etc/fcron.allow.sample
+@sample etc/fcron.conf.sample
+@sample etc/fcron.deny.sample
+@owner root
+@group wheel
+man/man1/fcrondyn.1.gz
+man/man1/fcrontab.1.gz
+man/man5/fcron.conf.5.gz
+man/man5/fcrontab.5.gz
+man/man8/fcron.8.gz
 sbin/fcron
-%%EXAMPLESDIR%%/fcrontab-operator
-%%EXAMPLESDIR%%/fcrontab-root
-%%EXAMPLESDIR%%/fcron.pam
-%%EXAMPLESDIR%%/fcrontab.pam
-@dirrm %%EXAMPLESDIR%%
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/fcron.pam
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/fcrontab-operator
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/fcrontab-root
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/fcrontab.pam
+%%PORTEXAMPLES%%@dirrmtry %%EXAMPLESDIR%%
 @cwd /
-%%PAMDIR%%/fcron
-%%PAMDIR%%/fcrontab
-@dirrmtry %%PAMDIR%%
+@exec install -d -o fcron -g fcron -m 770 /var/spool/fcron
+@owner fcron
+@group fcron
+@dirrmtry /var/spool/fcron
+@owner root
+@group wheel



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