Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

macroy

macrumors newbie
Original poster
Jul 8, 2004
4
0
Our requirement is to code in Carbon using Xcode and must be compatible in both versions of MAC OS X./8.6/9. is that possible ?

we are quite new to the mac environment. so it would be greatful if anyone could suggest some suggestions...

also there are certain doubts regarding..

1. Hardware Interface – How can we overcome this two different architectural device driver problem? Is carbon providing any APIs to work across different OS versions

2.While running over 68K processor there are lot of obsolete managers like Trap Manager, Trap Table, Mixed Mode Manager and Patch Manager, what are they? Do we really need them? If so as per your comments MAC OS X doesn’t support them, then what are the available options?

3.Can we use C++ along with Carbon?

4.Which compiler you prefer to compile the application?

5.Is it possible for us to going a native calls i.e. BSD/POSIX APIs while taking into consideration that the underlying kernel is a UNIX variant? If so what are the limitations?

Thanking You,

rG.
 
Whilst I'm really a Cocoa person I can help you a bit. Carbon is a subset of the OS 9 APIs (more or less). Carbon libs are designed to allow an application to run without recompile on both OSX and OS9. Whislt carbon libs existed for some versions of OS8 I'm not sure that the latest versions are available. Carbon is only available to C++. XCode contains compilers that will happily compile carbon code (they are all gcc based). If you are shooting for pre-OSX compatability then making calls outside of carbon to the BSD layer (or Posix calles) is not a good idea. OS8/9 are not Unix based, do not have the BSD layer and are not Posix compliant.

Hope that helps.
 
While Carbon-ised code is supported on both platforms, there are some constraints. i.e., Mac OS X and Mac OS 9.x will use .Nib files but earlier versions must use resource (.r, .rsrc) files. If you need to go back further, you will need to use MetroWerks CodeWarrior.

You may use either C or C++ with Carbon but since the libraries were meant for C they provide no C++ exceptions. However, being able to register an event and the callback works just fine.

If you use gestalt calls to determine the operating system, you should be fine in making UNIX calls within Carbon code. You would probably be wise to keep that code in a separate source file, though.
 
Who would require anyone to code in Carbon for Mac OS X/8.6/9 these days. Is this some kind of entry ritual to the guild of masochistic geeks?? :p
 
gekko513 said:
Who would require anyone to code in Carbon for Mac OS X/8.6/9 these days. Is this some kind of entry ritual to the guild of masochistic geeks?? :p

Cross platform code is much easier to write with Carbon than with Cocoa.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.