public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] GCC 3.0 use flag?
@ 2002-03-27  9:32 Preston A. Elder
  0 siblings, 0 replies; only message in thread
From: Preston A. Elder @ 2002-03-27  9:32 UTC (permalink / raw
  To: gentoo-user; +Cc: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1825 bytes --]

Hi all,

What do you all think of adding a 'gcc3' USE flag.  This could be used
to activate special patches/flags that are only required on GCC 3.0 (and
above), and possibly break compilation by 2.95.3 if used.

More and more as I look at things, its getting necessary to know which
compiler will be building a package.  The example I can think of off the
top of my head, is that I'm creating an ebuild file for openoffice 641c
(currently only 641b is in the archive).

Openoffice has a configure flag, called --enable-gcc3, for when
compiling with the 3.0.x compiler suite.  Openoffice has moved to 3.0.x
for their linux builds as of 641c (641b I believe they still used
2.95.x).  I'm not even sure if it still compiles on 2.95.x, but it
should, however I would love to be able to give the option to compile
with either, and just set the flag if its gcc 3.0.x.

I could figure out the compiler version by doing:
    GCC_MAJOR=`gcc --version | cut -f1 -d.`
and then
    local myflags
    if [ $GCC_MAJOR == 3 ]; then
         myflags="--enable-gcc3"
    fi
then simply add $myflags to the configure options.

however the above seems like (and is) a hack.  Plus, when patches start
being made to fix code that wont compile on gcc 3.0.x (see my previous
email), we're going to NEED to know the gcc version in use.  Hense, I
would suggest a gcc3 use flag.  That, or there could be a default
veriable offered by portage which contains the GCC version (now THAT
would be cool, but not expected).

Anyway,

Comments? opinions?

-- 
PreZ
Systems Administrator
GOTH.NET

Goth Code '98:   tSKeba5qaSabsaaaGbaa75KAASWGuajmsvbieqcL4BaaLb3F4
                 nId5mefqmDjmmgm#haxthgzpj4GiysNkycSRGHabiabOkauNSW

GOTH.NET - http://www.goth.net
Free online resource for the gothic community.

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 232 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-03-27  9:36 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-03-27  9:32 [gentoo-dev] GCC 3.0 use flag? Preston A. Elder

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox