Skip to main content
Rick E Johnson
Inspiring
June 11, 2009
Answered

porting tips (Mac <-> Win)

  • June 11, 2009
  • 1 reply
  • 820 views

For years, I worked in CodeWarrior, and I was able to do cross-platform development of Adobe Illustrator plugins rather easily using one code base, with a few specialized files for each platform, and only one compiler with various targets for debug/release and Mac/Windows. I've documented what I did here, but now using Xcode and Visual Studio, everything's changed. In my case, I'm starting with the Mac project and porting it to the PC, but I'm sure there are just as many working the other direction. Do you have favorite tips for porting between platforms that you'd be willing to share, particularly regarding porting resources? Thanks! -- Rick

This topic has been closed for replies.
Correct answer A. Patterson

Resources are a pain. There's no real way to share them unfortunately, since they use such widly different mechanisms. We solved a lot of our problems by simply using Qt for our dialogs. We still have to share resources for ADM-related stuff like panels, but everything else is very cross-platform. We even use the qmake system to share project files -- sort of. With qmake you create .pro files that you run through qmake, which spits out the platform you request. So we manage a single .pro file and it creates Xcode & VS project files.

As for code, most of our code is cross-platform, except some of the resource loading stuff.

1 reply

A. Patterson
A. PattersonCorrect answer
Inspiring
June 11, 2009

Resources are a pain. There's no real way to share them unfortunately, since they use such widly different mechanisms. We solved a lot of our problems by simply using Qt for our dialogs. We still have to share resources for ADM-related stuff like panels, but everything else is very cross-platform. We even use the qmake system to share project files -- sort of. With qmake you create .pro files that you run through qmake, which spits out the platform you request. So we manage a single .pro file and it creates Xcode & VS project files.

As for code, most of our code is cross-platform, except some of the resource loading stuff.