From des@des.no  Fri Feb  6 08:31:58 2004
Return-Path: <des@des.no>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 0431216A4CE
	for <FreeBSD-gnats-submit@freebsd.org>; Fri,  6 Feb 2004 08:31:58 -0800 (PST)
Received: from smtp.des.no (flood.des.no [217.116.83.31])
	by mx1.FreeBSD.org (Postfix) with ESMTP id B7E2643D41
	for <FreeBSD-gnats-submit@freebsd.org>; Fri,  6 Feb 2004 08:31:54 -0800 (PST)
	(envelope-from des@des.no)
Received: by smtp.des.no (Pony Express, from userid 666)
	id 6AA3A530D; Fri,  6 Feb 2004 17:31:53 +0100 (CET)
Received: from dwp.des.no (des.no [80.203.228.37])
	by smtp.des.no (Pony Express) with ESMTP id 19CC85308
	for <FreeBSD-gnats-submit@freebsd.org>; Fri,  6 Feb 2004 17:31:46 +0100 (CET)
Received: by dwp.des.no (Postfix, from userid 2602)
	id F11EA33C68; Fri,  6 Feb 2004 17:31:45 +0100 (CET)
Message-Id: <20040206163145.F11EA33C68@dwp.des.no>
Date: Fri,  6 Feb 2004 17:31:45 +0100 (CET)
From: Dag-Erling Smrgrav <des@des.no>
Reply-To: Dag-Erling Smrgrav <des@des.no>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: [PATCH] correctly determine PERL_ARCH
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         62441
>Category:       ports
>Synopsis:       [PATCH] correctly determine PERL_ARCH
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    portmgr
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Feb 06 08:40:01 PST 2004
>Closed-Date:    Thu Apr 01 23:35:38 PST 2004
>Last-Modified:  Thu Apr 01 23:35:38 PST 2004
>Originator:     Dag-Erling Smrgrav
>Release:        FreeBSD 5.2-CURRENT i386
>Organization:
>Environment:
System: FreeBSD dwp.des.no 5.2-CURRENT FreeBSD 5.2-CURRENT #0: Thu Feb 5 15:09:07 CET 2004 des@dwp.des.no:/usr/obj/usr/src/sys/dwp_smp i386

ports-current

>Description:

The default PERL_ARCH is currently determined as a function of OSVERSION.
It should however be a function of PERL_LEVEL since the correct value
depends on what Perl version one has installed (older Perl versions use
${ARCH}-freebsd, newer versions use mach).

>How-To-Repeat:

n/a

>Fix:

Apply the attached patch.

--- bsd.port.mk.diff begins here ---
Index: bsd.port.mk
===================================================================
RCS file: /home/pcvs/ports/Mk/bsd.port.mk,v
retrieving revision 1.484
diff -u -r1.484 bsd.port.mk
--- bsd.port.mk	4 Feb 2004 04:27:04 -0000	1.484
+++ bsd.port.mk	4 Feb 2004 22:11:59 -0000
@@ -1155,17 +1155,14 @@
 .if ${OSVERSION} >= 502100
 PERL_VERSION?=	5.8.2
 PERL_VER?=	5.8.2
-PERL_ARCH?=	mach
 .else
 .if ${OSVERSION} >= 500032
 PERL_VERSION?=	5.6.1
 PERL_VER?=		5.6.1
-PERL_ARCH?=		mach
 .else
 .if ${OSVERSION} >= 500007
 PERL_VERSION?=	5.6.0
 PERL_VER?=		5.6.0
-PERL_ARCH?=		mach
 .else
 .if ${OSVERSION} >= 300000
 PERL_VERSION?=	5.00503
@@ -1173,7 +1170,6 @@
 PERL_VERSION?=	5.00502
 .endif
 PERL_VER?=		5.005
-PERL_ARCH?=		${ARCH}-freebsd
 .endif
 .endif
 .endif
@@ -1193,6 +1189,12 @@
 .else
 PERL_LEVEL=0
 .endif # !defined(PERL_LEVEL) && defined(PERL_VERSION)
+
+.if ${PERL_LEVEL} >= 500600
+PERL_ARCH?=		mach
+.else
+PERL_ARCH?=		${ARCH}-freebsd
+.endif
 
 .if ${PERL_LEVEL} >= 500800
 PERL_PORT?=	perl5.8
--- bsd.port.mk.diff ends here ---


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->portmgr  
Responsible-Changed-By: krion 
Responsible-Changed-When: Fri Feb 6 11:42:44 PST 2004 
Responsible-Changed-Why:  
portmgr territory 

http://www.freebsd.org/cgi/query-pr.cgi?pr=62441 
State-Changed-From-To: open->analyzed 
State-Changed-By: kris 
State-Changed-When: Sat Mar 20 18:23:26 PST 2004 
State-Changed-Why:  
Will be tested on the next bento 4-exp run 

http://www.freebsd.org/cgi/query-pr.cgi?pr=62441 
State-Changed-From-To: analyzed->closed 
State-Changed-By: kris 
State-Changed-When: Thu Apr 1 23:35:29 PST 2004 
State-Changed-Why:  
Committed, thanks! 

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