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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support building with gz-cmake3 or gz-cmake4 #128

Merged
merged 1 commit into from
Oct 13, 2023
Merged
Changes from all commits
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
13 changes: 11 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,17 @@ project(gz-tools2 VERSION 2.0.0)
#============================================================================
# Find gz-cmake
#============================================================================
find_package(gz-cmake3 REQUIRED)
set(GZ_CMAKE_VER ${gz-cmake3_VERSION_MAJOR})
find_package(gz-cmake3 QUIET)
if (${gz-cmake3_FOUND})
set(GZ_CMAKE_VER ${gz-cmake3_VERSION_MAJOR})
else()
find_package(gz-cmake4 QUIET)
if (${gz-cmake4_FOUND})
set(GZ_CMAKE_VER ${gz-cmake4_VERSION_MAJOR})
else()
message(FATAL_ERROR "Could not find either gz-cmake3 or gz-cmake4")
endif()
endif()

#============================================================================
# Configure the project
Expand Down
Loading