< Previous PageNext Page > Hide TOC

Importing a CodeWarrior Project Into Xcode

This chapter provides a brief walk-through of importing a CodeWarrior project into Xcode. It assumes you’ve read “Xcode From a CodeWarrior Perspective ” and taken any appropriate preparatory steps listed in “Preparing a CodeWarrior Project for Importing.”

In this section:

About the Importer
Importing a Project


About the Importer

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:

For Best Results When Importing

Important: CodeWarrior must be running when you import your project.

For best results when importing, you should follow these steps:

Known Issues With the Importer

The following are some problems that have been observed. For the latest information, see the Xcode Release Notes.

Importing a Project

Importing a CodeWarrior project is very straightforward. First, make sure you’ve read the information in “For Best Results When Importing” and “Known Issues With the Importer.” Then follow these steps:

  1. Choose File > Import Project, which opens the Import Project assistant.

  2. Select Import CodeWarrior Project and click the Next button to bring up the pane shown in Figure 3-1.

    Figure 3-1  The Import CodeWarrior Project pane

    The Import CodeWarrior Project pane
  3. Click the Choose button and navigate to the CodeWarrior project file to import (or type in the path and filename).

    When you choose or type a project file to import, Xcode automatically uses the same name for the new project. However, you are free to change the project name in the New Project Name field. The new project is created in the same folder as the CodeWarrior project file, and has the extension .xcodeproj. (If you are using Xcode 2.0 or earlier, the project has the extension .xcode .)

  4. When you import a project, Xcode determines the location of the CodeWarrior root folder (commonly referred to as {Compiler} in CodeWarrior’s access paths) and adds it to the Source Trees list in the Preferences window, with the Setting Name “CodeWarrior” and Display Name “CodeWarrior Folder”.

    Select the checkbox Import “Global Source Trees” from CodeWarrior if you want the importer to add any global source trees from CodeWarrior’s preferences to the Source Trees list in Xcode. For more information about Source Trees, see “Source Trees.”

    If you select the checkbox “Import referenced projects,” Xcode also imports any projects that the selected CodeWarrior project references. For any referenced projects it imports, the importer uses the name of the referenced CodeWarrior project, with an extension of .xcodeproj.

  5. Click the Finish button to dismiss the assistant and start the import.

  6. You can follow the process of the import in the Import status window. Once the import is complete, the new project window opens, and in some cases asks you to choose an encoding.

    In most cases, you should be able to choose the suggested encoding (in this case, “Western (Mac OS Roman)”). If you are unsure, click the Give Me Advice button for more information.

For most projects, it is unlikely that the software will build and run immediately after importing. See “After Importing a Project” for steps you may need to take to get your imported CodeWarrior project to build in Xcode.



< Previous PageNext Page > Hide TOC


© 2003, 2006 Apple Computer, Inc. All Rights Reserved. (Last updated: 2006-10-26)


Did this document help you?
Yes: Tell us what works for you.
It’s good, but: Report typos, inaccuracies, and so forth.
It wasn’t helpful: Tell us what would have helped.