|
|
C for OS X, where?
|
|
|
|
Junior Member
Join Date: Jun 2001
Location: Asbury Park
Status:
Offline
|
|
The subject says it all, a friend is looking for GNU C compiler, where can we get it?
|
Woggle
'I will not be pushed, filed, indexed, stamped, briefed, debriefed or numbered. My life is my own.'-- No. 6
|
|
|
|
|
|
|
|
Admin Emeritus
Join Date: Oct 2000
Location: Boston, MA
Status:
Offline
|
|
The Dev Tools (connect.apple.com) come with Apple's modified version of gcc (called cc), and g++ (called c++).
|
"Against stupidity, the gods themselves contend in vain" (Schiller)
|
|
|
|
|
|
|
|
Dedicated MacNNer
Join Date: Jun 2000
Location: Dundas, Ontario, Canada
Status:
Offline
|
|
cc should do whatever you need but, if you really want gcc, it can be compiled for OS X. A friend of mine compiled it for me once back in the public beta days during his free time. As I recall, the only thing that had to be done to compile gcc is to download the compiler source and change one of the configuration files to indicate that it will be compiling Power PC code. I don't know where the option was, specifically, but you could find it with a little work.
I just don't know why you would want to use gcc since cc seems to work fine already.
Jeff.
|
|
|
|
|
|
|
|
|
Registered User
Join Date: Jun 2001
Location: Texas
Status:
Offline
|
|
doesn't power bulder do that? Power Builder is on the OSX Developers CD.
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Mar 2000
Location: London, UK
Status:
Offline
|
|
Originally posted by whodisbe:
<STRONG>doesn't power bulder do that? Power Builder is on the OSX Developers CD.</STRONG>
Project Builder (not Power Builder) is just an IDE built around gcc. At its heart, it still uses gcc to do all the compiling.
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Mar 2000
Location: London, UK
Status:
Offline
|
|
Originally posted by Apocalypse:
<STRONG>cc should do whatever you need but, if you really want gcc, it can be compiled for OS X. A friend of mine compiled it for me once back in the public beta days during his free time. As I recall, the only thing that had to be done to compile gcc is to download the compiler source and change one of the configuration files to indicate that it will be compiling Power PC code. I don't know where the option was, specifically, but you could find it with a little work.
I just don't know why you would want to use gcc since cc seems to work fine already.</STRONG>
cc IS gcc.
[localhost:~] finlayd% cc -v
Reading specs from /usr/libexec/gcc/darwin/ppc/2.95.2/specs
Apple Computer, Inc. version gcc-926, based on gcc version 2.95.2 19991024 (release)
You cannot compile gcc 2.95.x (which Apple's gcc is based off) on Mac OS X. You can compile gcc 3.0.x on OS X as a cross-compiling target, I *think*. There is work underway to port gcc 3.1 to OS X, should you really need it, but it's a moving target. You can get more information on it from Stan Shebs, it's available from anoncvs.opensource.apple.com (module gcc3), and you should search the archives of [email protected] (archives available at http://www.darwinfo.org). You will have almost definitely no need to compile gcc3 though.
|
|
|
|
|
|
|
|
|
Senior User
Join Date: Jan 2001
Location: california
Status:
Offline
|
|
when you run the srcdir/configure, use it with --host=powerpc
<BLOCKQUOTE><font size="1"face="Geneva, Verdana, Arial">code:</font><HR><pre><font size=1 face=courier>
srcdir/configure --host=powerpc
</font>[/code]
this, however, will only get you so far. ended up not working with gcc 2.95.3. somewhere on gcc.gnu.org it says that powerpc-darwin will work in build 3.1, but they're only at 3.0 right now.
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Mar 2000
Location: London, UK
Status:
Offline
|
|
Originally posted by superlarry:
<STRONG>this, however, will only get you so far. ended up not working with gcc 2.95.3. somewhere on gcc.gnu.org it says that powerpc-darwin will work in build 3.1, but they're only at 3.0 right now.</STRONG>
Well yes, as I said
3.0 *WILL* build on Darwin as a cross-compiler, though. It just won't build native (and even if it did, you wouldn't be able to use it for things like Obj-C because Apple's runtime is different and incompatible). Stan Shebs is working really hard on 3.1, though
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Forum Rules
|
|
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
|
|
|
|
|
|