Please Explain Process to Carbonize/Cocoaize a Program for OS X

Posted:
in macOS edited January 2014
I'm really curious as to how much goes into making a program OS X native.



-- I know that Carbonizing is a lot shorter/easier process, but what specifically has to be done?

-- How does that process compare with Cocoaizing?



Please reply in layman's terms for us non-Unix-speaking folk, but be thorough. I'm really interested in knowing this.

Comments

  • Reply 1 of 2
    There is no "cocoaizing" process. A program has to be completely re-written from the ground up, most likely also in a different programming language than the original.



    Carbonizing means taking old, outdated system calls and replacing them with newer ones. That's all. Of course, to make a *good* Carbon port, you have to rewrite the way you manage various events.
  • Reply 2 of 2
    amorphamorph Posts: 7,112member
    [quote]Originally posted by starfleetX:

    <strong>There is no "cocoaizing" process. A program has to be completely re-written from the ground up, most likely also in a different programming language than the original.</strong><hr></blockquote>



    Unless it's an old NeXTStep/OpenStep program.



    Generally, though, for Mac users, writing in Cocoa means starting from zero. Although, with the advent of Objective-C++, it's now possible to build existing C++ code (which forms a sizable chunk of the code in existence, including Mac and Windows code) into a Cocoa app - for example, you can take the engine from a UNIX or MacOS or Windows program and hitch it to a Cocoa interface.



    [quote]<strong>Carbonizing means taking old, outdated system calls and replacing them with newer ones. That's all. Of course, to make a *good* Carbon port, you have to rewrite the way you manage various events.</strong><hr></blockquote>



    Depending on how much your code depended on crufty parts of e.g. the filesystem, you might have to rewrite a lot. Also, a lot of menu- and window-handling code has to go, and printing code (which was some of the hairiest, nastiest code in most MacOS apps). And if you want to adopt Services or use sheets or Dock menus or other Mac OS X specific behavior, you have to code specifically for that (and the code won't work in OS 9).



    [ 01-26-2002: Message edited by: Amorph ]</p>
Sign In or Register to comment.