Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Oct 2012 10:27:55 -0500
From:      Brooks Davis <brooks@freebsd.org>
To:        Andriy Gapon <avg@freebsd.org>
Cc:        toolchain@freebsd.org, Gerald Pfeifer <gerald@freebsd.org>
Subject:   Re: gcc46 --version incompatible with bsd.compiler.mk
Message-ID:  <20121015152755.GC10224@lor.one-eyed-alien.net>
In-Reply-To: <5078102C.3070503@FreeBSD.org>
References:  <5078102C.3070503@FreeBSD.org>

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

--ncSAzJYg3Aa9+CRW
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Fri, Oct 12, 2012 at 03:42:20PM +0300, Andriy Gapon wrote:
>=20
> Gerald,
>=20
> $ gcc46 --version
> gcc46 (FreeBSD Ports Collection) 4.6.3
>=20
> I think that the above should have just "gcc" instead of "gcc46".  The ve=
rsion is
> reported separately from the compiler name.
> The above output confuses bsd.compiler.mk.

Alternatively I could alter bsd.compiler.mk to accept gcc[1-9][0-9] as
gcc.  You could also set COMPILER_TYPE to override the check entirely.

The end state that got proposed at the Cambridge devsummit was that
external toolchains would provide a makefile that bsd.compiler.mk could
include that would handle this.  An example implementation would be to
add something like the following to the top of bsd.compiler.mk:

=2Eif defined(TOOLCHAIN_MK) && exists(${TOOLCHAIN_MK})
=2Einclude ${TOOLCHAIN_MK}
=2Eendif

You could then point TOOLCHAIN_MK to a file that might look something
like (I'm not sure the CC assignments would actually work here, but you
get the idea):

CC=3Dgcc46
CXX=3Dg++46
CPP=3Dcpp46
COMPILER_TYPE=3Dgcc
COMPILER_FEATURES=3D

-- Brooks

--ncSAzJYg3Aa9+CRW
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (FreeBSD)

iD8DBQFQfCt6XY6L6fI4GtQRAgreAKDnGQhD1Mx0CpYOAS7PzNCMdwI5BACgiWn1
kG5N6wlovb+I57nyW+1YtOo=
=KpdU
-----END PGP SIGNATURE-----

--ncSAzJYg3Aa9+CRW--



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