Managing dependencies on other package is a major problem when configuring a build. Currently boost.build is designed to work this way: you request the build you want of the dependent component, and it causes a compatible build of the dependency to be generated if neccessary. Let's call this the devleoper mode.
But this only works if you have write access to the dependencies. If this isn't the case, you must take the dependencies as they are. Then, the dependencies should force a compatible build of the dependent, or at least stop an incompatible build with an error message. I'll call this the user mode.
We can support the user mode if every installed library is accompanied by a Jam file that reports the build properties of that library. By including the Jam report file in the dependent's Jamfile, it can be used to adjust target properties or error check the build.
Let me give an example: Suppose I want to create project 'foo' which depends on projects 'boost' and 'vigra', where 'vigra' itself depends on 'boost' as well. For each installed boost variant, there will be a Jamreport, e.g.
# contains the build properties for our solaris installation of boost 1.25.0 /software/boost-1.25.0/solaris-2.6/Jamreport
# contains the build properties for our linux installation of boost 1.25.0 /software/boost-1.25.0/linux-2.1/Jamreport
Likewise for vigra. Then foo's Jamfile might begin with (I'm making up some syntax):
dependency boost : /software/boost-1.25.0/$platform/Jamreport dependency vigra : /software/vigra-1.1.3/$platform/Jamreport
These lines would import the build properties for these packages, and also check for conflicts (e.g. they would signal a dependency error/warning if vigra-1.1.3 was build using boost-1.20.0). In build rules, one could use something like:
foo.o : cppincludes += [ get cppincludes boost ] bar.o : cppincludes += [ get cppincludes vigra ]
to add the neccessary include paths to the compiler command line. Since vigra itself depends on boost, [ get cppincludes vigra ] would actually add the transitive closure of vigra's include requirements. Similarly for libraries and their paths.
The file /software/boost-1.25.0/$platform/Jamreport is automatically created by Jam when that particular build variant of boost is created and installed, and it contains all relavant information about the build. Besides its primary use for controling/constraining/checking the build of dependent software, there are secondary uses:
An installation build differs from a development build in these respects:
If Jam could support this in an easy-to-use fashion, it would be great.
[buy lipitor online] [buy lipitor] [[buy lipitor online]]
[buy fioricet online] [buy fioricet] [[buy fioricet online]]