Subject: Re: test for gcc3 ?
To: Manuel Bouyer <bouyer@antioche.eu.org>
From: Juan RP <juan@xtraeme.unixbsd.org>
List: tech-pkg
Date: 03/19/2004 22:12:20
--Signature=_Fri__19_Mar_2004_22_12_20_+0100_5mH0dNmTBsl7WSZf
Content-Type: text/plain; charset=US-ASCII
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

On Fri, 19 Mar 2004 21:49:11 +0100
Manuel Bouyer <bouyer@antioche.eu.org> wrote:

> Hi,
> what is the appropriate test to know if we are using gcc3 or some other kind
> of compiler ?
> I need to do this for emacs:
> .if ${OPSYS} == "SunOS"
> CFLAGS+=        -fno-zero-initialized-in-bss
> .endif
> but only if using gcc3 (this doesn't exists in gcc2).

[juan@Nocturno][/usr/pkgsrc/devel/glib2]> make show-var VARNAME=CC_VERSION
gcc-3.3.3
[juan@Nocturno][/usr/pkgsrc/devel/glib2]>

You could use PKGSRC_COMPILER too I guess.

HTH,
-- 
	Juan RP <juan@xtraeme.unixbsd.org>

--Signature=_Fri__19_Mar_2004_22_12_20_+0100_5mH0dNmTBsl7WSZf
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (NetBSD)

iD4DBQFAW2I3ypkLYVDran0RAgi/AJj6qLhuT7pUEQ454fmbyX6wJ1qMAJ9ujF9y
AdRkYqFiBOM4Sxx7QcVmWg==
=PZYj
-----END PGP SIGNATURE-----

--Signature=_Fri__19_Mar_2004_22_12_20_+0100_5mH0dNmTBsl7WSZf--