1- cmake_minimum_required (VERSION 3.16 )
1+ cmake_minimum_required (VERSION 3.6 )
22project (mujoco_ros2_control)
33
44# Set default C standards
@@ -57,7 +57,7 @@ include(FetchContent)
5757FetchContent_Declare (
5858 mujoco
5959 GIT_REPOSITORY https://github.com/google-deepmind/mujoco.git
60- GIT_TAG 3.2.7 # MuJoCo version
60+ GIT_TAG 3.9.0 # MuJoCo version
6161)
6262
6363# Optionally set MuJoCo build options
@@ -66,6 +66,8 @@ set(MUJOCO_TEST_PYTHON_UTIL OFF CACHE BOOL "" FORCE)
6666set (BUILD_EXAMPLES OFF CACHE BOOL "" FORCE )
6767set (BUILD_SHARED_LIBS ON CACHE BOOL "" FORCE )
6868set (BUILD_SIMULATE ON CACHE BOOL "" FORCE )
69+ set (GLFW_BUILD_WAYLAND OFF CACHE BOOL "" FORCE )
70+ set (GLFW_BUILD_X11 OFF CACHE BOOL "" FORCE )
6971
7072FetchContent_MakeAvailable (mujoco)
7173
@@ -83,9 +85,6 @@ foreach(_dep_file ${_mujoco_dep_configs})
8385 file (WRITE "${_stub} " "# Auto-generated stub by mujoco_ros2_control workaround\n " )
8486 endif ()
8587endforeach ()
86- ## At the end this files will be filled with the correct data, so there is no problem with leaving them empty
87- # install(FILES "${CMAKE_BINARY_DIR}/ccd-config.cmake"
88- # DESTINATION share/${PROJECT_NAME}/cmake)
8988
9089# Add compile definitions and directories
9190add_definitions (
@@ -107,6 +106,7 @@ include_directories(
107106 ${pcl_conversions_INCLUDE_DIRS}
108107 ${CMAKE_BINARY_DIR } /_deps/mujoco-src/include
109108 ${CMAKE_BINARY_DIR } /_deps/mujoco-src/simulate
109+ ${CMAKE_BINARY_DIR } /_deps/lodepng-src
110110)
111111
112112# Generate parameter libraries
@@ -167,8 +167,8 @@ add_library(simulate_gui SHARED src/simulate_gui.cpp)
167167target_link_libraries (simulate_gui PUBLIC glfw )
168168target_link_libraries (simulate_gui PRIVATE
169169 mujoco::mujoco
170- mujoco::libsimulate
171170 mujoco::platform_ui_adapter
171+ lodepng
172172 glfw
173173)
174174
0 commit comments