Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Jun 2010 15:26:53 +0000 (UTC)
From:      Janne Snabb <snabb@epipe.com>
To:        bf1783@gmail.com
Cc:        freebsd-ports@freebsd.org
Subject:   Re: mail/thunderbird3 does not build with gcc 4.5.1
Message-ID:  <alpine.BSF.2.00.1006221504000.22303@tiktik.epipe.com>
In-Reply-To: <AANLkTimGZBtrAC-zg3Y9YzwJn9_eP8Zik_xehQRGDlHt@mail.gmail.com>
References:  <AANLkTikhO6G4GIQee4dNZdTwN4pDR3BkKbWVBN2ReiuK@mail.gmail.com> <4C206505.2060601@FreeBSD.org> <AANLkTimGZBtrAC-zg3Y9YzwJn9_eP8Zik_xehQRGDlHt@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 22 Jun 2010, b. f. wrote:

> I can tell you right now from my own experiences that the ports
> infrastructure and many individual ports do not respect the necessary
> compiler and toolchain-related variables.

Part of this problem is that the Porters Handbook only tells porters
to respect CC, CXX and CFLAGS, nothing else.

This issue came up as well in the "Building ports with stack-protector"
thread a couple of weeks ago (by yourself).

What would be the comprehensive list of variables to respect?

There are already quite many from the top of my head:

CC
CFLAGS
CXX
CXXFLAGS
CPP
CPPFLAGS
LD
LDFLAGS
AS
AFLAGS
AR
ARFLAGS
RANLIB
INSTALL
OBJCOPY

Some of the above would generally be required to be respected only
when cross-compiling to an another architecture.

I have been thinking of making a test build of all ports with some
useless options in relevant variables and capturing output or doing
ktrace to figure out which ports respect those flags and which do
not. Haven't gotten around to actually doing it just yet :).

Another work-around would be to make a directory containing
wrapper-shell-scripts with the names like cc, gcc, ld, cpp etc.
and make them invoke the desired tools with desired flags. That
directory would be placed in the beginning of PATH before compiling
ports. This would be a quicker alternative to patching lots of
ports.

--
Janne Snabb / EPIPE Communications
snabb@epipe.com - http://epipe.com/



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