From owner-freebsd-ports@FreeBSD.ORG Fri Feb 11 04:36:08 2005 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C9F4416A4CE for ; Fri, 11 Feb 2005 04:36:08 +0000 (GMT) Received: from relay.rdsnet.ro (gimli.rdsnet.ro [193.231.236.70]) by mx1.FreeBSD.org (Postfix) with SMTP id D38F243D46 for ; Fri, 11 Feb 2005 04:36:07 +0000 (GMT) (envelope-from itetcu@people.tecnik93.com) Received: (qmail 30850 invoked from network); 11 Feb 2005 04:31:29 -0000 Received: from unknown (HELO smtp.rdsnet.ro) (62.231.74.130) by smtp1-133.rdsnet.ro with SMTP; 11 Feb 2005 04:31:29 -0000 Received: (qmail 11910 invoked by uid 89); 11 Feb 2005 04:39:33 -0000 Received: from unknown (HELO buh.cameradicommercio.ro) (82.76.1.117) by 0 with SMTP; 11 Feb 2005 04:39:33 -0000 Received: from it.buh.cameradicommercio.ro (it.buh.cameradicommercio.ro [192.168.0.10]) by buh.cameradicommercio.ro (Postfix) with ESMTP id 68327619A; Fri, 11 Feb 2005 04:27:50 +0200 (EET) Received: from it.buh.cameradicommercio.ro (localhost.buh.tecnik93.com [127.0.0.1]) by it.buh.cameradicommercio.ro (Postfix) with ESMTP id D09D9117; Fri, 11 Feb 2005 06:37:11 +0200 (EET) Date: Fri, 11 Feb 2005 06:37:11 +0200 From: Ion-Mihai Tetcu To: Paul Schmehl Message-ID: <20050211063711.2bab8a80@it.buh.cameradicommercio.ro> In-Reply-To: <2147483647.1108068463@[192.168.2.100]> References: <2147483647.1108068463@[192.168.2.100]> X-Mailer: Sylpheed-Claws 1.0.0 (GTK+ 1.2.10; i386-portbld-freebsd5.3) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit cc: freebsd-ports@freebsd.org Subject: Re: Make problem X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Feb 2005 04:36:08 -0000 On Thu, 10 Feb 2005 20:47:43 -0600 Paul Schmehl wrote: > Here's the port Makefile: > > # New ports collection makefile for: sancp > # Date created: 10 Feb 2005 > # Whom: pauls Usually you put your name and email here, but it's your choice. > # > # $FreeBSD$ > # > > PORTNAME= sancp > PORTVERSION= 1.6.1 > CATEGORIES= security > MASTER_SITES= http://www.metre.net/ > MASTER_SITE_SUBDIR= files This works now, but it isn't guaranteed. Probably it's better to use MASTER_SITES= http://www.metre.net/files/ > MAINTAINER= pauls@utdallas.edu > COMMENT= A network connection profiler > > PKGINSTALL= ${WRKDIR}/pkg-install > LOG_DIR= ${LOGDIR}/sancp I don't see it used anywhere. If you what the user to set it perhaps it would be good to tell in pre-everything:: and use LOG_DIR?= /var/log/snacp > LIB_DEPENDS+= libpcap:/usr/lib/libpcap.a > > USE_REINPLACE= yes > USE_RC_SUBR= yes > RC_SCRIPTS_SUB= PREFIX=${PREFIX} RC_SUBR=${RC_SUBR} > > DOCS= AUTHORS COPYING LICENSE.QPL README docs/BUGS docs/ChangeLog \ > docs/FAQ docs/INSTALL docs/NEWS docs/USAGE Using PORTDOCS= ..... will simplify the pkg-plist. > .include > > post-patch: > @${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \ > ${FILESDIR}/sancp.sh > ${WRKDIR}/sancp.sh > > post-install: > ${INSTALL_SCRIPT} -m 751 ${WRKDIR}/sancp.sh ${PREFIX}/etc/rc.d/sancp.sh Does this work ? It translates to install -o root -g wheel -m 555 -m 751 > .for f in sancp.conf > ${INSTALL_DATA} ${WRKSRC}/etc/sancp/${f} ${PREFIX}/etc/${f}-sample > [ -f ${PREFIX}/etc/${f} ] || \ > ${INSTALL_DATA} ${WRKSRC}/etc/sancp/${f} ${PREFIX}/etc/${f} > .endfor Why .for if it's one file ? The problem with this is that you don't know if sancp.conf is installed or not and you'll receive a nice email from pointyhat. See mail/dspam for the way to do it in pkg-plist > .if !defined(NOPORTDOCS) > @${MKDIR} ${DOCSDIR} > cd ${WRKSRC} && ${INSTALL_DATA} ${DOCS} ${DOCSDIR} > .endif > @${CAT} ${PKGMESSAGE} > > .include -- IOnut Unregistered ;) FreeBSD "user"