Skip to content

Commit 01cbf60

Browse files
committed
Make SISL a dependency of base/orogen/types
1 parent d2da516 commit 01cbf60

File tree

4 files changed

+19
-26
lines changed

4 files changed

+19
-26
lines changed

CMakeLists.txt

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,17 @@ include_directories(${BOOST_INCLUDE_DIR})
1515
pkg_check_modules(EIGEN3 REQUIRED "eigen3")
1616
include_directories(${EIGEN3_INCLUDE_DIRS})
1717

18-
find_package(SISL)
19-
if (SISL_FOUND)
20-
pkg_check_modules(BASELIB REQUIRED "base-lib")
21-
include_directories(${BASELIB_INCLUDE_DIRS})
22-
include_directories(${SISL_INCLUDE_DIRS})
23-
list(APPEND TOOLKIT_ADDITIONAL_SOURCES ${CMAKE_SOURCE_DIR}/src/spline.cpp)
24-
list(APPEND TOOLKIT_ADDITIONAL_LIBRARIES ${BASELIB_LIBRARIES} ${SISL_LIBRARIES})
18+
pkg_check_modules(BASE_TYPES_SISL "base-types-sisl")
19+
if(NOT BASE_TYPES_SISL_FOUND)
20+
message(FATAL_ERROR "The dependency base/types has been built"
21+
" without SISL support."
22+
" It seems that you have intentially disabled the use of SISL in"
23+
" base/types. While disabling SISL support might be useful"
24+
" for an isolated reuse of base/types, base/orogen/types or more"
25+
" generally the framework Rock strictly requires"
26+
" SISL support in base/types.")
2527
endif()
28+
list(APPEND TOOLKIT_ADDITIONAL_SOURCES ${CMAKE_SOURCE_DIR}/src/spline.cpp)
2629

2730
INCLUDE(baseBase)
2831

base.orogen

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -29,20 +29,13 @@ import_types_from "base/JointState.hpp"
2929
import_types_from "base/JointLimits.hpp"
3030
import_types_from "base/JointTransform.hpp"
3131
import_types_from "base/JointsTrajectory.hpp"
32-
33-
if has_library?('base-lib')
34-
using_library 'base-lib'
35-
# Opaque wrappers for Spline types
36-
import_types_from 'base/wrappers/geometry/Spline.hpp'
37-
end
32+
import_types_from 'base/wrappers/geometry/Spline.hpp'
3833

3934
# Opaque wrappers for Eigen types
4035
import_types_from "base/wrappers/Eigen.hpp"
4136

42-
if has_library?('base-lib')
43-
typekit.opaque_type '/base/geometry/Spline<3>', '/wrappers/geometry/Spline'
44-
typekit.opaque_type '/base/geometry/Spline<1>', '/wrappers/geometry/Spline'
45-
end
37+
typekit.opaque_type '/base/geometry/Spline<3>', '/wrappers/geometry/Spline'
38+
typekit.opaque_type '/base/geometry/Spline<1>', '/wrappers/geometry/Spline'
4639
typekit.opaque_type '/base/Vector2d', 'wrappers/Vector2d'
4740
typekit.opaque_type '/base/Vector3d', 'wrappers/Vector3d'
4841
typekit.opaque_type '/base/Vector4d', 'wrappers/Vector4d'
@@ -56,9 +49,8 @@ typekit.opaque_type '/base/Matrix6d', 'wrappers/Matrix6d'
5649
typekit.opaque_type '/base/MatrixXd', 'wrappers/MatrixXd'
5750
typekit.opaque_type '/base/VectorXd', 'wrappers/VectorXd'
5851
typekit.opaque_type '/base/Affine3d', 'wrappers/Matrix4d'
59-
if has_library?('base-lib')
60-
import_types_from "base/geometry/Spline.hpp"
61-
end
52+
53+
import_types_from "base/geometry/Spline.hpp"
6254
import_types_from "base/TwistWithCovariance.hpp"
6355
import_types_from "base/TransformWithCovariance.hpp"
6456
import_types_from "base/Pose.hpp"

manifest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
</copyright>
1313
<license>GPL v2 or later</license>
1414
<depend package="base/types"/>
15+
<depend package="external/sisl" />
1516
<depend package="base/orogen/std"/>
1617
<depend package="orogen"/>
1718
<depend package="rtt"/>

test/CMakeLists.txt

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
pkg_check_modules(BASE REQUIRED "base-lib")
1+
pkg_check_modules(BASE REQUIRED "base-types-sisl")
22
include_directories(${BASE_INCLUDE_DIRS})
33
link_directories(${BASE_LIBRARY_DIRS})
44

@@ -10,10 +10,7 @@ include_directories(${STD_INCLUDE_DIRS})
1010

1111
add_definitions("-DOROCOS_TARGET=${OROCOS_TARGET}")
1212

13-
if (SISL_LIBRARIES)
14-
set(ADDITIONAL_TESTS test_nurbs.cpp)
15-
endif()
16-
add_executable(base_orogen_types_test test.cpp test_matrixx.cpp
17-
${ADDITIONAL_TESTS} ${TOOLKIT_ADDITIONAL_SOURCES} ../typekit/Opaques.cpp)
13+
add_executable(base_orogen_types_test test.cpp test_matrixx.cpp test_nurbs.cpp
14+
${TOOLKIT_ADDITIONAL_SOURCES} ../typekit/Opaques.cpp)
1815
target_link_libraries(base_orogen_types_test ${Boost_SYSTEM_LIBRARIES} ${Boost_UNIT_TEST_FRAMEWORK_LIBRARIES} ${BASE_LIBRARIES})
1916

0 commit comments

Comments
 (0)