world leader in high performance signal processing
Trace: » preparations

One-time Preparations

The preparations explained here are necessary with respect to code management. For doing most of the steps described below, a project should be defined already, since associated settings are stored in project data.

Configuring the C-indexer

For full utilization of the indexer, i.e. the mechanism that allows for quick cross-file referencing to symbol, variable and function definitions, one must tell Eclipse which include paths are used with the normal make process. This is invaluable when you're going to modify existing application or kernel code. However, error free indexing seems not possible due to macro constructs used in Linux (e.g. macros like param_check_##type(..), which expands to macro names in compile time). In order to obtain best results, you may try to set up the indexer in Full Indexing mode (Fast Indexing is default).

Typical configuration for handling kernel code is shown by the screenshots below (resp. paths and predefined symbols). The paths and symbols are gathered using the kernel's makefile. The entries shown are examples and not necessarily OK for all cases. These dialogs are entered via Project→Properties, or right click in the Navigator view.

Note that these values are automatically inserted in the tool settings dialog (or reversed when the entries are done here) when automatic build is configured, see just below:

This dialog is limited to the two most right tabs, when a makefile is used for building the code.
When application code is programmed, automatic build may be preferred. The full toolchain paths must then be specified in the Tool Setting dialog, or these must be specified in the ~/.bashrc file. Also, the export CROSS_COMPILE=bfin-uclinux- must be active.


Eclipse provides a graphical CVS interface allowing projects checked out from CVS to easily be integrated with Eclipse. If you have installed the Subclipse plugins, SVN version control is present, too. Since this is currenly being utilized with the Blackfin repositories, only SVN is described here.

As a first step, the repositories should be specified. Do File→New→Other… and then select the SVN (Checkout Projects from SVN) entry in the dialog that pops up now. This is the resulting dialog:

As an aid, the two main paths are shown as already configured. To get it right there, The “Create …” choice must be checked first. In subsequent steps, one is entering a wizard which allows to create a new C-project as shown above, complete with import of selected tree nodes of the repository.

Alternatively, it is also possible to manage (and here also delete) SVN configuration in the SVN perspective. At first start this must be opened through Window→Open Perspective→SVN Repository Exploring. You should now see the SVN Repositories view on the workbench.

Defining an SVN entry is very simple and straightforward. Just after definition, Eclipse will attempt to connect to the SVN repository. If the connection is successful you may then proceed to checkout modules, during an import process or a simple update process, see sample dialog:

To checkout a module, expand the repository in the SVN Repositories view then expand the head of the repository; all of the modules in repository should now be listed. Select the module you wish to checkout and right click anywhere in the CVS Repositories view, select Check Out from the menu that appears.

If you have performed any changes you can commit the module to the SVN repository by selecting the project, right clicking in the Navigator view and selecting Team→Commit, provided that you have write access rights. If you have added files to the project a dialog will appear asking you if you wish to add the resources to the module. Next, a dialog will appear where you can enter a comment, when you are finished click OK. The module in the SVN repository should now be updated.

Some other useful features of the Eclipse SVN client are summarized below:

To add a new module to the SVN repository select an existing project in the Navigator view. Right click in the view and select Team→Share Project. The share project dialog should be displayed. This dialog will ask you which SVN repository you wish to submit the module to, it will also ask what name you would like to use for the module. After completing the required information Eclipse will submit your project to the SVN repository as a new module. If there are resources in the project Eclipse will ask if you wish to add these resources to the repository.

To compare the local version of a resource with a version in the SVN repository select the local resource in the Navigator view, right click within the view and select an option from the Compare With menu.

To view the revision history of a SVN resource select the resource in the SVN Repositories view, right click within the view and select Show in Resource History, this will display the SVN Resource History view. This view provides a list of all the revisions of the resource. Double clicking on a particular revision will display the contents of that revision in an editor window.

To replace the local version of a resource with a version from the SVN repository select the local resource in the Navigator view, right click within the view and select an option from the Replace With menu.

To remove a file from a SVN repository simply delete the file from the project then commit the project by selecting it in the Navigator view, right clicking in the view and choosing Team→Commit.

To refresh the list of resources in a SVN repository select the repository in the SVN Repositories view, right click in the view and choose Refresh View.