koecher/candi-origin

optional packages

Closed this issue · 1 comments

tjhei commented

I would like to discuss how would one go about optional packages. I found the somewhat hidden command to do ./candi.sh install-package pkgname which works nicely, but I can a) not detect if a package is installed when installing another package and b) package_specific_register() won't be executed.

My suggestion would be to

  • change package_specific_register() to echo what they want to export/do
  • pipe that into a file that we can source during installation (so dealII will see "export TRILINOS_DIR=")
  • also pipe something like export CANDI_PKGS="$PKG $CANDI_PKGS" into the file
  • the cool thing about this is that this will generate an environment that the user can source to setup his environment (export DEAL_II_DIR etc). This means you can also build deal.II anywhere by yourself if you need to (I have plenty of them around).

Thoughts?

The functionality of compiling a single package comes from the origins, which was dorsal.
I do not have tested this, since I'm always interessted in compiling a complete and fitting toolchain.
Your approach sounds very useful, if you want to install your specific working tools.