On Thu, May 01, 2008 at 01:19:18PM +0100, Ian Lynagh wrote:
> On Wed, Apr 30, 2008 at 08:38:37AM -0500, John Goerzen wrote:
> > 
> > When I try to build programs with -fvia-C, I get:
> > 
> > cc1: error: unrecognized command line option "-fno-toplevel-reorder"
> > 
> > gcc is 4.2.2-1 here.
> 
> Works for me:
> 
> $ gcc -fno-toplevel-reorder q.c 
> $ gcc --version
> gcc (GCC) 4.2.2 (Debian 4.2.2-1)
> Copyright (C) 2007 Free Software Foundation, Inc.
> This is free software; see the source for copying conditions.  There is
> NO
> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR
> PURPOSE.

Interesting:

[EMAIL PROTECTED]:/tmp$ dpkg -l gcc
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-files/Unpacked/Failed-config/Half-installed
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name           Version        Description
+++-==============-==============-============================================
ii  gcc            4:4.2.2-1      The GNU C compiler
[EMAIL PROTECTED]:/tmp$ gcc --version
gcc (GCC) 4.1.3 20071209 (prerelease) (Debian 4.1.2-18)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[EMAIL PROTECTED]:/tmp$ ls -l /usr/bin/gcc*
lrwxrwxrwx 1 root root      7 Apr  2 12:38 /usr/bin/gcc -> gcc-4.1
-rwxr-xr-x 1 root root 204836 Dec  9 09:48 /usr/bin/gcc-4.1
-rwxr-xr-x 1 root root 192532 Jan  2 12:28 /usr/bin/gcc-4.2
-rwxr-xr-x 1 root root  16312 Dec  9 09:46 /usr/bin/gccbug-4.1
-rwxr-xr-x 1 root root   2018 Apr  8  2007 /usr/bin/gccmakedep

In any case, it seems like ghc ought to be calling the compiler for
the specific version that it wants, as /usr/bin/gcc can point to
different things at different times, or on different archs.

> 
> $ ghc -fvia-C q.hs
> $ dpkg -s ghc6 | grep "^Version"
> Version: 6.8.2-2
> 
> 
> Thanks
> Ian
> 
> 
> 
> 
> 

-- 
John Goerzen
Author, Foundations of Python Network Programming
http://www.amazon.com/exec/obidos/tg/detail/-/1590593715



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to