Adding new files

## Adding new files to the framework

Please follow these steps when adding new files to BioCocoa. This will make sure that whatever you add will be visible and usable in the Xcode project of the other developers, and minimize the Xcode-cvs issues that some of us are experiencing.

1. Add the files in the right location in Xcode, so they match the structure on your HD.
2. Add the new files to BCFoundation.h or BCAppKit.h under their appropriate header, reflecting the project's file structure.
3. Click on the BioCocoa target and make sure all headerfiles are labeled 'public' (except for BioCocoa_Prefix.h).
4. Header files in BCFoundation only need to add #import <Foundation/Foundation.h> and not #import <Cocoa/Cocoa.h>. Header files in BCAppKit need #import <AppKit/AppKit.h> and maybe #import <Foundation/Foundation.h>.
5. In public headers, check that you do not use relative paths in your #import statements. Example: use #import "BCSequence.h" and not #import "../BCSequence/BCSequence.h" if called from a file in another folder. The compiler will find the header even without the correct path.
6. Change "_MyCompanyName_" to "The BioCocoa Project".
7. Make sure the target compiles without errors and warnings.
8. Add and commit the files to the cvs repository, and don't forget to commit the changes to BCFoundation.h and project.pbxproj. You should be able to use cvs from within Xcode (see also the Xcode cvs setup documentation). However, using cvs from the command line has proven more reliable, at least in my hands ;-). If you use Xcode, never select BioCocoa at the top of the "Groups & Files" and then commit changes to cvs, this will wreak havoc. Always commit individual files. The best place to do this is within the SCM disclosure triangle in the "Groups & Files" pane. This is also the only place where you can commit changes in project.pbxproj from Xcode. If you use the command line, you will find project.pbxproj inside the BioCocoa.pbproj folder at the root level of the framework.

That should be it!

Back to index