Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 20 May 2001 16:30:03 -0700 (PDT)
From:      Cyrille Lefevre <clefevre@poboxes.com>
To:        freebsd-ports@FreeBSD.org
Subject:   Re: ports/27478: Updated port: net/isc-dhcp3 (3.0.r7)
Message-ID:  <200105202330.f4KNU3n93642@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/27478; it has been noted by GNATS.

From: Cyrille Lefevre <clefevre@poboxes.com>
To: freebsd-gnats-submit@FreeBSD.org
Cc:  
Subject: Re: ports/27478: Updated port: net/isc-dhcp3 (3.0.r7)
Date: Mon, 21 May 2001 01:23:42 +0200 (CEST)

 ok, forgive the previous patch. STRIP is broken too.
 so, I completly rewrote the Makefile and the PLIST file
 using some rules I've applyed to some other ports.
 
 Index: Makefile
 ===================================================================
 RCS file: /home/ncvs/ports/net/isc-dhcp3/Makefile,v
 retrieving revision 1.62
 diff -u -r1.62 Makefile
 --- Makefile	2001/05/14 00:17:11	1.62
 +++ Makefile	2001/05/20 23:09:17
 @@ -7,7 +7,7 @@
  #
  
  PORTNAME=	dhcp
 -PORTVERSION=	3.0.r4
 +PORTVERSION=	3.0.r7
  CATEGORIES=	net
  MASTER_SITES=	ftp://ftp.isc.org/isc/%SUBDIR%/ \
  		${US_MASTER_SITES} ${JAPAN_MASTER_SITES} \
 @@ -32,7 +32,11 @@
  
  HAS_CONFIGURE=	yes
  
 -PLIST_SUB=	PKGBASE="${PKGBASE}"
 +PLIST_SUB=	DATA_DIR="${DATA_DIR}" RCD_SUBDIR="${RCD_SUBDIR}" \
 +		CONF_SUBDIR="${CONF_SUBDIR}" SAMP_SUBDIR="${SAMP_SUBDIR}" \
 +		BIN_SUBDIR="${BIN_SUBDIR}" INC_SUBDIR="${INC_SUBDIR}" \
 +		LIB_SUBDIR="${LIB_SUBDIR}" DOC_SUBDIR="${DOC_SUBDIR}" \
 +		SAMP_SUFFIX="${SAMP_SUFFIX}"
  
  MAN3=		dhcpctl.3 omapi.3
  MAN5=		dhclient.conf.5 dhclient.leases.5 dhcp-contrib.5 \
 @@ -96,27 +100,32 @@
  
  PATCH_SUBDIRS=	common minires dst omapip server client relay dhcpctl
  
 +SAMP_SUFFIX=	.sample
 +
  BIN_FILES=	dhclient dhcpd dhcrelay
 +CONF_FILES=	dhclient.conf
  SAMP_FILES=	client/dhclient.conf server/dhcpd.conf
 -RCD_FILES=	isc-dhcpd.sh.sample
 +RCD_FILES=	isc-dhcpd.sh${SAMP_SUFFIX}
  DOC_FILES=	CHANGES COPYRIGHT README RELNOTES
  DATA_FILES=	dhclient.leases dhcpd.leases
 -CONF_FILES=	dhclient.conf
  
 -BIN_DIR=	${PREFIX}/sbin
 -ETC_DIR=	${PREFIX}/etc
 -RCD_DIR=	${PREFIX}/etc/rc.d
 -DOC_DIR=	${PREFIX}/share/doc/${PKGBASE}
 -VARDB_DIR=	/var/db
 -VARRUN_DIR=	/var/run
 +BIN_SUBDIR=	sbin
 +CONF_SUBDIR=	etc
 +SAMP_SUBDIR=	${CONF_SUBDIR}
 +RCD_SUBDIR=	etc/rc.d
 +INC_SUBDIR=	include
 +LIB_SUBDIR=	lib
 +DOC_SUBDIR=	share/doc/${PKGBASE}
 +DATA_DIR=	/var/db
  
 -STRIP?=		strip
 +STRIP_CMD?=	strip
  
  #
  # Post-patch
  #
  
 -post-patch: patch-scripts patch-makefile-conf patch-makefiles-dist
 +post-patch: patch-scripts patch-makefile-conf patch-makefiles-dist \
 +	    patch-man-pages
  
  patch-scripts:
  	@${PERL} -pi.fbsd -e 's.!!PREFIX!!.${PREFIX}.g' \
 @@ -132,6 +141,11 @@
  		${WRKSRC}/${subdir}/Makefile.dist
  .endfor
  
 +# temporary hack - no patch file needed for this typo.
 +# grrr! don't know how to delete lines in perl :(
 +patch-man-pages:
 +	@${PERL} -pi.fbsd -e 's/^\.Fd$$//' ${WRKSRC}/dhcpctl/dhcpctl.3
 +
  #
  # Post-install
  #
 @@ -142,40 +156,41 @@
  
  strip-binary-files:
  .for file in ${BIN_FILES}
 -.if exists({BIN_DIR}/${file})
 -	@${STRIP} ${BIN_DIR}/${file}
 +.if exists(${PREFIX}/${BIN_SUBDIR}/${file})
 +	@${STRIP_CMD} ${PREFIX}/${BIN_SUBDIR}/${file}
  .endif
  .endfor
  
  install-startup-files:
  .for file in ${RCD_FILES}
 -	@${INSTALL_SCRIPT} ${FILESDIR}/${file} ${RCD_DIR}/${file}
 +	@${INSTALL_SCRIPT} ${FILESDIR}/${file} ${PREFIX}/${RCD_SUBDIR}
  .endfor
  
  install-doc-files:
  .if !defined(NOPORTDOCS)
 -	@${MKDIR} ${DOC_DIR}
 +	@${MKDIR} ${PREFIX}/${DOC_SUBDIR}
  .for file in ${DOC_FILES}
 -	@${INSTALL_DATA} ${WRKSRC}/${file} ${DOC_DIR}/${file}
 +	@${INSTALL_DATA} ${WRKSRC}/${file} ${PREFIX}/${DOC_SUBDIR}
  .endfor
  .endif
  
  install-sample-files:
  .for file in ${SAMP_FILES}
 -	@${INSTALL_DATA} ${WRKSRC}/${file} ${ETC_DIR}/${file:T}.sample
 +	@${INSTALL_DATA} ${WRKSRC}/${file} \
 +		${PREFIX}/${SAMP_SUBDIR}/${file:T}${SAMP_SUFFIX}
  .endfor
  
  create-data-files:
  .for file in ${DATA_FILES}
 -.if !exists(${VARDB_DIR}/${file})
 -	@${TOUCH} ${VARDB_DIR}/${file}
 +.if !exists(${DATA_DIR}/${file})
 +	@${TOUCH} ${DATA_DIR}/${file}
  .endif
  .endfor
  
  create-conf-files:
  .for file in ${CONF_FILES}
 -.if !exists(${ETC_DIR}/${file})
 -	@${TOUCH} ${ETC_DIR}/${file}
 +.if !exists(${PREFIX}/${CONF_SUBDIR}/${file})
 +	@${TOUCH} ${PREFIX}/${CONF_SUBDIR}/${file}
  .endif
  .endfor
  
 Index: distinfo
 ===================================================================
 RCS file: /home/ncvs/ports/net/isc-dhcp3/distinfo,v
 retrieving revision 1.30
 diff -u -r1.30 distinfo
 --- distinfo	2001/05/14 00:17:11	1.30
 +++ distinfo	2001/05/20 22:00:07
 @@ -1 +1 @@
 -MD5 (dhcp-3.0rc4.tar.gz) = 3f270f45836027b107ffc79eecf0b76e
 +MD5 (dhcp-3.0rc7.tar.gz) = 835be51c217c629d46fbcb422b1c91a9
 Index: pkg-plist
 ===================================================================
 RCS file: /home/ncvs/ports/net/isc-dhcp3/pkg-plist,v
 retrieving revision 1.16
 diff -u -r1.16 pkg-plist
 --- pkg-plist	2001/04/25 12:13:34	1.16
 +++ pkg-plist	2001/05/20 23:17:22
 @@ -1,34 +1,35 @@
  @comment $FreeBSD: ports/net/isc-dhcp3/pkg-plist,v 1.16 2001/04/25 12:13:34 roam Exp $
 -etc/dhclient.conf.sample
 -etc/dhcpd.conf.sample
 -etc/rc.d/isc-dhcpd.sh.sample
 -include/dhcpctl.h
 -include/isc/boolean.h
 -include/isc/dst.h
 -include/isc/int.h
 -include/isc/lang.h
 -include/isc/list.h
 -include/isc/result.h
 -include/isc/types.h
 -include/omapip/alloc.h
 -include/omapip/buffer.h
 -include/omapip/omapip.h
 -lib/libdhcpctl.a
 -lib/libomapi.a
 -sbin/dhclient
 -sbin/dhclient-script
 -sbin/dhcpd
 -sbin/dhcrelay
 -%%PORTDOCS%%share/doc/%%PKGBASE%%/CHANGES
 -%%PORTDOCS%%share/doc/%%PKGBASE%%/COPYRIGHT
 -%%PORTDOCS%%share/doc/%%PKGBASE%%/README
 -%%PORTDOCS%%share/doc/%%PKGBASE%%/RELNOTES
 -@dirrm include/isc
 -@dirrm include/omapip
 -%%PORTDOCS%%@dirrm share/doc/%%PKGBASE%%
 -@exec [ -f /var/db/dhclient.leases ] || touch /var/db/dhclient.leases
 -@unexec [ -s /var/db/dhclient.leases ] || rm -f /var/db/dhclient.leases
 -@exec [ -f /var/db/dhcpd.leases ] || touch /var/db/dhcpd.leases
 -@unexec [ -s /var/db/dhcpd.leases ] || rm -f /var/db/dhcpd.leases
 -@exec [ -f %D/etc/dhclient.conf ] || touch %D/etc/dhclient.conf
 -@unexec [ -L %D/etc/dhclient.conf -o -s %D/etc/dhclient.conf ] || rm -f %D/etc/dhclient.conf
 +%%SAMP_SUBDIR%%/dhclient.conf%%SAMP_SUFFIX%%
 +%%SAMP_SUBDIR%%/dhcpd.conf%%SAMP_SUFFIX%%
 +%%RCD_SUBDIR%%/isc-dhcpd.sh%%SAMP_SUFFIX%%
 +%%INC_SUBDIR%%/dhcpctl.h
 +%%INC_SUBDIR%%/isc/boolean.h
 +%%INC_SUBDIR%%/isc/dst.h
 +%%INC_SUBDIR%%/isc/int.h
 +%%INC_SUBDIR%%/isc/lang.h
 +%%INC_SUBDIR%%/isc/list.h
 +%%INC_SUBDIR%%/isc/result.h
 +%%INC_SUBDIR%%/isc/types.h
 +%%INC_SUBDIR%%/omapip/alloc.h
 +%%INC_SUBDIR%%/omapip/buffer.h
 +%%INC_SUBDIR%%/omapip/omapip.h
 +%%LIB_SUBDIR%%/libdhcpctl.a
 +%%LIB_SUBDIR%%/libomapi.a
 +%%BIN_SUBDIR%%/dhclient
 +%%BIN_SUBDIR%%/dhclient-script
 +%%BIN_SUBDIR%%/dhcpd
 +%%BIN_SUBDIR%%/dhcrelay
 +%%PORTDOCS%%%%DOC_SUBDIR%%/CHANGES
 +%%PORTDOCS%%%%DOC_SUBDIR%%/COPYRIGHT
 +%%PORTDOCS%%%%DOC_SUBDIR%%/README
 +%%PORTDOCS%%%%DOC_SUBDIR%%/RELNOTES
 +@dirrm %%INC_SUBDIR%%/isc
 +@dirrm %%INC_SUBDIR%%/omapip
 +%%PORTDOCS%%@dirrm %%DOC_SUBDIR%%
 +@unexec rm -f %%RCD_SUBDIR%%/isc-dhcpd.sh
 +@exec [ -f %%DATA_DIR%%/dhclient.leases ] || touch %%DATA_DIR%%/dhclient.leases
 +@unexec [ -s %%DATA_DIR%%/dhclient.leases ] || rm -f %%DATA_DIR%%/dhclient.leases
 +@exec [ -f %%DATA_DIR%%/dhcpd.leases ] || touch %%DATA_DIR%%/dhcpd.leases
 +@unexec [ -s %%DATA_DIR%%/dhcpd.leases ] || rm -f %%DATA_DIR%%/dhcpd.leases
 +@exec [ -f %D/%%CONF_SUBDIR%%/dhclient.conf ] || touch %D/%%CONF_SUBDIR%%/dhclient.conf
 +@unexec [ -L %D/%%CONF_SUBDIR%%/dhclient.conf -o -s %D/%%CONF_SUBDIR%%/dhclient.conf ] || rm -f %D/%%CONF_SUBDIR%%/dhclient.conf
 
 Cyrille.
 --
 home: mailto:clefevre@poboxes.com   UNIX is user-friendly; it's just particular
 work: mailto:Cyrille.Lefevre@edf.fr   about who it chooses to be friends with. 

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




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