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

Support IN_LIST operator in DARTConfig.cmake (6.9 backport) #1494

Merged
merged 2 commits into from
Aug 30, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions cmake/DARTFindBullet.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
find_package(Bullet COMPONENTS BulletMath BulletCollision MODULE QUIET)

if((BULLET_FOUND OR Bullet_FOUND) AND NOT TARGET Bullet)
cmake_policy(SET CMP0057 NEW)
Copy link
Member

@jslee02 jslee02 Aug 30, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error could occur anywhere IN_LIST is used. Also, this policy setting isn't necessary if the required CMake version is set from the parent project (e.g., gazebo). This policy setting isn't required if the required CMake version is set to 3.5.1 or greater. Let's fix this in DARTConfig.cmake.in like this one.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, I'll copy that approach here

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thanks!

if(WIN32 AND "optimized" IN_LIST BULLET_LIBRARIES
AND "debug" IN_LIST BULLET_LIBRARIES)
cmake_parse_arguments(BULLET_INTERFACE_LIBRARIES "" "" "debug;optimized"
Expand Down