Gate
Gate copied to clipboard
policy for the install directory
When running make install
in a Gate build directory, the following things get copied to the install directory:
- the (statically linked) Gate executable
- the MetaIO library (static)
- the MetaIO header files
Why do we install the MetaIO stuff? It's not even our own code, it's a copy of a directory in an old release of ITK. The static library is (by definition) not needed for running Gate. I don't think we want to encourage other developers to use our ITK copy (library and header files), they should use ITK directly.
On the other hand, I think it would be very useful to store the examples stuff (macros and input data) in the share
part of the installation directory (except if the user left GATE_DOWNLOAD_EXAMPLES_DATA
as OFF, then the user apparently does not want to install the examples). I usually treat the build directory as a temporary directory, which I delete after I'm done for the day with installing/developing/testing. All the interesting long term useful stuff should go into the install directory, and this includes the examples, in my opinion.
Another thing which I find myself doing all the time, is to create an gate_env.sh
script, which I copy into the $(CMAKE_INSTALL_PREFIX)/bin
directory. This file can be sourced and this then makes sure that my environment contains all the ROOT and Geant4 stuff that was used for this particular installation. Plus of course the bin directory is prepended to PATH. This is similar to the thisroot.sh
and geant4.sh
scripts that you get with ROOT and Geant4 (and of course my script uses those other scripts).
tl;dr: I want to change the install dir policy as follows:
- remove the MetaIO stoff
- add the examples (IFF the users enabled example data download)
- add a script for setting the environment of this particular Gate install
I dont think MetaIO stuff can be removed since ITK sources are not available as part of any distribution. So we must bundle it. The problem is what we bundle is an old copy of MetaIO and that can be updated.
These are two very different things: (1) Including (a copy of) MetaIO source code in the Gate source code (2) installing MetaIO as a compiled library & header files in the Gate install directories
Your comment is about (1), while this issue is about (2). Afer make install
, I can delete the build directory as well as the lib
and include
subdirectories from the install directory, and Gate
still runs. We need MetaIO
only to build Gate
, not to run it.
Maybe you guys never run make install
, do instead everything always in the build directory?
I agree with David, all 3 changes are good suggestions and I'd support a pull-request in this direction. Simon
On Mon, Jun 6, 2016 at 3:34 PM, David Boersma [email protected] wrote:
These are two very different things: (1) Including (a copy of) MetaIO source code in the Gate source code (2) installing MetaIO as a compiled library & header files in the Gate install directories
Your comment is about (1), while this issue is about (2). Afer make install, I can delete the build directory as well as the lib and include subdirectories from the install directory, and Gate still runs. We need MetaIO only to build Gate, not to run it.
Maybe you guys never run make install, do instead everything always in the build directory?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/OpenGATE/Gate/issues/75#issuecomment-223960179, or mute the thread https://github.com/notifications/unsubscribe/AAT_cHA5qe0ZRcmGWHV997Z2b4fT7b_Nks5qJCH9gaJpZM4Iu2m1 .
I am crazy busy right now, will try to work on this (and submit a pull request) in the first week of July.