PDA

View Full Version : Compiler required


Hawksun
2002.07.03, 07:13 PM
Hello everybody. I downloaded MPW recently to sink my teeth into programming, but it is way too overwhelming for me. So i would like to know if there are any free compilers for the Mac out there.(C/C++ compilers preferably) Thanks for help.

Carlos Camacho
2002.07.03, 07:32 PM
Did you check our FAQ, to see if that answer is in there?
If not... If you have Mac OS X, Apple has what you want.. for free.
For Classic (before Mac OS X), there are no FREE C/C++ compiliers to my knowledge.

If you want an alternative language, then you can get some things for free, like METAL and Think Pascal.

I recall "Harvest C", but don't remember anything about it. There were some old C/C++ tools by Symantec and VIP series, but they are all discontinued. (Symantec allowed Pascal to be distributed... Someone should but them for their C and C++ products.) VIP is RIP as far as I know.

I would recommend getting CodeWarrior LE for Classic stuff. It is cheap. If you are a student, you can also get discounts on CW Pro. Overall though, you may be better off with Apple's X tools.

Cheers

Hawksun
2002.07.03, 07:46 PM
Sorry i didn't think about checking the faqs. Thanks for your solutions, i'll check them out, especially CLE. If i could just get a little more cash i'd buy it immediately.

monteboyd
2002.07.03, 07:48 PM
MPW is overwhleming at first, but please post any questions you have about it here. There are a couple of us who use it and you really don't need to know much about it to be able to compile a program. Let us know what you are aiming to compile for (e.g. Carbon, OpenGL, Classic etc.) and someone might be able to post the MakeFile for it here.

Don't give up on MPW if you are working on OS9, free tools are the best!

Hawksun
2002.07.03, 07:56 PM
Well i will try to experiemnt a bit more with it and continue to read documentation on it before asking questions since the answer might just lie somewhere near. I f i have questions i'll ask them tough.

ClarustheDogCow
2002.07.03, 08:51 PM
Originally posted by Camacho
If you have Mac OS X, Apple has what you want.. for free.
For Classic (before Mac OS X), there are no FREE C/C++ compiliers to my knowledge.
MPW has free Classic compiling=]
I wouldn't dive into programing without a book. Take my word for it.
And Carbon and 68k, along with some Z80 tools (other places). Its realy a nice package if you haven't looked at it.

But I would have to reccomend if you purchase a compiler, there really is not much to decide between-get codewarrior. I would even recommend the developers edition for the PDF's alone. It has very good guides to the core elements of programming C and C++ (and Java, I belive). And you can use MPW's compilers to build any Carbon or Classic shareware that you come up with so you could buy CodeWarrior 8=]

Hawksun
2002.07.03, 08:54 PM
Good strategy, i'll try that. Once i get MPW working everything is going to be fine, i think.

RedWolf
2002.07.03, 09:51 PM
Originally posted by Camacho
> For Classic (before Mac OS X), there are no FREE C/C++ compiliers
> to my knowledge.

mrc and mrcpp are free C and C++ compilers that come with MPW. These are very good compilers and probably are still way ahead of the gcc compiler available with OS X. I think actually there's a plugin that allows these compilers to be invoked from CodeWarrior. In any case, MPW is a free download (originally you did have to pay for it, which I did) but MPW is no longer being maintained. Still, if you're just programming as a hobby under Classic, you can't beat the price. Metrowerks CodeWarrior may be nice but it is just too expensive for most hobbyists (unless you can somehow manage to get the educational price).

RedWolf
2002.07.03, 09:54 PM
Originally posted by Hawksun
> Well i will try to experiemnt a bit more with it and continue to read documentation on it
> before asking questions since the answer might just lie somewhere near.
> I f i have questions i'll ask them tough.

Probably the best place to ask questions on MPW, is the MPW developers list maintained by Apple:

http://www.lists.apple.com/mailman/listinfo/mpw-dev

ClarustheDogCow
2002.07.03, 10:51 PM
While we are on the topic of MPW, I'd like to mention the rabid fan base=]
Here are some things to get you along:

http://calyxa.best.vwh.net/mpw4newbies.html
A very good link for learning MPW. This is the most important for you now.

ftp://sunsite.cnlab-switch.ch/software/platform/macos/src/HTML/MPW_C.html
Tons of example code that builds with MPW to get your noggin coggin

http://www.wave.co.nz/~ldo/MPW/intro.html
Good guide for the more advanced elements of MPW

http://www3.ocn.ne.jp/~ribbon/MacAppMPW/
This is a must for advanced programming techniques in C++. It has information to get the STLport kit working. This is something you will find helpful later.

You can get Open-GL working fairly easily. Do a search on the mpw-dev archives to find it. I couldn't find a tutorial on the web so mabye I'll make one=]

General tips:
-When working with quickdraw, make sure to make a global variable for it.
-If you ever want to delve into assembly, MPW also has assemblers. PPCAsm is one.
-Type help and then return to give a listing of the various built in help topics. You probably want Help PowerMacintosh.
-You don't need to derez resources if you use ResEdit, only add them when creating a makefile.
-Projecter comes with MPW, which is basically like offline CVS. It helps you track the changes you make to your project.

Have fun=]

Carlos Camacho
2002.07.04, 02:44 AM
ClarustheDogCow,

I'd like to nominate you to write an article or tutorial with the above information. i.e. For someone who comes to the Mac, and isn't on X, show them what they need, what they can do, tricks, where to go and what to read, etc... I think that would be helpful. If you don't have THAT much info, then please add it to our WIKI FAQ.

Thanks

Hawksun
2002.07.04, 10:42 AM
Yippee! Thanks a lot Clarus! I'll add those links to my database.