Hi James, Thanks for your reply, and from Mathius and Alan...
> Does that help at all? Well, there is no doubt I could 'simplify' the situation by NOT appending an extra path items after 'install', but I should not have to! If I wanted such a 'simple' single install path, why not install those items to /usr/include or /usr/local/include, and /usr/lib or /usr/local/lib... and be done with it! But this implies you are ONLY going to have say ONE version of say OSG, or simgear installed, always building against it... 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 ;=)) And I also like your idea of building OUTSIDE the source tree... Will also get around to giving that a try... As to adding CMAKE_VERBOSE_MAKEFILE, I certainly like to see exactly WHAT is being passed to gcc, so will always keep this... And I know in the 'Release' build the LIB_POSTFIX is not required, since it already defaults to 'nothing', but should do no harm to add it... But the idea from Alan, in Windows, which I think is sort of 'cheating' ;=)) and that is to add a -D SIMGEAR_VERSION_OK=TRUE got me through the cmake configure step, but with some VERY ominous warnings from cmake, which does not look good for the final links - ... -- Configuring done WARNING: Target "fgfs" requests linking to directory "/home/geoff/fg/fg16/install/simgear/lib". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "metar" requests linking to directory "/home/geoff/fg/fg16/install/simgear/lib". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "fgviewer" requests linking to directory "/home/geoff/fg/fg16/install/simgear/lib". Targets may link only to libraries. CMake is dropping the item. -- Generating done ... But ignoring those, the build still FAILED on the first compile for another reason - [ 0%] Building CXX object src/Airports/CMakeFiles/fgAirports.dir/apt_loader.cxx.o cd /home/geoff/fg/fg16/fgfs/source/src/Airports && /usr/bin/c++ \ -DHAVE_CONFIG_H -O3 -Wall -D_REENTRANT -O3 -DNDEBUG \ -I/home/geoff/fg/fg16/install/OSG301/include -I/usr/include/AL \ -I/home/geoff/fg/fg16/install/simgear/include/simgear \ -I/home/geoff/fg/fg16/fgfs/source/src \ -I/home/geoff/fg/fg16/fgfs/source/src/Include \ -I/home/geoff/fg/fg16/fgfs/source \ -o CMakeFiles/fgAirports.dir/apt_loader.cxx.o -c \ /home/geoff/fg/fg16/fgfs/source/src/Airports/apt_loader.cxx In file included from /home/geoff/fg/fg16/fgfs/source/src/Airports/apt_loader.cxx:29: /home/geoff/fg/fg16/fgfs/source/src/Airports/apt_loader.hxx:28:30: error: simgear/compiler.h: No such file or directory /home/geoff/fg/fg16/fgfs/source/src/Airports/apt_loader.cxx:37:31: error: simgear/constants.h: No such file or directory ... etc, etc, etc This shows cmake getting the simgear 'include' directory WRONG! It is adding 'simgear' to the end when it should NOT! -I/home/geoff/fg/fg16/install/simgear/include/simgear I think that should be just -I/home/geoff/fg/fg16/install/simgear/include Having HIT this cmake barrier, I reverted to venerable automake, and FG built without problems ;=)) I will continue testing with CMake in Ubuntu, and will also give it a try in Windows, and thanks for all the effort in this regard, but I certainly do not feel it is quite the right time to fully dismantle the automake system ;=() Simply, any new system adopted should - (a) work in ALL cases, and (b) offer the SAME flexibility in the location of dependent library versions... Of course I understand this may take some effort to work out the correct cmake commands, and am willing to continue to seek this, but it should be achievable ;=)) Any new, further ideas welcome... I will certainly give them a try... Regards, Geoff. On Sun, 2011-10-23 at 20:44 +0100, James Turner wrote: > On 23 Oct 2011, at 18:47, Geoff McLane wrote: > > > Sorry, what am I doing wrong? > > I'm not sure *exactly* what you're doing wrong, but in general I would say > you're over controlling things a little. > > I'm not clear why you are installing each component in a subdir of install - > that's making your life complicated. If you simply installed OSG to > > /home/geoff/fg/fg16/install > > (as CMAKE_INSTALL_PREFIX when configuring OSG) > > then assuming you have (from Git) > > /home/geoff/fg/fg16/flightgear > /home/geoff/fg/fg16/simgear > > you should simply need: > > cd /home/geoff/fg/fg16/ > mkdir fgbuild > mkdir sgbuild > > cd sgbuild > cmake ../simgear -D CMAKE_INSTALL_PREFIX=/home/geoff/fg/fg16/install -D > CMAKE_BUILD_TYPE=Release > make install > > cd ../fgbuild > cmake ../flightgear -D CMAKE_INSTALL_PREFIX=/home/geoff/fg/fg16/install > -D CMAKE_BUILD_TYPE=Release > make install > > Of course you can set CXXFLAGS or CMAKE_VERBOSE_MAKEFILE is you need, but I > would avoid setting OSG_DIR, SIMGEAR_DIR or SIMGEAR_LIBRARIES unless you need > something very special - just use a common destination prefix and everything > works out easily! (And there's no need for a LIB_POSTFIX, it defaults to > empty for Release builds) > > Does that help at all? > > 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