forked from AcademySoftwareFoundation/MaterialX
-
Notifications
You must be signed in to change notification settings - Fork 23
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
MATX-344 : Ensure CMake config relocatability #1350
Merged
JGamache-autodesk
merged 2 commits into
adsk_contrib/dev
from
t_gamaj/MATX-344/ensure_relocatable_cmake_generation
Jan 4, 2022
Merged
MATX-344 : Ensure CMake config relocatability #1350
JGamache-autodesk
merged 2 commits into
adsk_contrib/dev
from
t_gamaj/MATX-344/ensure_relocatable_cmake_generation
Jan 4, 2022
Conversation
This file contains 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
All install paths *must* be relative for CMake to generate a relocatable config file. This means removing all those CMAKE_INSTALL_PREFIX path components that point to an absolute path. For an install in `/dev/MaterialX/staging` The difference will be in the generated file: `/dev/MaterialX/staging/lib/cmake/MaterialX/MaterialXTargets.cmake` Where, without this fix, you will find: ``` set(_IMPORT_PREFIX "/dev/MaterialX/staging") ``` and, with the fix, the results will be: ``` get_filename_component(_IMPORT_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH) get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH) get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH) get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH) if(_IMPORT_PREFIX STREQUAL "/") set(_IMPORT_PREFIX "") endif() ``` which makes the install area packageable and relocatable.
kwokcb
changed the title
Ensure CMake config relocatability
MATX-344 : Ensure CMake config relocatability
Jan 4, 2022
Is this correct in understanding the change:
|
kwokcb
approved these changes
Jan 4, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. But want to check my understanding.
@kwokcb you are correct on all 3 points. Setting the default location in CMake is done by adding
to the command line, so basically the same variable name. |
JGamache-autodesk
deleted the
t_gamaj/MATX-344/ensure_relocatable_cmake_generation
branch
January 4, 2022 21:13
This was referenced Jan 7, 2022
jstone-lucasfilm
pushed a commit
that referenced
this pull request
Jul 11, 2023
Fixes triplanar node's blending, so the corner's are not bright. Also adds a blend control for users to adjust the blending between maps. The default blend value of 1.0 matches the original behavior (apart from the brightness bug).
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.
All install paths must be relative for CMake to generate a relocatable
config file. This means removing all those CMAKE_INSTALL_PREFIX
path components that point to an absolute path.
For an install in
/dev/MaterialX/staging
The difference will be in the generated file:
/dev/MaterialX/staging/lib/cmake/MaterialX/MaterialXTargets.cmake
Where, without this fix, you will find:
and, with the fix, the results will be:
which makes the install area packageable and relocatable.