From owner-freebsd-ports Wed Oct 30 9:28:39 2002 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 E7C0237B404 for ; Wed, 30 Oct 2002 09:28:37 -0800 (PST) Received: from vectors.cx (manifold.vectors.cx [64.163.147.229]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3A73843E88 for ; Wed, 30 Oct 2002 09:28:37 -0800 (PST) (envelope-from monkey@vectors.cx) Received: from vectors.cx (e33f741fd72eb704ffc21d646d77d9ca@localhost [127.0.0.1]) by vectors.cx (8.12.6/8.12.4) with ESMTP id g9UHULit030398 for ; Wed, 30 Oct 2002 09:30:21 -0800 (PST) (envelope-from monkey@vectors.cx) Received: (from monkey@localhost) by vectors.cx (8.12.6/8.12.6/Submit) id g9UHULKj030397 for ports@freebsd.org; Wed, 30 Oct 2002 09:30:21 -0800 (PST) (envelope-from monkey) Date: Wed, 30 Oct 2002 09:30:21 -0800 From: Adam Weinberger To: ports@freebsd.org Subject: Some more PLIST substitutions Message-ID: <20021030173021.GU197@vectors.cx> Mail-Followup-To: Adam Weinberger , ports@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Editor: Vim 6.1 http://www.vim.org X-Mailer: Mutt 1.5 http://www.mutt.org X-PGP-Key: http://www.vectors.cx/pgp.key.txt X-URL: http://www.vectors.cx http://www.crackula.com User-Agent: Mutt/1.5.1i Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following may be useful, not to help in portability as much as encouraging things to go in 'standard' locations. Additionally, it makes pkg-plist creation easier... if you ${INSTALL_PROGRAM} to ${DOCSDIR}, it makes sense to have the plist contain %%DOCSDIR%%/README. This patch just adds PLIST substitutions for EXAMPLESDIR, DATADIR, and DOCSDIR. The DOCSDIR target also acts like %%PORTDOCS%% and can replace it. That is, if NOPORTDOCS is defined, it comes out as "@comment ". Thoughts? -Adam Index: ports/Mk/bsd.port.mk =================================================================== RCS file: /home/ncvs/ports/Mk/bsd.port.mk,v retrieving revision 1.426 diff -u -r1.426 bsd.port.mk --- ports/Mk/bsd.port.mk 2 Oct 2002 07:18:17 -0000 1.426 +++ ports/Mk/bsd.port.mk 30 Oct 2002 17:22:22 -0000 @@ -829,12 +829,16 @@ BUILD_WRKSRC?= ${WRKSRC} INSTALL_WRKSRC?=${WRKSRC} -PLIST_SUB+= OSREL=${OSREL} PREFIX=%D LOCALBASE=${LOCALBASE} X11BASE=${X11BASE} +PLIST_SUB+= OSREL=${OSREL} PREFIX=%D LOCALBASE=${LOCALBASE} X11BASE=${X11BASE} \ + EXAMPLESDIR=${EXAMPLESDIR:S/${PREFIX}\///} \ + DATADIR=${DATADIR:S/${PREFIX}\///} .if defined(NOPORTDOCS) PLIST_SUB+= PORTDOCS="@comment " +PLIST_SUB+= DOCSDIR="@comment " .else PLIST_SUB+= PORTDOCS="" +PLIST_SUB+= DOCSDIR=${DOCSDIR:S/${PREFIX}\///} .endif CONFIGURE_SHELL?= ${SH} -- Adam Weinberger adam@vectors.cx adamw@FreeBSD.ORG To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message