Porting CodeWarrior Projects to Xcode
PDF
Introduction
Xcode From a CodeWarrior Perspective
The Basic Development Environment
Some Special Features of Xcode
The Project Window
Customizing the Environment
Limitations
Companion Applications
Header Files
Framework-Style Headers
Cross-Development
Precompiled Headers and Prefix Files
Pragma Statements
C and C++ Libraries
Runtime and Library Issues
Support for wchar_t and wstring
The GCC Compiler
More on GCC Compiler Versions
Additional Compiler Information
C++ Code in C Files
Inline ASM
The Linker
Dead Code Stripping
The Information Property List and .plc Files
Working With Resources
Building Code
Native Build System
Build Configurations
Creating Debug and Non-Debug Products
Automating the Build Process
Makefiles
Exporting Symbols
Debugging
Prebinding
Source Trees
Source Control
PowerPlant
Maintaining Parallel Projects in Xcode and CodeWarrior
Executable Format
Framework and System Headers
Using Precompiled Headers and Prefix Files
Property Lists
Code Differences
Linking
Preparing a CodeWarrior Project for Importing
Convert Classic Applications to Use Carbon
Use the Application Package Type
Build the Application in the Mach-O Format
Convert to Mach-O Format
Use Framework Headers
Use C99 Standard in Language Settings
Migrate from MSL to System C and C++ Libraries
Replace Your Prefix File
Test Your Mach-O Target
Remove Unnecessary Targets From the Project
Importing a CodeWarrior Project Into Xcode
About the Importer
For Best Results When Importing
Known Issues With the Importer
Importing a Project
After Importing a Project
Build Your Project
Check for Common Conversion Issues
Resolve Undefined Symbols
Make Code Changes for GCC Compatibility
Conform to the C99 Standard
Inlining Thresholds
Dealing With Pragmas
Packing and Alignment Differences
Different size and alignment of enums
Different alignment of doubles
Code size incompatibility with power alignment
Data packed differently in a register
The Mach-O bool Type is Four Bytes, Not One
Guarding Header Includes for C++
Friend of Template Specialization Can’t Access Private Members
Float to Integer Conversions Give Incorrect Output
Some Casts Don’t Work in Function Lists
Standard C Library Functions Are in Global Namespace
Vector Load Indexed Intrinsic Is Not Const Correct
CodeWarrior Allows Anonymous Unused C Function Arguments
GCC Interprets Some #define Values Differently Than CodeWarrior
GCC asm Intrinsics are Preprocessor Macros
Xcode’s Rez tool Doesn’t Support Certain Operators
Move Settings From the .plc File to an Info.plist File
Make Changes to PowerPlant
Add PowerPlant Headers to the Project and Target
Create a Prefix File for PowerPlant
Make Minor Changes to the PowerPlant Code
Changes for a Debug Build
Using PowerPlant in Universal Binaries
Changing LStream Code
LStream.h
LStream.cp
LControl.cp
LListBox.cp
LPane.cp
LPrintout.cp
LScroller.cp
LTable.cp
LView.cp
LWindow.cp
LPopupGroupBox.cp
LControlView.cp
LScrollerView.cp
LPageController.cp
Flipping the 'DBC#’ Resource Type
Where to Go From Here
After Moving Your Project to Xcode
Revision History