Skip to content

Commit

Permalink
Rename CMake project to gz
Browse files Browse the repository at this point in the history
Signed-off-by: Louise Poubel <louise@openrobotics.org>
  • Loading branch information
chapulina committed Jun 7, 2022
1 parent b250500 commit 231f63c
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 36 deletions.
4 changes: 2 additions & 2 deletions BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ licenses(["notice"])

exports_files(["LICENSE"])

PROJECT_NAME = "ignition-math"
PROJECT_NAME = "gz-math"

PROJECT_MAJOR = 7

Expand All @@ -30,7 +30,7 @@ ign_config_header(
name = "config",
src = "include/ignition/math/config.hh.in",
cmakelists = ["CMakeLists.txt"],
project_name = "ignition-math",
project_name = PROJECT_NAME,
project_version = (PROJECT_MAJOR, PROJECT_MINOR, PROJECT_PATCH),
)

Expand Down
16 changes: 8 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR)
#============================================================================
# Initialize the project
#============================================================================
project(ignition-math7 VERSION 7.0.0)
project(gz-math7 VERSION 7.0.0)

#============================================================================
# Find ignition-cmake
# Find gz-cmake
#============================================================================
# If you get an error at this line, you need to install ignition-cmake
find_package(ignition-cmake3 REQUIRED)
# If you get an error at this line, you need to install gz-cmake
find_package(gz-cmake3 REQUIRED)

#============================================================================
# Configure the project
Expand Down Expand Up @@ -41,9 +41,9 @@ option(USE_DIST_PACKAGES_FOR_PYTHON
#============================================================================

#--------------------------------------
# Find ignition-utils
ign_find_package(ignition-utils2 REQUIRED)
set(IGN_UTILS_VER ${ignition-utils2_VERSION_MAJOR})
# Find gz-utils
ign_find_package(gz-utils2 REQUIRED)
set(GZ_UTILS_VER ${gz-utils2_VERSION_MAJOR})

#--------------------------------------
# Find eigen3
Expand All @@ -69,7 +69,7 @@ if (SWIG_FOUND)
# Include ruby
find_package(Ruby 1.9 QUIET)
if (NOT RUBY_FOUND)
IGN_BUILD_WARNING("Ruby is missing: Install ruby-dev to enable ruby interface to ignition math.")
IGN_BUILD_WARNING("Ruby is missing: Install ruby-dev to enable ruby interfaces.")
message (STATUS "Searching for Ruby - not found.")
else()
message (STATUS "Searching for Ruby - found version ${RUBY_VERSION}.")
Expand Down
48 changes: 24 additions & 24 deletions examples/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,70 +1,70 @@
cmake_minimum_required(VERSION 3.5 FATAL_ERROR)

project(ignition-math-examples)
project(gz-math-examples)

# Find the Ignition-Math library
find_package(ignition-math7 REQUIRED)
set(IGN_MATH_VER ${ignition-math7_VERSION_MAJOR})
find_package(gz-math7 REQUIRED)
set(GZ_MATH_VER ${gz-math7_VERSION_MAJOR})

add_executable(additively_separable_scalar_field3_example additively_separable_scalar_field3_example.cc)
target_link_libraries(additively_separable_scalar_field3_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(additively_separable_scalar_field3_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(angle_example angle_example.cc)
target_link_libraries(angle_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(angle_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(color_example color_example.cc)
target_link_libraries(color_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(color_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(diff_drive_odometry diff_drive_odometry.cc)
target_link_libraries(diff_drive_odometry ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(diff_drive_odometry gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(gauss_markov_process gauss_markov_process_example.cc)
target_link_libraries(gauss_markov_process ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(gauss_markov_process gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(graph_example graph_example.cc)
target_link_libraries(graph_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(graph_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(helpers_example helpers_example.cc)
target_link_libraries(helpers_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(helpers_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(interval_example interval_example.cc)
target_link_libraries(interval_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(interval_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(kmeans kmeans.cc)
target_link_libraries(kmeans ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(kmeans gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(matrix3_example matrix3_example.cc)
target_link_libraries(matrix3_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(matrix3_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(piecewise_scalar_field3_example piecewise_scalar_field3_example.cc)
target_link_libraries(piecewise_scalar_field3_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(piecewise_scalar_field3_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(polynomial3_example polynomial3_example.cc)
target_link_libraries(polynomial3_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(polynomial3_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(pose3_example pose3_example.cc)
target_link_libraries(pose3_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(pose3_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(quaternion_example quaternion_example.cc)
target_link_libraries(quaternion_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(quaternion_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(quaternion_from_euler quaternion_from_euler.cc)
target_link_libraries(quaternion_from_euler ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(quaternion_from_euler gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(quaternion_to_euler quaternion_to_euler.cc)
target_link_libraries(quaternion_to_euler ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(quaternion_to_euler gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(rand_example rand_example.cc)
target_link_libraries(rand_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(rand_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(region3_example region3_example.cc)
target_link_libraries(region3_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(region3_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(temperature_example temperature_example.cc)
target_link_libraries(temperature_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(temperature_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(triangle_example triangle_example.cc)
target_link_libraries(triangle_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(triangle_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})

add_executable(vector2_example vector2_example.cc)
target_link_libraries(vector2_example ignition-math${IGN_MATH_VER}::ignition-math${IGN_MATH_VER})
target_link_libraries(vector2_example gz-math${GZ_MATH_VER}::gz-math${GZ_MATH_VER})
2 changes: 1 addition & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ign_create_core_library(SOURCES ${sources} CXX_STANDARD ${c++standard})

target_link_libraries(${PROJECT_LIBRARY_TARGET_NAME}
PUBLIC
ignition-utils${IGN_UTILS_VER}::ignition-utils${IGN_UTILS_VER}
gz-utils${GZ_UTILS_VER}::gz-utils${GZ_UTILS_VER}
)

# Build the unit tests
Expand Down
3 changes: 2 additions & 1 deletion src/ruby/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ if (RUBY_FOUND)

SWIG_LINK_LIBRARIES(${SWIG_RB_LIB}
${RUBY_LIBRARY}
ignition-math${PROJECT_VERSION_MAJOR}
gz-utils${GZ_UTILS_VER}::gz-utils${GZ_UTILS_VER}
gz-math${PROJECT_VERSION_MAJOR}
)
target_compile_features(${SWIG_RB_LIB} PUBLIC ${IGN_CXX_${c++standard}_FEATURES})

Expand Down

0 comments on commit 231f63c

Please sign in to comment.