On 24 Oct 2011, at 13:17, Geoff McLane wrote:

> 
> In my case I like to be able to compile 
> against different versions of say OSG - like -
> 
> OSG301=1        # stable release 3.0.1 - default
> OSG283=0        # general release 283 - option
> OSG299=0        # another development release
> OSGTRUNK=0      # option, for 'trunk' version
> 
> I have yet to try the idea from Mathius, using 
> a semi-colon set of paths, maybe replacing some 
> or all the 'export' items, like -
> -D "CMAKE_PREFIX_PATH=/path/to/osg;/path/to/simgear;..."
> - this seems a good idea to try... maybe cmake 
> will like it ;=))

Okay, *but*, for your own sanity, you need to keep the Simgear-built-against 
each of these separate too (anf FlightGear). By all means install each OSG 
somewhere special, but then you need to build FG and SG against the same 
version - so you may as well share a prefix for that build config (this is what 
Jenkins does to build trunk OSG vs stable)

Put it another way - you need to reconfigure and rebuild SG & FG entirely, when 
switching OSG version, so I don't see any problem with installing to the prefix 
for that OSG build too.

I'd do:
        mkdir osg-build-301
        cd osg-build-301
        cmake ../path/to/osg-301-source 
-DCMAKE_INSTALL_PREFIX=/path/to/install/dist-osg-301
        make install
        cd ..
        mkdir sg-build-with-osg-301
        cd sg-build-with-osg-301
        cmake ../path/to/simgear 
-DCMAKE_INSTALL_PREFIX=/path/to/install/dist-osg-301
        make install
        cd ..
        
... and repeat once more for FlightGear
        

Mathias' suggestion also works, BTW - specify CMAKE_PREFIX_PATH, with one (or 
several) paths to search - I tested that this morning and updated the README. 

As you guessed, manually setting the the detection variables 
(SIMGEAR_VERSION_OK, etc) is a bad idea, unless you set *all* the generated 
variables correctly - not impossible, but a lot of work. The error you report 
looks like it's happening because the detection script has got confused, but I 
need to see the arguments / environment passed to CMake, to understand why.

James


------------------------------------------------------------------------------
The demand for IT networking professionals continues to grow, and the
demand for specialized networking skills is growing even more rapidly.
Take a complimentary Learning@Cisco Self-Assessment and learn 
about Cisco certifications, training, and career opportunities. 
http://p.sf.net/sfu/cisco-dev2dev
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to