From root@xeon.ouestil.com  Wed Nov 24 18:23:07 2004
Return-Path: <root@xeon.ouestil.com>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id AB64D16A4CE
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 24 Nov 2004 18:23:07 +0000 (GMT)
Received: from xeon.ouestil.com (home.ouestil.com [81.56.27.190])
	by mx1.FreeBSD.org (Postfix) with SMTP id 88BD943D41
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 24 Nov 2004 18:23:06 +0000 (GMT)
	(envelope-from root@xeon.ouestil.com)
Received: (qmail 70685 invoked by uid 0); 24 Nov 2004 18:23:04 -0000
Message-Id: <20041124182304.70684.qmail@xeon.ouestil.com>
Date: 24 Nov 2004 18:23:04 -0000
From: freebsd@simplerezo.com <freebsd@simplerezo.com>
Reply-To: freebsd@simplerezo.com <freebsd@simplerezo.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc: doc@FreeBSD.org
Subject: [books/porters-handbook] Adding a call sample for pkg-install in Makefile
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         74328
>Category:       docs
>Synopsis:       [books/porters-handbook] Adding a call sample for pkg-install in Makefile
>Confidential:   no
>Severity:       non-critical
>Priority:       high
>Responsible:    freebsd-doc
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Wed Nov 24 18:30:24 GMT 2004
>Closed-Date:    Fri Nov 26 09:46:22 GMT 2004
>Last-Modified:  Fri Nov 26 09:46:22 GMT 2004
>Originator:     freebsd@simplerezo.com
>Release:        FreeBSD 4.9-RELEASE-p12 i386
>Organization:
SimpleRezo [http://www.simplerezo.com]
>Environment:
System: FreeBSD ---.simplerezo.com 4.9-RELEASE-p12 FreeBSD 4.9-RELEASE-p12 #0: Sun Nov 7 15:23:05 CET 2004 root@:/usr/obj/usr/src/sys/KERNEL i386


	
>Description:
	Because a lot of maintainer does not make a correct call to the pkg-install script
	in their Makefile, i think we should include a sample.
	
	Adding @PKG_PREFIX=${PREFIX} ${SH} pkg-install ${PKGNAME} PRE-INSTALL is a mistake because
	with a WRKDIRPREFIX variable set, this would not work: pkg-install have to be replaced
	with the PKG-INSTALL variable substitution instead.
>How-To-Repeat:
	
>Fix:

	

--- book.sgml.diff begins here ---
--- book.sgml.orig	Wed Nov 24 19:08:15 2004
+++ book.sgml	Wed Nov 24 19:13:15 2004
@@ -5014,7 +5014,9 @@
 	  <para>This script is not run automatically if you install the port
 	    with <command>make install</command>.  If you are depending on it
 	    being run, you will have to explicitly call it from your port's
-	    <filename>Makefile</filename>.</para>
+	    <filename>Makefile</filename>, with a line like
+	    <literal>@PKG_PREFIX=&dollar;{PREFIX} &dollar;{SH} &dollar;{PKGINSTALL}
+	    &dollar;{PKGNAME} PRE-INSTALL</literal>.</para>
 	</note>
       </sect1>
 
--- book.sgml.diff ends here ---


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: roam 
State-Changed-When: Fri Nov 26 09:45:58 GMT 2004 
State-Changed-Why:  
The change was committed with a little modification: PKG_PREFIX instead 
of @PKG_PREFIX.  Thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=74328 
>Unformatted:
