GCC 4.2.4?

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

GCC 4.2.4?

Jeffrey Walton-3
Hi All,

After installing GCC 4.2.4, I still have version 4.2.1. I've learned a
little about pkg_add, so I went hunting for the README.

$ find / -name gcc 2>/dev/null
/usr/local/lib/gcc
/usr/local/libexec/gcc
/usr/local/include/boost/mpl/aux_/preprocessed/gcc
/usr/bin/gcc

$ find /usr/local/lib/gcc -name README 2>/dev/null
/usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/include/README
/usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/install-tools/include/README

Not much to the install-tools/README:

    This README file is copied into the directory for GCC-only header files
    when fixincludes is run by the makefile for GCC.
   ...

Would anyone be able to point out my mistakes with installing GCC
4.2.4? There is no GCC 4.2.4 executable, and I'm catching a boatload
of c++ template errors
(http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656). I'm also hoping
Binutils will be updated.

Jeff

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Amit Kulkarni-5
> Hi All,
>
> After installing GCC 4.2.4, I still have version 4.2.1. I've learned a
> little about pkg_add, so I went hunting for the README.
>
> $ find / -name gcc 2>/dev/null
> /usr/local/lib/gcc
> /usr/local/libexec/gcc
> /usr/local/include/boost/mpl/aux_/preprocessed/gcc
> /usr/bin/gcc
>
> $ find /usr/local/lib/gcc -name README 2>/dev/null
> /usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/include/README
>
/usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/install-tools/include/README


err... don't hunt for README in a /usr/local/lib folder. do all your
hunting on the global port of gcc-4.2.4

> Not much to the install-tools/README:
>
>    This README file is copied into the directory for GCC-only header files
>    when fixincludes is run by the makefile for GCC.
>   ...
>
> Would anyone be able to point out my mistakes with installing GCC
> 4.2.4? There is no GCC 4.2.4 executable, and I'm catching a boatload
> of c++ template errors
> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656). I'm also hoping
> Binutils will be updated.
>
> Jeff

pkg_info -L gcc-4.2.4 (or whatever is the package name of gcc-4.2.4)
gives you a full list of files

http://www.openbsd.org/cgi-bin/man.cgi?query=pkg_info&sektion=1&format=html

is your friend

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Nicholas Marriott-2
In reply to this post by Jeffrey Walton-3
Ports gcc4 is called egcc so it doesn't conflict with base gcc4 which'll
stay as 4.2.1


On Thu, Sep 15, 2011 at 02:40:46PM -0400, Jeffrey Walton wrote:

> Hi All,
>
> After installing GCC 4.2.4, I still have version 4.2.1. I've learned a
> little about pkg_add, so I went hunting for the README.
>
> $ find / -name gcc 2>/dev/null
> /usr/local/lib/gcc
> /usr/local/libexec/gcc
> /usr/local/include/boost/mpl/aux_/preprocessed/gcc
> /usr/bin/gcc
>
> $ find /usr/local/lib/gcc -name README 2>/dev/null
> /usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/include/README
> /usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/install-tools/include/README
>
> Not much to the install-tools/README:
>
>     This README file is copied into the directory for GCC-only header files
>     when fixincludes is run by the makefile for GCC.
>    ...
>
> Would anyone be able to point out my mistakes with installing GCC
> 4.2.4? There is no GCC 4.2.4 executable, and I'm catching a boatload
> of c++ template errors
> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656). I'm also hoping
> Binutils will be updated.
>
> Jeff

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

LeviaComm Networks NOC
In reply to this post by Jeffrey Walton-3
On 15-Sep-11 11:40, Jeffrey Walton wrote:

> Hi All,
>
> After installing GCC 4.2.4, I still have version 4.2.1. I've learned a
> little about pkg_add, so I went hunting for the README.
>
> $ find / -name gcc 2>/dev/null
> /usr/local/lib/gcc
> /usr/local/libexec/gcc
> /usr/local/include/boost/mpl/aux_/preprocessed/gcc
> /usr/bin/gcc
>
> $ find /usr/local/lib/gcc -name README 2>/dev/null
> /usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/include/README
> /usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/install-tools/include/README
>
> Not much to the install-tools/README:
>
>      This README file is copied into the directory for GCC-only header files
>      when fixincludes is run by the makefile for GCC.
>     ...
>
> Would anyone be able to point out my mistakes with installing GCC
> 4.2.4? There is no GCC 4.2.4 executable, and I'm catching a boatload
> of c++ template errors
> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656). I'm also hoping
> Binutils will be updated.
>


Another example of the OS giving you enough rope to hang yourself.
Unless there is some burning need to run that version of gcc, I would
recommend staying away from upgrading it, at least until you understand
enough about the OS to fix this yourself.

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Jeffrey Walton-3
On Thu, Sep 15, 2011 at 3:01 PM, LeviaComm Networks <[hidden email]>
wrote:

> On 15-Sep-11 11:40, Jeffrey Walton wrote:
>>
>> Hi All,
>>
>> After installing GCC 4.2.4, I still have version 4.2.1. I've learned a
>> little about pkg_add, so I went hunting for the README.
>>
>> $ find / -name gcc 2>/dev/null
>> /usr/local/lib/gcc
>> /usr/local/libexec/gcc
>> /usr/local/include/boost/mpl/aux_/preprocessed/gcc
>> /usr/bin/gcc
>>
>> $ find /usr/local/lib/gcc -name README 2>/dev/null
>> /usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/include/README
>>
>>
/usr/local/lib/gcc/i386-unknown-openbsd4.9/4.2.4/install-tools/include/README

>>
>> Not much to the install-tools/README:
>>
>>     This README file is copied into the directory for GCC-only header
>> files
>>     when fixincludes is run by the makefile for GCC.
>>    ...
>>
>> Would anyone be able to point out my mistakes with installing GCC
>> 4.2.4? There is no GCC 4.2.4 executable, and I'm catching a boatload
>> of c++ template errors
>> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656). I'm also hoping
>> Binutils will be updated.
>>
>
>
> Another example of the OS giving you enough rope to hang yourself.
:)

> Unless there is some burning need to run that version of gcc, I would
> recommend staying away from upgrading it,
I'm interested in seeing if (1) patches have been applied to fix my
template error problem
(http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656); and (2) the
compiler/linker is using hardened settings (I know 4.2.1 is not
hardened out of the box).

> at least until you understand enough about the OS to fix this yourself.
I don't think I have that much time. But on the good side, I can
reinstall/restore the OS in about 45 minutes.

Jeff

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Marc Espie-2
On Thu, Sep 15, 2011 at 03:17:36PM -0400, Jeffrey Walton wrote:
> I'm interested in seeing if (1) patches have been applied to fix my
> template error problem
> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656); and (2) the
> compiler/linker is using hardened settings (I know 4.2.1 is not
> hardened out of the box).

lol.

4.2.1 *in OpenBSD* is "hardened" more, and has been tested as an hardened
compiler for more time than gcc 4.2.4.

(unless you want to get f*d harder by the GPLv3, that is)

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Jeffrey Walton-3
On Thu, Sep 15, 2011 at 5:23 PM, Marc Espie <[hidden email]> wrote:

> On Thu, Sep 15, 2011 at 03:17:36PM -0400, Jeffrey Walton wrote:
>> I'm interested in seeing if (1) patches have been applied to fix my
>> template error problem
>> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656); and (2) the
>> compiler/linker is using hardened settings (I know 4.2.1 is not
>> hardened out of the box).
>
> lol.
>
> 4.2.1 *in OpenBSD* is "hardened" more, and has been tested as an hardened
> compiler for more time than gcc 4.2.4.
I believe -z relro -z now are fairly standard for GOT and PLT attack
remediations. I know some flavors of Linux include them in the spec
file for a gcc:

  $ uname -a
  OpenBSD germain.home.pvt 4.9 GENERIC#671 i386
  $ /usr/local/bin/egcc -dumpspecs | grep -i relro
  $ /usr/local/bin/egcc -dumpspecs | grep -i wall
  $ /usr/local/bin/egcc -dumpspecs | grep -i wextra
  $ /usr/local/bin/egcc -dumpspecs | grep -i format
  $ /usr/local/bin/egcc -dumpspecs | grep -i security
  $

Also, I was not sure about -Wformat=2 -Wformat-security. I guess it
depends on what procedures are in place to enforce policy (or in
OpenBSD's case, its position on security).

> (unless you want to get f*d harder by the GPLv3, that is)
I sometimes wonder about the whole free software, free beer thing. Its
kind of like trying to figure out how US politicians claim to balance
a budget, yet the US is trillions in debt.

Jeff

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

J Sisson
On Thu, Sep 15, 2011 at 4:59 PM, Jeffrey Walton <[hidden email]> wrote:

> I sometimes wonder about the whole free software, free beer thing. Its
> kind of like trying to figure out how US politicians claim to balance
> a budget, yet the US is trillions in debt.
>
> Here's a hint:  Someone is *lying*.

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Theo de Raadt
In reply to this post by Jeffrey Walton-3
>From [hidden email] Thu Sep 15 16:03:31 2011
>DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:content-type; bh=kY1gasrwKPDiR1SMIn3cjJDmW1LWRP2RblMzlI6oeEY=; b=qE/NProQ4ve3hMGaGftTHEtUJK+BYxVPdg1Kop0TbfhKrTENshwjL12n0it66isGKc QkUV+jkkVeVNvoeLrotxXlj1qrGLAEJzNpaBgqSRPytKsyRa0srDrxAvKkQypPFOTjKi P9WXZ0SiW76Tk3UrEgoA3dG8MWwVtqRyUeO0o=
>MIME-Version: 1.0
>Reply-To: [hidden email]
>In-Reply-To: <[hidden email]>
>References: <[hidden email]> <[hidden email]> <CAH8yC8=iqkWU-G4Woeuhm6asx_cABCaXJ=yXwFcuypf=[hidden email]> <[hidden email]>
>Date: Thu, 15 Sep 2011 17:59:03 -0400
>Subject: Re: GCC 4.2.4?
>From: Jeffrey Walton <[hidden email]>
>To: [hidden email], Jeffrey Walton <[hidden email]>, [hidden email]
>Content-Type: text/plain; charset=ISO-8859-1
>List-Help: <mailto:[hidden email]?body=help>
>List-ID: <misc.openbsd.org>
>List-Owner: <mailto:[hidden email]>
>List-Post: <mailto:[hidden email]>
>List-Subscribe: <mailto:[hidden email]?body=sub%20misc>
>List-Unsubscribe: <mailto:[hidden email]?body=unsub%20misc>
>X-Loop: [hidden email]
>Precedence: list
>Sender: [hidden email]
>
>On Thu, Sep 15, 2011 at 5:23 PM, Marc Espie <[hidden email]> wrote:
>> On Thu, Sep 15, 2011 at 03:17:36PM -0400, Jeffrey Walton wrote:
>>> I'm interested in seeing if (1) patches have been applied to fix my
>>> template error problem
>>> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656); and (2) the
>>> compiler/linker is using hardened settings (I know 4.2.1 is not
>>> hardened out of the box).
>>
>> lol.
>>
>> 4.2.1 *in OpenBSD* is "hardened" more, and has been tested as an hardened
>> compiler for more time than gcc 4.2.4.
>I believe -z relro -z now are fairly standard for GOT and PLT attack
>remediations. I know some flavors of Linux include them in the spec
>file for a gcc:
>
>  $ uname -a
>  OpenBSD germain.home.pvt 4.9 GENERIC#671 i386
>  $ /usr/local/bin/egcc -dumpspecs | grep -i relro
>  $ /usr/local/bin/egcc -dumpspecs | grep -i wall
>  $ /usr/local/bin/egcc -dumpspecs | grep -i wextra
>  $ /usr/local/bin/egcc -dumpspecs | grep -i format
>  $ /usr/local/bin/egcc -dumpspecs | grep -i security
>  $
>
>Also, I was not sure about -Wformat=2 -Wformat-security. I guess it
>depends on what procedures are in place to enforce policy (or in
>OpenBSD's case, its position on security).
>
>> (unless you want to get f*d harder by the GPLv3, that is)
>I sometimes wonder about the whole free software, free beer thing. Its
>kind of like trying to figure out how US politicians claim to balance
>a budget, yet the US is trillions in debt.
>
>Jeff

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Theo de Raadt
In reply to this post by Jeffrey Walton-3
>I sometimes wonder about the whole free software, free beer thing. Its
>kind of like trying to figure out how US politicians claim to balance
>a budget, yet the US is trillions in debt.

http://en.wikipedia.org/wiki/Ben_Tre

It became necessary to encumber the software to free it.

Reply | Threaded
Open this post in threaded view
|

Re: GCC 4.2.4?

Tomas Bodzar-4
In reply to this post by Jeffrey Walton-3
On Thu, Sep 15, 2011 at 11:59 PM, Jeffrey Walton <[hidden email]> wrote:

> On Thu, Sep 15, 2011 at 5:23 PM, Marc Espie <[hidden email]> wrote:
>> On Thu, Sep 15, 2011 at 03:17:36PM -0400, Jeffrey Walton wrote:
>>> I'm interested in seeing if (1) patches have been applied to fix my
>>> template error problem
>>> (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21656); and (2) the
>>> compiler/linker is using hardened settings (I know 4.2.1 is not
>>> hardened out of the box).
>>
>> lol.
>>
>> 4.2.1 *in OpenBSD* is "hardened" more, and has been tested as an hardened
>> compiler for more time than gcc 4.2.4.
> I believe -z relro -z now are fairly standard for GOT and PLT attack
> remediations. I know some flavors of Linux include them in the spec
> file for a gcc:
>
> B $ uname -a
> B OpenBSD germain.home.pvt 4.9 GENERIC#671 i386
> B $ /usr/local/bin/egcc -dumpspecs | grep -i relro
> B $ /usr/local/bin/egcc -dumpspecs | grep -i wall
> B $ /usr/local/bin/egcc -dumpspecs | grep -i wextra
> B $ /usr/local/bin/egcc -dumpspecs | grep -i format
> B $ /usr/local/bin/egcc -dumpspecs | grep -i security
> B $
>
> Also, I was not sure about -Wformat=2 -Wformat-security. I guess it
> depends on what procedures are in place to enforce policy (or in
> OpenBSD's case, its position on security).
>
>> (unless you want to get f*d harder by the GPLv3, that is)
> I sometimes wonder about the whole free software, free beer thing. Its
> kind of like trying to figure out how US politicians claim to balance
> a budget, yet the US is trillions in debt.

Second point  http://www.openbsd.org/goals.html which leads to
http://www.openbsd.org/policy.html as well

Probably one of the reasons for  http://www.bsdfund.org/projects/pcc/
( http://undeadly.org/cgi?action=search&mode=&thres=&query=pcc ) and
http://clang.llvm.org/

>
> Jeff