diff --git a/sci-libs/dart/dart-6.10.1-r2.ebuild b/sci-libs/dart/dart-6.10.1-r2.ebuild
index a0947f03b2..d475a1738d 100644
--- a/sci-libs/dart/dart-6.10.1-r2.ebuild
+++ b/sci-libs/dart/dart-6.10.1-r2.ebuild
@@ -14,10 +14,12 @@ SRC_URI="https://github.com/dartsim/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~amd64"
-IUSE="bullet doc examples extras glut +ipopt +nlopt ode openscenegraph python test tutorials urdfdom"
+IUSE="bullet doc examples extras glut +ipopt +nlopt ode openscenegraph python test tests tutorials urdfdom"
#TODO: pagmo
+#TODO: unbundle imgui
RESTRICT="!test? ( test )"
+PATCHES=( "${FILESDIR}/${PN}-respect-ldflags.patch" )
REQUIRED_USE="
python? ( ${PYTHON_REQUIRED_USE} )
@@ -28,7 +30,6 @@ RDEPEND="
app-arch/lz4
>=dev-cpp/eigen-3.0.5
dev-libs/boost
- dev-libs/tinyxml
dev-libs/tinyxml2
>=sci-libs/libccd-2.0
>=media-libs/assimp-3.0.0
@@ -76,10 +77,10 @@ src_configure() {
src_compile() {
cmake_src_compile
- use examples && cmake_src_compile examples
-# use python && cmake_src_compile dartpy
-# use test && cmake_src_compile tests
-# use tutorials && cmake_src_compile tutorials
+ use examples && cmake_build examples
+ use python && cmake_build dartpy # no work to do ...
+ use test && cmake_build tests
+ use tutorials && cmake_build tutorials
}
src_install() {
diff --git a/sci-libs/dart/files/dart-respect-ldflags.patch b/sci-libs/dart/files/dart-respect-ldflags.patch
new file mode 100644
index 0000000000..0fa4397cda
--- /dev/null
+++ b/sci-libs/dart/files/dart-respect-ldflags.patch
@@ -0,0 +1,11 @@
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -220,7 +220,7 @@
+ endif()
+ set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELEASE} ${CMAKE_CXX_FLAGS_DEBUG}")
+ set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAGS_DEBUG} -pg")
+- set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--no-undefined")
++ set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined")
+
+ # Enforce to colorize compilation output
+ if(${DART_FORCE_COLORED_OUTPUT})
diff --git a/sci-libs/dart/metadata.xml b/sci-libs/dart/metadata.xml
index 98e5267443..486eef0826 100644
--- a/sci-libs/dart/metadata.xml
+++ b/sci-libs/dart/metadata.xml
@@ -17,6 +17,7 @@
NLopt Optimization Support
ODE Collision Detector Support
OpenSceneGraph GUI and examples
+ Build the tests
Build the tutorials
URDF parser