The project importer in Xcode communicates with CodeWarrior through Apple events. Once you’ve specified a CodeWarrior project to import, the importer tells CodeWarrior to make a copy of the project, then sets various settings and performs other operations to prepare the copy. The importer tells CodeWarrior to export the copied project, then reads the exported XML and uses that information to set up the new Xcode project. The importer displays a status dialog while importing. On completion, the status dialog is dismissed and the new project opens.
Some other features include:
By default, the CodeWarrior importer adds a Source Tree entry to your Xcode preferences named “CodeWarrior”. This entry maps to CodeWarrior’s {Compiler} relative path access path. The importer will not overwrite an existing source tree of the same name.
The importer can optionally import global source tree data from CodeWarrior.
The new project uses the Xcode native build system for all imported CW targets. This system is described in “Native Build System.”
The importer supports importing cross-project references.
The importer supports importing dependent projects automatically.
You can write an AppleScript script to automate importing CodeWarrior projects, using the import AppleScript command (in the Xcode Application Suite).
For Best Results When Importing
Known Issues With the Importer
For best results when importing, you should follow these steps:
Some import steps can be CPU-intensive and time-consuming—for example, importing multiple projects (due to dependent projects) can launch many threads, while searching for included files in a large project can take some time.
Avoid performing other compute-intensive tasks during large imports. If possible, allow the machine to work only on the import.
Use CodeWarrior Pro version 8.3 or later for projects that you will import into Xcode. The earlier your version of CodeWarrior, the more likely it is that problems will occur.
The following are some problems that have been observed. For the latest information, see the Xcode 3.0 Release Notes.
The importer does not currently support bringing in CW Targets that use the Java Linker or the Mac OS Merge Linker.
A successful import does not imply that your project will build successfully, since (by design) the importer does not modify source files. See “After Importing a Project” for additional steps you may need to take.
It may happen that an AppleScript or CodeWarrior error occurs during the import. If so, check the Console for details and try importing again.
One possible cause is that you previously quit CodeWarrior with a project open, then moved or deleted that project. When the importer sends an Apple event to launch CodeWarrior, CodeWarrior puts up an error dialog reporting it can’t find the previously open project. That freezes the process, and eventually the Apple event times out and the import stops. The importer status dialog may remain on screen until you next quit and relaunch Xcode.
If an import fails repeatedly, please file a bug with as much detail as possible. See “Feedback and Mail List” for information on filing bugs.
If CodeWarrior prompts you to install the Interface Builder connection and your project fails to import, make sure that you have CodeWarrior running before trying the import again.
Even though your CodeWarrior application uses Carbon, if it doesn’t use framework-style headers, the importer may not add the Carbon framework to the new Xcode project.
Last updated: 2006-10-26