Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Sep 2010 06:11:39 +0200 (CEST)
From:      Gerald Pfeifer <gerald@pfeifer.com>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/151047: Pass CPP to CONFIGURE_ENV and MAKE_ENV in Mk/bsd.port.mk
Message-ID:  <201009290411.o8T4Bd5d075176@sputnik1.dbai.tuwien.ac.at>
Resent-Message-ID: <201009290420.o8T4K2ND022027@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         151047
>Category:       ports
>Synopsis:       Pass CPP to CONFIGURE_ENV and MAKE_ENV in Mk/bsd.port.mk
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed Sep 29 04:20:01 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Gerald Pfeifer
>Release:        
>Organization:
>Environment:
>Description:
	Right now the Ports Collection machinery passes CC and CXX and
	their flags as part of CONFIGURE_ENV and MAKE_ENV, alas not CPP
	which very well may depend on the compiler chosen.  And indeed
	Mk/bsd.gcc.mk now sets CPP properly in the case of USE_GCC.
>How-To-Repeat:
>Fix:
	The patch below should address this by adding CPP in both
	places.  To make the two invocations symmetric, the order
	of variables in the former now matches the one of the latter.

Index: bsd.port.mk
===================================================================
RCS file: /home/pcvs/ports/Mk/bsd.port.mk,v
retrieving revision 1.648
diff -u -3 -p -r1.648 bsd.port.mk
--- bsd.port.mk	26 Sep 2010 07:59:13 -0000	1.648
+++ bsd.port.mk	29 Sep 2010 04:07:49 -0000
@@ -2274,7 +2274,8 @@ MAKEFILE?=		Makefile
 MAKE_ENV+=		PREFIX=${PREFIX} \
 			LOCALBASE=${LOCALBASE} X11BASE=${X11BASE} \
 			MOTIFLIB="${MOTIFLIB}" LIBDIR="${LIBDIR}" \
-			CC="${CC}" CFLAGS="${CFLAGS}" CXX="${CXX}" CXXFLAGS="${CXXFLAGS}" \
+			CC="${CC}" CPP="${CPP}" CXX="${CXX}" \
+			CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}" \
 			MANPREFIX="${MANPREFIX}"
 
 # Add -fno-strict-aliasing to CFLAGS with optimization level -O2 or higher.
@@ -3776,7 +3777,7 @@ do-configure:
 .if defined(HAS_CONFIGURE)
 	@(cd ${CONFIGURE_WRKSRC} && \
 	    ${SET_LATE_CONFIGURE_ARGS} \
-		if ! ${SETENV} CC="${CC}" CXX="${CXX}" \
+		if ! ${SETENV} CC="${CC}" CPP="${CPP}" CXX="${CXX}" \
 	    CFLAGS="${CFLAGS}" CXXFLAGS="${CXXFLAGS}" \
 	    INSTALL="/usr/bin/install -c ${_BINOWNGRP}" \
 	    INSTALL_DATA="${INSTALL_DATA}" \
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201009290411.o8T4Bd5d075176>