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

Disable CMake user registry lookup by find_package #1469

Open
jcfr opened this issue Dec 5, 2019 · 0 comments
Open

Disable CMake user registry lookup by find_package #1469

jcfr opened this issue Dec 5, 2019 · 0 comments
Labels

Comments

@jcfr
Copy link
Contributor

@jcfr jcfr commented Dec 5, 2019

Description

Configuring ITK on a system where unrelated build exported their build tree using export(PACKAGE) can have unintended side effect.

For example, on my system the package registry contains the following:

Steps to Reproduce

Configure ITK with ITK_USE_SYSTEM_EIGEN set to ON on a system where Eigen3 is found in the cmake registry:

ls -1 ~/.cmake/packages/
Eigen3

Expected behavior

Find Eigen3 installed with the package manager or fail if not available.

Actual behavior

CMakeCache.txt has the following value:

Eigen3_DIR:PATH=/home/jcfr/Projects/SlicerSALT-Release-Qt5/Slicer-build/E/Eigen3

Proposed solution

Set CMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY to 1

See https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#disabling-the-package-registry

Versions

Observed with d2e5114

Environment

Any

Additional Information

@jcfr jcfr added the type:Bug label Dec 5, 2019
jcfr added a commit to jcfr/ITK that referenced this issue Dec 5, 2019
jcfr added a commit to jcfr/ITK that referenced this issue Dec 6, 2019
See InsightSoftwareConsortium#1469

Suggested-by: Hans Johnson <hans-johnson@uiowa.edu>
jcfr added a commit to jcfr/ITK that referenced this issue Dec 6, 2019
See InsightSoftwareConsortium#1469

Suggested-by: Hans Johnson <hans-johnson@uiowa.edu>
jcfr added a commit to jcfr/ITK that referenced this issue Dec 6, 2019
See InsightSoftwareConsortium#1469

Suggested-by: Hans Johnson <hans-johnson@uiowa.edu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.