Skip to content

Commit

Permalink
[build] Require Assimp >= 5.2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
jslee02 committed Mar 22, 2024
1 parent 7a13a30 commit 03566fe
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 14 deletions.
6 changes: 3 additions & 3 deletions cmake/DARTFindDependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ if(ASSIMP_FOUND)
# Check for missing symbols in ASSIMP (see #451)
include(CheckCXXSourceCompiles)
set(CMAKE_REQUIRED_DEFINITIONS "")
if (NOT ASSIMP_VERSION VERSION_LESS 3.3.0 AND NOT MSVC)
set(CMAKE_REQUIRED_FLAGS "-std=c++11 -w")
else()
if (MSVC)
set(CMAKE_REQUIRED_FLAGS "-w")
else()
set(CMAKE_REQUIRED_FLAGS "-std=c++11 -w")
endif()
set(CMAKE_REQUIRED_INCLUDES ${ASSIMP_INCLUDE_DIRS})
set(CMAKE_REQUIRED_LIBRARIES ${ASSIMP_LIBRARIES})
Expand Down
12 changes: 1 addition & 11 deletions cmake/DARTFindassimp.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,7 @@
#
# This file is provided under the "BSD-style" License

find_package(assimp REQUIRED MODULE)

# Manually check version because the upstream version compatibility policy
# doesn't allow different major number while DART is compatible any version
# greater than or equal to 4.1.
set(DART_ASSIMP_VERSION 4.1)
if(ASSIMP_VERSION AND ASSIMP_VERSION VERSION_LESS ${DART_ASSIMP_VERSION})
message(SEND_ERROR "Found Assimp ${ASSIMP_VERSION}, but Assimp >= ${DART_ASSIMP_VERSION}
is required"
)
endif()
find_package(assimp 5.2.2 REQUIRED MODULE)

# Set target assimp if not set
if((ASSIMP_FOUND OR assimp_FOUND) AND NOT TARGET assimp)
Expand Down
2 changes: 2 additions & 0 deletions docs/readthedocs/developer_guide/build.rst
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,8 @@ Here's a summary of the dependencies required to build DART (WIP):
+============+==========+=========+==============+=======+
| CMake | Yes | Build | 3.22.1 | |
+------------+----------+---------+--------------+-------+
| Assimp | Yes | Runtime | 5.2.2 | |
+------------+----------+---------+--------------+-------+
| Eigen | Yes | Runtime | 3.4.0 | |
+------------+----------+---------+--------------+-------+

Expand Down

0 comments on commit 03566fe

Please sign in to comment.