geant4-data: symlink only specific data dirs - #47367
Merged
Merged
Conversation
Currently, the `geant4-data` spec creates symlink to all of its dependencies, and it does so by globbing their `share/` directories. This works very well for the way Spack installs these, but it doesn't work for anybody wanting to use e.g. the Geant4 data on CVMFS. See pull request spack#47298. This commit changes the way the `geant4-data` spec works. It no longer blindly globs directories and makes symlinks, but it asks its dependencies specifically for the name of their data directory. This should allow us to use Spack to use the CVMFS installations as externals.
drbenmorgan
approved these changes
Nov 4, 2024
drbenmorgan
left a comment
Member
There was a problem hiding this comment.
Very nice update @stephenswat! Works nicely locally with a mix of local installs and externals taken from CVMFS.
Member
|
@wdconinc, would appreciate a quick review/approval from you in case you spot anything! |
wdconinc
approved these changes
Nov 4, 2024
wdconinc
left a comment
Contributor
There was a problem hiding this comment.
I likely won't have time to test this similar to @drbenmorgan with a mixture of external sources. All looks great to me, though!
One (out of scope for this PR) idea would be to reduce the duplication a bit more by having geant4-data define a dataset base class that just defines the install and setup_dependent_run_environment once.
This was referenced Nov 25, 2024
fryeguy52
pushed a commit
to fryeguy52/spack
that referenced
this pull request
Dec 17, 2024
Currently, the `geant4-data` spec creates symlink to all of its dependencies, and it does so by globbing their `share/` directories. This works very well for the way Spack installs these, but it doesn't work for anybody wanting to use e.g. the Geant4 data on CVMFS. See pull request spack#47298. This commit changes the way the `geant4-data` spec works. It no longer blindly globs directories and makes symlinks, but it asks its dependencies specifically for the name of their data directory. This should allow us to use Spack to use the CVMFS installations as externals.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently, the
geant4-dataspec creates symlink to all of its dependencies, and it does so by globbing theirshare/directories. This works very well for the way Spack installs these, but it doesn't work for anybody wanting to use e.g. the Geant4 data on CVMFS. See pull request #47298. This commit changes the way thegeant4-dataspec works. It no longer blindly globs directories and makes symlinks, but it asks its dependencies specifically for the name of their data directory. This should allow us to use Spack to use the CVMFS installations as externals.