From owner-freebsd-ports@FreeBSD.ORG Tue May 27 06:47:09 2014 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C937DA09; Tue, 27 May 2014 06:47:09 +0000 (UTC) Received: from mail-wg0-x22b.google.com (mail-wg0-x22b.google.com [IPv6:2a00:1450:400c:c00::22b]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 35F8924DE; Tue, 27 May 2014 06:47:09 +0000 (UTC) Received: by mail-wg0-f43.google.com with SMTP id l18so8730549wgh.26 for ; Mon, 26 May 2014 23:47:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=8QeJqNe6ndTyMvq9FedNxC6sybC3N30KTZZ8hFWeZ/Y=; b=VCF2mguuAHJ70eov9qV/OXvL+aE2iaCQHEhfgLBLeoAgLs5M230KggW7jdzb4fz63u QZEzB8X80FUwHkEkdRzRfxU47P3lAoYaVDVq1IGbbU3rSGGnZGTpybjSLGmCq19a2f5W d+6SC4juqywpvNqbLc+e+xBCqU9LOOHfI2phP88XMPMrZ4+D0iKq9+a30aCf4BO6vnxR +rpuOgUYlB+zmxQBS2tvVqnHJZKuH2U7oRE/VaVKo+96GJHr1Srw+hdHuxfu9PipPOqS 71HTAlg2cnkgByxA6Nn3QsYvo0U/G3faU2i40Qh7SrDKTmbPiy8fEGX8vPIxcKKTUJvZ QV7w== X-Received: by 10.194.24.36 with SMTP id r4mr6576366wjf.39.1401173227435; Mon, 26 May 2014 23:47:07 -0700 (PDT) Received: from ivaldir.etoilebsd.net ([2001:41d0:8:db4c::1]) by mx.google.com with ESMTPSA id be3sm32633509wjc.5.2014.05.26.23.47.05 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 26 May 2014 23:47:06 -0700 (PDT) Sender: Baptiste Daroussin Date: Tue, 27 May 2014 08:47:04 +0200 From: Baptiste Daroussin To: Perry Hutchison Subject: Re: Is staging a port really this simple? Message-ID: <20140527064704.GF20327@ivaldir.etoilebsd.net> References: <524CE820.5060003@missouri.edu> <20131003061511.GF85314@ithaqua.etoilebsd.net> <538179d9.ERL3ZKEnk4pQKKib%perryh@pluto.rain.com> <538197E3.1070609@marino.st> <53840869.xP0jQy92GIgSbFZy%perryh@pluto.rain.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="K/NRh952CO+2tg14" Content-Disposition: inline In-Reply-To: <53840869.xP0jQy92GIgSbFZy%perryh@pluto.rain.com> User-Agent: Mutt/1.5.23 (2014-03-12) Cc: marino@freebsd.org, udvzsolt@gmail.com, freebsd-ports@freebsd.org X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 May 2014 06:47:09 -0000 --K/NRh952CO+2tg14 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, May 26, 2014 at 08:37:13PM -0700, Perry Hutchison wrote: > John Marino wrote: > > You didn't miss much -- except adding the man page to the > > pkg-plist and removing the MAN* definitions from the makefile. >=20 > ... >=20 > > On 5/25/2014 09:09, Zsolt Udvari wrote: > > > Your condition is unneeded. > > > You don't need check the existence of > > > ${STAGEDIR}${PREFIX}/etc/distcheckd.conf because you'll copy it, the > > > ${STAGEDIR} are empty!!!! > > > > no, the @sample keyword in pkg-plist does that (replacing other lines > > there). pkg doesn't do this by itself, it needs to be told. >=20 > So, like this? (diffs against the originals, not the previous iteration) > [and I don't follow how, or if, @sample should be used in diskcheckd > since it delivers the sample named as such, and also installs it as > the live config file if the live config file does not already exist] >=20 > --- misc/gtkfind/Makefile > +++ misc/gtkfind/Makefile-staged > @@ -18,15 +18,13 @@ > USE_GNOME=3D gtk12 > GNU_CONFIGURE=3D yes > =20 > -MAN1=3D gtkfind.1 > -PLIST_FILES=3D bin/gtkfind > +PLIST_FILES=3D bin/gtkfind man/man1/gtkfind.1 Manpages are automatically compressed so you are missing .gz here > =20 > -NO_STAGE=3D yes > post-patch: > ${REINPLACE_CMD} -e "s,-O2,${CFLAGS}," ${WRKSRC}/configure ${WRKSRC}/Ma= kefile.in > =20 > do-install: > - ${INSTALL_PROGRAM} ${WRKSRC}/gtkfind ${PREFIX}/bin > - ${INSTALL_MAN} ${WRKSRC}/gtkfind.1 ${MANPREFIX}/man/man1 > + ${INSTALL_PROGRAM} ${WRKSRC}/gtkfind ${STAGEDIR}${PREFIX}/bin > + ${INSTALL_MAN} ${WRKSRC}/gtkfind.1 ${STAGEDIR}${MANPREFIX}/man/man1 > =20 > .include > --- sysutils/diskcheckd/Makefile > +++ sysutils/diskcheckd/Makefile-staged > @@ -11,15 +11,13 @@ > MAINTAINER=3D perryh@pluto.rain.com > COMMENT=3D Daemon to check for disk read errors > =20 > -MAN8=3D diskcheckd.8 > MLINKS=3D diskcheckd.8 diskcheckd.conf.5 > =20 > USE_RC_SUBR=3D diskcheckd > CFLAGS+=3D -D_PATH_CONF=3D'\"${PREFIX}/etc/diskcheckd.conf\"' > MAKEFILE=3D /usr/share/mk/bsd.prog.mk > -MAKE_ARGS=3D PROG=3Ddiskcheckd MAN8=3D${MAN8} > +MAKE_ARGS=3D PROG=3Ddiskcheckd MAN8=3Ddiskcheckd.8 > =20 > -NO_STAGE=3D yes > do-extract: > @${MKDIR} ${WRKSRC} > .for f in diskcheckd.c diskcheckd.8 > @@ -30,13 +28,13 @@ > @${REINPLACE_CMD} -e 's|/usr/local/etc/diskcheckd.conf|${PREFIX}/etc/di= skcheckd.conf|g' ${WRKSRC}/diskcheckd.8 > =20 > do-install: > - ${INSTALL_PROGRAM} ${WRKSRC}/diskcheckd ${PREFIX}/sbin > - ${INSTALL_DATA} ${FILESDIR}/diskcheckd.conf ${PREFIX}/etc/diskcheckd.co= nf.sample > - ${INSTALL_MAN} ${WRKSRC}/diskcheckd.8 ${MAN8PREFIX}/man/man8 > + ${INSTALL_PROGRAM} ${WRKSRC}/diskcheckd ${STAGEDIR}${PREFIX}/sbin > + ${INSTALL_DATA} ${FILESDIR}/diskcheckd.conf \ > + ${STAGEDIR}${PREFIX}/etc/diskcheckd.conf.sample > + ${INSTALL_MAN} ${WRKSRC}/diskcheckd.8 ${STAGEDIR}${MAN8PREFIX}/man/man8 > =20 > post-install: > - @[ -f ${PREFIX}/etc/diskcheckd.conf ] \ > - || ${CP} -p ${PREFIX}/etc/diskcheckd.conf.sample \ > - ${PREFIX}/etc/diskcheckd.conf > + @${CP} -p ${STAGEDIR}${PREFIX}/etc/diskcheckd.conf.sample \ > + ${STAGEDIR}${PREFIX}/etc/diskcheckd.conf > =20 > .include > --- sysutils/diskcheckd/pkg-plist > +++ sysutils/diskcheckd/pkg-plist-staged > @@ -1,4 +1,6 @@ > sbin/diskcheckd > +man/man8/diskcheckd.8 > +man/man5/diskcheckd.conf.5 =2Egz here as well=20 > @unexec if cmp -s %D/etc/diskcheckd.conf.sample %D/etc/diskcheckd.conf; = then rm -f %D/etc/diskcheckd.conf; fi > etc/diskcheckd.conf.sample > @exec if [ ! -f %D/etc/diskcheckd.conf ]; then cp %D/%F %B/diskcheckd.co= nf; fi --K/NRh952CO+2tg14 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (FreeBSD) iEYEARECAAYFAlOENOgACgkQ8kTtMUmk6EwxwQCfQPCxOa1Ho8hLRP+2ES7MZSUM UPkAoK1S29Qelb/1w8KqBwyle+aJ4+TD =K4Ix -----END PGP SIGNATURE----- --K/NRh952CO+2tg14--