This appendix contains a description of the makefiles and other scripts used to build the tutorial. The main premise behind the build system is automation of as many steps in the port and component build processes as possible.
![]() |
Note |
|---|---|
|
While the tutorial build system is generally reusable for simple component projects, it is not intended for "black-box" use with arbitrary component applications. Please email tutorial-wg@cca-forum.org with any questions regarding the reuse of the tutorial build system in existing and new component applications. |
The tutorial build system relies on a strictly-defined directory structures,
in which the various files associated with the port and component definitions
and implementations reside. SIDL definitions for all ports reside in
ports/sidl directory; similarly the
SIDL definitions of all components should be placed in the components/sidl directory.
The following files are used during the build and can be modified to customize the build process. The paths are relative to the top-level tutorial source code directory. Files which are expected to be modified by the user are shown with italisized names. Modifying the rest of the files could be more error-prone and is not recommended.
components/MakeIncl.components is
the makefile segment that contains a list of the fully-qualified SIDL class
names for all components, with a suffix encoding the language of the
implementation. If SIDL definitions for new components are added to or
removed from the components/sidl
directory or a different implementation language for a certain
component is chosen, the
components/MakeIncl.components file
must be updated accordingly.
MakeIncl.user.in
is the file from which configure generates
MakeIncl.user. This file contains some high-level user
options, such as an optional installation prefix and the list of languages
for which to generate client libraries. While both of these files can be
modified by hand, it is better practice to use configure with the appropriate
options to generate the desired settings. For example, it is better to run
configure with the --with-languages option than to
modify the value of the USER_LANGUAGES variable directly.
ports/MakeIncl_template.user and
components/MakeIncl_template.user
are simple makefile segments that allow user-specified values to be prepended
to the INCLUDES and LIBS variables,
used for compilation and linking, respectively. Modifying
the top-level template files must be done before the
Babel-generated code has been built for the first time. In that case, the
build system will put copies of these files in each port and component source
subdirectories, and the local file will be used in the individual
port/component library builds. If the settings of those variables are not
uniform across all ports or components, individual
MakeIncl.user files can be modified
in their respective port/component source directories
after the first build attempt (e.g., invoking
make at the top level). It is usually a good idea to
use revision control for any user-modified portions of the build system in
addition to the files containing component
implementations.
Files that should not normally be modified:
Makefile contains targets for invoking
the build in all the tutorial subdirectories.
configure.in contains macros for
discovering or setting the location of the installed CCA tools, namely, the
ccafe-config script.
The utils/ directory
contains a number of utility shell scripts used by the build
systems. Modifying these is extremely dangerous and may easily break the
build.