Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please don't include GCC version in installed file paths #51

Closed
yurivict opened this issue Jan 18, 2022 · 2 comments · Fixed by #52
Closed

Please don't include GCC version in installed file paths #51

yurivict opened this issue Jan 18, 2022 · 2 comments · Fixed by #52

Comments

@yurivict
Copy link

yurivict commented Jan 18, 2022

This and many your other projects include strings like GNU-10.3.0:

$ find /usr/local/include/ -name GNU-10.3.0
/usr/local/include/mctc-lib/GNU-10.3.0
/usr/local/include/mstore/GNU-10.3.0
/usr/local/include/multicharge/GNU-10.3.0
/usr/local/include/toml-f/GNU-10.3.0
/usr/local/include/tblite/GNU-10.3.0
/usr/local/include/s-dftd3/GNU-10.3.0
/usr/local/include/dftd4/GNU-10.3.0

This causes ports/packages to break when gcc version is changed because plist would change and ports would need to be updated.

@awvwgk
Copy link
Member

awvwgk commented Jan 18, 2022

Since Fortran compiler are not necessarily ABI compatible this is the wanted behavior.

However, it is notable that the GFortran ABI has been stable now since version 9, meaning this could be reconsidered now. I'm unsure whether there is a reliable way to extract the version of the module files at configure time to use this for tagging rather than the compiler version number which might be too tightly pinned.

@awvwgk
Copy link
Member

awvwgk commented Jan 18, 2022

The module directory is set always in config/CMakeLists.txt:

set(
module-dir
"${PROJECT_NAME}/${CMAKE_Fortran_COMPILER_ID}-${CMAKE_Fortran_COMPILER_VERSION}"
)
set(module-dir "${module-dir}" PARENT_SCOPE)

feel free to patch the generation of the module directory string if this is an actual problem. I could also offer in the future to allow overwriting a cached variable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants