From 7c9bdd475c6618600537ee2a37a03497ab34d357 Mon Sep 17 00:00:00 2001 From: JeongBong Seo Date: Fri, 5 Apr 2019 19:18:05 +0900 Subject: [PATCH] DRAFT fmi-adapter-0.1.3.inc: Fix external project build --- .../fmi-adapter-ros2/fmi-adapter-0.1.3.inc | 10 ++++++++ .../0001-Don-t-test-external-project.patch | 24 +++++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 includes-ros2/fmi-adapter-ros2/fmi-adapter-0.1.3.inc create mode 100644 includes-ros2/fmi-adapter-ros2/fmi-adapter/0001-Don-t-test-external-project.patch diff --git a/includes-ros2/fmi-adapter-ros2/fmi-adapter-0.1.3.inc b/includes-ros2/fmi-adapter-ros2/fmi-adapter-0.1.3.inc new file mode 100644 index 0000000..e5dc4e6 --- /dev/null +++ b/includes-ros2/fmi-adapter-ros2/fmi-adapter-0.1.3.inc @@ -0,0 +1,10 @@ +# Copyright (c) 2019 LG Electronics, Inc. + +# build external project first (It seems that dependency logic is weird.) +cmake_do_compile_prepend() { + cmake_runcmake_build --target FMILibraryProject +} + +# Don't test the external project because of we are in cross-compiling +FILESEXTRAPATHS_prepend := "${THISDIR}/fmi-adapter:" +SRC_URI += " file://0001-Don-t-test-external-project.patch" diff --git a/includes-ros2/fmi-adapter-ros2/fmi-adapter/0001-Don-t-test-external-project.patch b/includes-ros2/fmi-adapter-ros2/fmi-adapter/0001-Don-t-test-external-project.patch new file mode 100644 index 0000000..6783ca9 --- /dev/null +++ b/includes-ros2/fmi-adapter-ros2/fmi-adapter/0001-Don-t-test-external-project.patch @@ -0,0 +1,24 @@ +From 50966400c421e73866b24aef2f1ec5a160958013 Mon Sep 17 00:00:00 2001 +From: JeongBong Seo +Date: Fri, 5 Apr 2019 19:11:34 +0900 +Subject: Don't test external project + +--- + CMakeLists.txt | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 6ef34b5..ca673f0 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -12,6 +12,7 @@ externalproject_add(FMILibraryProject + URL https://jmodelica.org/fmil/FMILibrary-2.0.3-src.zip + URL_MD5 53d8edd7442c31bcd3fb56477e574845 + TIMEOUT 60 ++ CMAKE_ARGS -DFMILIB_BUILD_TESTS=OFF + ) + externalproject_get_property(FMILibraryProject INSTALL_DIR) + set(FMILibraryProject_INCLUDE_DIR "${INSTALL_DIR}/src/install/include") +-- +2.17.1 +