doc/guide/src/customization.page in autoproj-1.2.0 vs doc/guide/src/customization.page in autoproj-1.2.1
- old
+ new
@@ -41,10 +41,22 @@
- utilmm
- utilrb
- orocos/
{coderay}
+Configuration files like <tt>autoproj/manifest</tt> are YAML file. As such, they
+aresensible to indentation. The snippet above should be read as: in the layout, there is first a "lib" part and second the packages whose names start with "orocos/" _(first level of indentation)_. In the "lib" part, the packages are "typelib", "utilmm"
+ and "utilrb" _(second level of indentation)_.
+{.warning}
+
+Alternatively, the example above could be written:
+{coderay:: yaml}
+layout:
+ - lib: [typelib, utilmm, utilrb]
+ - orocos/
+{coderay}
+
Finally, names of sublayouts can be used as arguments in the autoproj command
line, instead of package names:
autoproj build lib
{.commandline}
@@ -109,11 +121,11 @@
You can list local packages that are not in an imported package set by placing
the definitions in autoproj/, in a file ending with <tt>.autobuild</tt>. See [this
page](source_yml.html) for information on how to write autobuild files.
-Setting up the path to specific commands (make, parallel_builds)
+Setting up the path to specific commands (make, parallel builds)
----------------------------------------------------------------
The autobuild API allows to specify what specific installed command to use for
each tool needed during the build. These commands can be used in
<tt>autoproj/init.rb</tt> to tune the build system. Example:
@@ -129,9 +141,24 @@
More complex customization can be achieved by accessing the Autoproj and
Autobuild API directly in the <tt>autoproj/init.rb</tt> and
<tt>autoproj/overrides.rb</tt>
files. The former is loaded before all source files and the latter is loaded
after all source files.
+
+Some examples:
+
+ * fixing dependencies: if a dependency is not listed in a package's manifest,
+ then you can fix it by adding the following in <tt>autoproj/overrides.rb</tt>
+ {coderay:: ruby}
+ a = Autobuild::Package['a_package']
+ a.depends_on "other_package"
+ {coderay}
+
+ * changing the configuration of some cmake package:
+ {coderay:: ruby}
+ a = Autobuild::Package['a_package']
+ a.define "CONFIG_VAR", "CONFIG_VALUE"
+ {coderay}
Building packages selectively on the command line
-------------------------------------------------
The autoproj command line accepts subdirectories defined in the layout as well