Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 30 Dec 2013 16:06:43 +0000 (UTC)
From:      Dirk Meyer <dinoex@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r338128 - head/net/freebsd-uucp
Message-ID:  <201312301606.rBUG6hFn099318@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dinoex
Date: Mon Dec 30 16:06:43 2013
New Revision: 338128
URL: http://svnweb.freebsd.org/changeset/ports/338128

Log:
  - create and remove spool dirs
  Reported by:	Christian Weisgerber
  
  - install mtree files
  - remove upgrade target

Modified:
  head/net/freebsd-uucp/Makefile
  head/net/freebsd-uucp/pkg-plist

Modified: head/net/freebsd-uucp/Makefile
==============================================================================
--- head/net/freebsd-uucp/Makefile	Mon Dec 30 16:01:04 2013	(r338127)
+++ head/net/freebsd-uucp/Makefile	Mon Dec 30 16:06:43 2013	(r338128)
@@ -19,16 +19,15 @@ PKGMESSAGE=	${WRKDIR}/pkg-message
 INFO=	uucp
 VARLOG=	uucp/common_sources/policy.h uucp/uucico/uucico.8 \
 	uucp/uucp/uucp.1 uucp/uux/uux.1 uucp/uuxqt/uuxqt.8
-POLICY=	uucp/common_sources/policy.h
 FIXME=	etc/periodic/daily/340.uucp etc/periodic/daily/410.status-uucp \
 	etc/periodic/weekly/300.uucp
-BPKGNAME=	base-uucp-1.06.1
 
 # fix errros for -std=iso9899:1999 in FreeBSD 5.1
 MAKE_ENV+=	CSTD=gnu99
 
 OPTIONS_DEFINE=PAM ENCRYPTED_PASSWORDS VAR_LOG
 OPTIONS_DEFAULT=
+OPTIONS_SUB=	yes
 NO_OPTIONS_SORT=yes
 ENCRYPTED_PASSWORDS_DESC=	use encrypted passwords in etc/uucp/sys
 VAR_LOG_DESC=			put logfiles into /var/log
@@ -55,6 +54,12 @@ post-extract:
 	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} \
 		${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} extract)
 	${REINPLACE_CMD} -e 's|doc ||' ${WRKSRC}/uucp/Makefile
+	${REINPLACE_CMD} -e 's|VERSION=.*|VERSION=${PORTVERSION}|' \
+		${WRKSRC}/uucp/common_sources/configure \
+		${WRKSRC}/uucp/Makefile.inc
+	${REINPLACE_CMD} -e 's|(owner)|(uucpowner)|' \
+		${WRKSRC}/uucp/uustat/Makefile
+	${REINPLACE_CMD} -e 's|0770|0750|' ${WRKSRC}/local.mtree
 
 do-configure:
 	${REINPLACE_CMD} -e "s=/usr/local/=${PREFIX}/=" \
@@ -77,7 +82,7 @@ do-configure:
 .if ${PORT_OPTIONS:MENCRYPTED_PASSWORDS}
 	${REINPLACE_CMD} \
 		-e "s=HAVE_ENCRYPTED_PASSWORDS.*=HAVE_ENCRYPTED_PASSWORDS 1=" \
-		${WRKSRC}/${POLICY}
+		${WRKSRC}/uucp/common_sources/policy.h
 .endif
 	@${CAT} pkg-message > ${WRKDIR}/pkg-message
 .if ${PORT_OPTIONS:MPAM}
@@ -92,27 +97,9 @@ pre-install:
 	${MKDIR} ${STAGEDIR}/var
 
 post-install:
-	-${MKDIR} ${STAGEDIR}${PREFIX}/info
+	${MKDIR} ${STAGEDIR}${PREFIX}/etc/mtree ${STAGEDIR}${PREFIX}/info
+	${INSTALL_DATA} ${WRKSRC}/uucp.mtree ${STAGEDIR}${PREFIX}/etc/mtree/uucp-var.mtree
+	${INSTALL_DATA} ${WRKSRC}/local.mtree ${STAGEDIR}${PREFIX}/etc/mtree/uucp-local.mtree
 	${INSTALL_DATA} ${WRKSRC}/uucp/doc/uucp.info ${STAGEDIR}${PREFIX}/info/
-	${CHOWN} uucp:uucp ${STAGEDIR}${PREFIX}/etc/uucp
-	${CHMOD} 750 ${STAGEDIR}${PREFIX}/etc/uucp
-	@${ECHO_CMD} "updating ${ROOTDIR}/etc/services"
-	@${CP} ${ROOTDIR}/etc/services ${ROOTDIR}/etc/services.bak
-	@(grep -v ^suucp ${ROOTDIR}/etc/services.bak; \
-	${ECHO_CMD} "suucp           4031/tcp   #UUCP over SSL"; \
-	${ECHO_CMD} "suucp           4031/udp   #UUCP over SSL" ) \
-		> ${ROOTDIR}/etc/services
-.if !defined(BATCH)
-	@if test "$$(pw usershow uucp)" != "uucp:*:66:66::0:0:UUCP pseudo-user:/var/spool/uucppublic:${PREFIX}/libexec/uucp/uucico"; then \
-	pw usermod uucp -s ${PREFIX}/libexec/uucp/uucico; fi
-	@pw usershow uucp
-.endif
-	@${ECHO_MSG} "Use the 'make upgrade' command to copy your old configuration"
-	@${ECHO_MSG} "files from /etc/uucp to the new location in ${PREFIX}/etc/uucp"
-	@${ECHO_MSG}
-
-upgrade:
-	@${ECHO_MSG} "Copying old configuration files from /etc/uucp to ${PREFIX}/etc/uucp"
-	@${CP} -rp /etc/uucp ${PREFIX}/etc/uucp
 
 .include <bsd.port.mk>

Modified: head/net/freebsd-uucp/pkg-plist
==============================================================================
--- head/net/freebsd-uucp/pkg-plist	Mon Dec 30 16:01:04 2013	(r338127)
+++ head/net/freebsd-uucp/pkg-plist	Mon Dec 30 16:06:43 2013	(r338128)
@@ -5,6 +5,8 @@ bin/uusched
 bin/uustat
 bin/uuto
 bin/uux
+etc/mtree/uucp-var.mtree
+etc/mtree/uucp-local.mtree
 etc/periodic/daily/340.uucp
 etc/periodic/daily/410.status-uucp
 etc/periodic/weekly/300.uucp
@@ -42,11 +44,22 @@ libexec/uucp/uuxqt
 @group wheel
 sbin/uuchk
 sbin/uuconv
+@dirrmtry etc/mtree
 @dirrm etc/periodic/daily
 @dirrm etc/periodic/weekly
 @dirrm etc/periodic
 @dirrm etc/uucp
 @dirrm libexec/uucp
 @exec pw usermod uucp -s %D/libexec/uucp/uucico
+@exec mtree -deU -f etc/mtree/uucp-var.mtree -p /var
+@exec mtree -deU -f etc/mtree/uucp-local.mtree -p %D
+@unexec rm -d /var/spool/uucppublic 2>/dev/null || true
+@unexec rm -d /var/spool/uucp/.Preserve 2>/dev/null || true
+@unexec rm -d /var/spool/uucp/.Sequence 2>/dev/null || true
+@unexec rm -d /var/spool/uucp/.Status 2>/dev/null || true
+@unexec rm -d /var/spool/uucp/.Temp 2>/dev/null || true
+@unexec rm -d /var/spool/uucp/.Xqtdir 2>/dev/null || true
+@unexec rm -d /var/spool/uucp 2>/dev/null || true
+%%VAR_LOG%%@unexec rm -d /var/log/uucp 2>/dev/null || true
 @exec echo "updating /etc/services"; cp /etc/services /etc/services.bak; (grep -v ^suucp /etc/services.bak ; echo "suucp               4031/tcp  #UUCP over SSL";  echo "suucp               4031/udp  #UUCP over SSL") > /etc/services
 @unexec echo "updating /etc/services"; cp /etc/services /etc/services.bak; (grep -v ^suucp /etc/services.bak ) > /etc/services



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