|Message: CMAKE_INSTALL_LIBDIR & proper way for side-by-side installation of multiple Geant4 versions||Not Logged In (login)|
Click on the Forum title, e.g. on the "Forums by Category" page, to read a sequence of postings to the Forum and its threads all in one page. If you are only interested in one thread or the thread following a specific posting, click the thread or the posting, which takes you to a smaller page, which contains only the part you are interested in and may be easier to navigate.
Messages are "chained" if there are only replies at the first level, i.e. 1/1.html, 1/1/1.html etc. In case of "chained" messages the message number is replaced by the icon and there is no indentation.
Inline: Display the subject line only or also the text of the posting(s); for the choice "All" the "Outline" choices are switched off.
|1||0||1||no text / full text of posting|
|2||1||All||text for level 1 only / text for All postings|
Outline: Choose the depth of the posting thread, successive toggle controls provide increasing detail.
|1||2||1||2 levels / 1 level (original posting)|
|2||3||2||3 levels / 2 levels|
|3||3||All||3 levels / all levels (all postings)|
I would like to support side-by-side installation of multiple Geant4 versions in MacPorts on Mac OS X (I'm writing a new package), to allow simultaneous installation of, say, Geant4 9.5.p02, Geant4 9.6.p02 and Geant4 10.0.b01.
I need to change CMAKE_INSTALL_LIBDIR, for example to CMAKE_INSTALL_LIBDIR=lib/Geant4/Geant4.9.6, else the files like libG4run.dylib from different versions would clash with each other.
But that creates another "problem". Changing this option also puts the cmake modules to a weird location: they end up in $prefix/lib/Geant4/Geant4.9.6/Geant4-9.6.2/*.cmake when they should actually go to $prefix/lib/Geant4-9.6.2/*.cmake.
Less important, but related:
I would also like to use $prefix/include/Geant4/Geant4.9.6 for included files (CMAKE_INSTALL_INCLUDEDIR=include/Geant4/Geant4.9.6), but Geant4 would automatically add Geant4 to the end, so I end up with $prefix/include/Geant4/Geant4.9.6/Geant4/include/G4Something.hh.
DATAROOTDIR is also automatically suffixed with Geant4-9.6.2 (I don't know if there is any way to control that).
Related, more important, but a completely different issue:
I also had to set CMAKE_INSTALL_BINDIR=libexec/Geant4/Geant4.9.6 to be able to avoid clashes, but since all the paths in geant4-config for example are written in a relative way, I cannot simply make a symlink like
ln -s $prefix/libexec/Geant4/Geant4.9.6/geant-config $prefix/bin/
Of course I can patch geant-config, but it would be a lot better to have some option to hardcode paths automatically. The installation (even though default one, with some path changes) is not really rellocatable anyway. If nothing else, all the libraries are linked in an absolute way. I'm not sure how that is on Linux, but on Mac I get the following:
> otool -L /opt/local/lib/Geant4/Geant4.9.6/libG4run.dylib /opt/local/lib/Geant4/Geant4.9.6/libG4run.dylib: /opt/local/lib/Geant4/Geant4.9.6/libG4run.dylib (compatibility version 0.0.0, current version 0.0.0) /opt/local/lib/Geant4/Geant4.9.6/libG4digits_hits.dylib (compatibility version 0.0.0, current version 0.0.0) ... /opt/local/lib/libexpat.1.dylib (compatibility version 8.0.0, current version 8.0.0) /opt/local/lib/libCLHEP-188.8.131.52.dylib (compatibility version 0.0.0, current version 0.0.0) /usr/lib/libstdc++.6.dylib (compatibility version 7.0.0, current version 52.0.0) /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 159.1.0)
with hardcoded absolute paths. Therefore the libraries would stop working if I would move them around.
I would be grateful for any hints about how to best approach this.
Thank you, Mojca
|Inline Depth:||Outline Depth:||Add message:|