Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 27 Feb 2007 22:44:19 +0300 (MSK)
From:      Dmitry Marakasov <amdmi3@amdmi3.ru>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        alexbl@FreeBSD.org
Subject:   ports/109640: Mk/bsd.scons.mk: add important hind for porters
Message-ID:  <20070227194419.209F54122@hades.panopticon>
Resent-Message-ID: <200702271950.l1RJo5R8046868@freefall.freebsd.org>

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

>Number:         109640
>Category:       ports
>Synopsis:       Mk/bsd.scons.mk: add important hind for porters
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Feb 27 19:50:04 GMT 2007
>Closed-Date:
>Last-Modified:
>Originator:     Dmitry Marakasov
>Release:        FreeBSD 6.1-RELEASE-p12 i386
>Organization:
>Environment:
System: FreeBSD hades.panopticon 6.1-RELEASE-p12 FreeBSD 6.1-RELEASE-p12 #0: Tue Jan 16 23:12:21 MSK 2007 amdmi3@hades.panopticon:/usr/obj/usr/src/sys/HADES i386


>Description:
SCons does not automatically import settings affecting build (that is, CC/CXX/CFLAGS/CXXFLAGS and others) from it's parameters nor environment, and FreeBSD ports are required to respect those settings. There is a feature, though, that makes scons import all parameters given in command line to build environment easily. Judging from scons-using ports that I've seen till now, this feature is not well known, and it is not mentioned in scons manual either, so I guess it'll be wise to mention it bsd.scons.mk as easiest and fastest way to make third party SConstruct support FreeBSD ports collection and respect system compiler/flags settings.

>How-To-Repeat:
>Fix:

--- bsd.scons.mk.patch begins here ---
--- bsd.scons.mk.orig	Sat Sep 16 17:32:45 2006
+++ bsd.scons.mk	Tue Feb 27 22:34:37 2007
@@ -8,6 +8,17 @@
 #
 # Please view me with 4 column tabs!
 
+#
+# Hint for porters:
+# To make third party SConstruct respect everything that is passed to scons
+# in SCONS_ENV (that is, most importantly, CC/CXX/CFLAGS/CXXFLAGS), just
+# patch it so build Environment is constructed in this way:
+#
+#   env = Environment(**ARGUMENTS)
+#
+# it may be then modified with env.Append and env.Replace
+#
+
 # Please make sure all changes to this file are passed through the maintainer.
 SCONS_MAINTAINER=	alexbl@FreeBSD.org
 
--- bsd.scons.mk.patch ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:



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