Merge pull request #502 from bulwahn/mavros-update-v2
repair and update mavros to kinetic (resolves #489)
This commit is contained in:
commit
118a1d0728
|
@ -0,0 +1,13 @@
|
||||||
|
DESCRIPTION = "Clean single-source support for Python 3 and 2"
|
||||||
|
SECTION = "devel/python"
|
||||||
|
LICENSE = "MIT"
|
||||||
|
LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=3f457538b297bd0ef86564b8ac216ad7"
|
||||||
|
SRCNAME = "future"
|
||||||
|
|
||||||
|
SRC_URI = "https://pypi.python.org/packages/00/2b/8d082ddfed935f3608cc61140df6dcbf0edea1bc3ab52fb6c29ae3e81e85/future-${PV}.tar.gz"
|
||||||
|
SRC_URI[md5sum] = "3e8e88a2bda48d54b1da7634d04760d7"
|
||||||
|
SRC_URI[sha256sum] = "e39ced1ab767b5936646cedba8bcce582398233d6a627067d4c6a454c90cfedb"
|
||||||
|
|
||||||
|
S = "${WORKDIR}/${SRCNAME}-${PV}"
|
||||||
|
|
||||||
|
BBCLASSEXTEND += "native"
|
|
@ -0,0 +1,3 @@
|
||||||
|
require python-future.inc
|
||||||
|
|
||||||
|
inherit setuptools
|
|
@ -0,0 +1,3 @@
|
||||||
|
require python-future.inc
|
||||||
|
|
||||||
|
inherit setuptools3
|
|
@ -0,0 +1,45 @@
|
||||||
|
From 9a48d109510a9e3592fb90bb1ab89853dfa62da3 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Lukas Bulwahn <lukas.bulwahn@gmail.com>
|
||||||
|
Date: Sun, 7 May 2017 07:02:29 +0200
|
||||||
|
Subject: [PATCH 1/2] do not require python2
|
||||||
|
|
||||||
|
When only a python3 interpreter is available, CMake fails with:
|
||||||
|
|
||||||
|
```
|
||||||
|
| CMake Error at /home/lukas/work/repositories/openembedded.org/openembedded-core/build/tmp-glibc/work/core2-64-oe-linux/ros-mavlink/git-r0/recipe-sysroot-native/usr/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:138 (message):
|
||||||
|
| Could NOT find PythonInterp (missing: PYTHON_EXECUTABLE) (Required is at
|
||||||
|
| least version "2")
|
||||||
|
| Call Stack (most recent call first):
|
||||||
|
| /home/lukas/work/repositories/openembedded.org/openembedded-core/build/tmp-glibc/work/core2-64-oe-linux/ros-mavlink/git-r0/recipe-sysroot-native/usr/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
|
||||||
|
| /home/lukas/work/repositories/openembedded.org/openembedded-core/build/tmp-glibc/work/core2-64-oe-linux/ros-mavlink/git-r0/recipe-sysroot-native/usr/share/cmake-3.7/Modules/FindPythonInterp.cmake:151 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
|
||||||
|
| CMakeLists.txt:22 (find_package)
|
||||||
|
|
|
||||||
|
|
|
||||||
|
| -- Configuring incomplete, errors occurred!
|
||||||
|
```
|
||||||
|
|
||||||
|
After dropping this one line, CMake does not insist on python2,
|
||||||
|
and configures mavlink successfully.
|
||||||
|
|
||||||
|
Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
|
||||||
|
|
||||||
|
Upstream-Status: Pending
|
||||||
|
---
|
||||||
|
CMakeLists.txt | 1 -
|
||||||
|
1 file changed, 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||||
|
index 594ecb3..26a4210 100644
|
||||||
|
--- a/CMakeLists.txt
|
||||||
|
+++ b/CMakeLists.txt
|
||||||
|
@@ -18,7 +18,6 @@ include(GNUInstallDirs)
|
||||||
|
set(CMAKE_INSTALL_LIBDIR lib)
|
||||||
|
|
||||||
|
# find libraries with cmake modules
|
||||||
|
-set(PythonInterp_FIND_VERSION "2")
|
||||||
|
find_package(PythonInterp REQUIRED)
|
||||||
|
|
||||||
|
# Try to read package version from package.xml
|
||||||
|
--
|
||||||
|
1.9.1
|
||||||
|
|
|
@ -0,0 +1,43 @@
|
||||||
|
From 6ac7498052f0e97e978c8adf887b9bbf851d58e2 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Lukas Bulwahn <lukas.bulwahn@gmail.com>
|
||||||
|
Date: Sun, 7 May 2017 07:02:49 +0200
|
||||||
|
Subject: [PATCH 2/2] provide path to find mavgen_c
|
||||||
|
|
||||||
|
When compiling mavlink, it failed with:
|
||||||
|
|
||||||
|
```
|
||||||
|
| Generating C headers
|
||||||
|
| Traceback (most recent call last):
|
||||||
|
| File "/home/lukas/work/repositories/openembedded.org/openembedded-core/build/tmp-glibc/work/core2-64-oe-linux/ros-mavlink/git-r0/git/pymavlink/tools/mavgen.py", line 30, in <module>
|
||||||
|
| mavgen.mavgen(args, args.definitions)
|
||||||
|
| File "/home/lukas/work/repositories/openembedded.org/openembedded-core/build/tmp-glibc/work/core2-64-oe-linux/ros-mavlink/git-r0/git/pymavlink/generator/mavgen.py", line 154, in mavgen
|
||||||
|
| mavgen_cpp11.generate(opts.output, xml)
|
||||||
|
| File "/home/lukas/work/repositories/openembedded.org/openembedded-core/build/tmp-glibc/work/core2-64-oe-linux/ros-mavlink/git-r0/git/pymavlink/generator/mavgen_cpp11.py", line 451, in generate
|
||||||
|
| import mavgen_c
|
||||||
|
| ImportError: No module named 'mavgen_c'
|
||||||
|
```
|
||||||
|
|
||||||
|
This commit provides the path to find mavgen_c, as already done in
|
||||||
|
many other places.
|
||||||
|
|
||||||
|
Upstream-Status: Pending
|
||||||
|
---
|
||||||
|
pymavlink/generator/mavgen_cpp11.py | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/pymavlink/generator/mavgen_cpp11.py b/pymavlink/generator/mavgen_cpp11.py
|
||||||
|
index 797ab2e..5fc824a 100644
|
||||||
|
--- a/pymavlink/generator/mavgen_cpp11.py
|
||||||
|
+++ b/pymavlink/generator/mavgen_cpp11.py
|
||||||
|
@@ -448,7 +448,7 @@ def generate_one(basename, xml):
|
||||||
|
def generate(basename, xml_list):
|
||||||
|
'''generate serialization MAVLink C++ implemenation'''
|
||||||
|
print("Generating C headers")
|
||||||
|
- import mavgen_c
|
||||||
|
+ from . import mavgen_c
|
||||||
|
mavgen_c.generate(basename, xml_list)
|
||||||
|
for xml in xml_list:
|
||||||
|
generate_one(basename, xml)
|
||||||
|
--
|
||||||
|
1.9.1
|
||||||
|
|
|
@ -2,13 +2,14 @@ DESCRIPTION = "MAVLink message marshaling library"
|
||||||
LICENSE = "LGPLv3"
|
LICENSE = "LGPLv3"
|
||||||
LIC_FILES_CHKSUM = "file://COPYING;md5=54ad3cbe91bebcf6b1823970ff1fb97f"
|
LIC_FILES_CHKSUM = "file://COPYING;md5=54ad3cbe91bebcf6b1823970ff1fb97f"
|
||||||
|
|
||||||
SRC_URI = "git://github.com/mavlink/mavlink-gbp-release.git;branch=release/${ROSDISTRO}/mavlink"
|
SRC_URI = "git://github.com/mavlink/mavlink-gbp-release.git;branch=release/kinetic/mavlink"
|
||||||
SRCREV = "${AUTOREV}"
|
SRCREV = "${AUTOREV}"
|
||||||
|
|
||||||
SRC_URI += "file://0001-Fix-PKG_NAME-_INCLUDE_DIR-variable.patch"
|
SRC_URI += "file://0001-do-not-require-python2.patch"
|
||||||
|
SRC_URI += "file://0002-provide-path-to-find-mavgen_c.patch"
|
||||||
|
|
||||||
S = "${WORKDIR}/git"
|
S = "${WORKDIR}/git"
|
||||||
|
|
||||||
DEPENDS = "python-setuptools-native"
|
DEPENDS = "${PYTHON_PN}-setuptools-native ${PYTHON_PN}-future-native"
|
||||||
|
|
||||||
inherit catkin
|
inherit catkin
|
|
@ -4,13 +4,13 @@ LIC_FILES_CHKSUM = "file://package.xml;beginline=15;endline=17;md5=9b511d4c606b1
|
||||||
|
|
||||||
DEPENDS = " \
|
DEPENDS = " \
|
||||||
boost \
|
boost \
|
||||||
ros-mavlink \
|
mavlink \
|
||||||
console-bridge \
|
console-bridge \
|
||||||
"
|
"
|
||||||
|
|
||||||
RDEPENDS_${PN} = " \
|
RDEPENDS_${PN} = " \
|
||||||
boost \
|
boost \
|
||||||
ros-mavlink \
|
mavlink \
|
||||||
console-bridge \
|
console-bridge \
|
||||||
"
|
"
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
SRC_URI = "https://github.com/mavlink/${ROS_SPN}/archive/${PV}.tar.gz;downloadfilename=${ROS_SP}.tar.gz"
|
SRC_URI = "https://github.com/mavlink/${ROS_SPN}/archive/${PV}.tar.gz;downloadfilename=${ROS_SP}.tar.gz"
|
||||||
SRC_URI[md5sum] = "eea22457db6c7b8a17bba0223a41dceb"
|
SRC_URI[md5sum] = "88a94aeeeda9bc8f7e5b1997071464ac"
|
||||||
|
SRC_URI[sha256sum] = "92e086072ac0641143b59d1dbda7ab54e5903d55001eaeceb34432efe3b07dcc"
|
||||||
|
|
||||||
S = "${WORKDIR}/${ROS_SP}/${ROS_BPN}"
|
S = "${WORKDIR}/${ROS_SP}/${ROS_BPN}"
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,36 @@
|
||||||
|
From d7b00940cb69d659d77bb08b1cbbf5aad4ea4617 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Lukas Bulwahn <lukas.bulwahn@gmail.com>
|
||||||
|
Date: Sun, 7 May 2017 06:14:18 +0200
|
||||||
|
Subject: [PATCH] always find Eigen with cmake_modules mechanism
|
||||||
|
|
||||||
|
Upstream-Status: Pending
|
||||||
|
---
|
||||||
|
mavros/CMakeLists.txt | 12 ++++--------
|
||||||
|
1 file changed, 4 insertions(+), 8 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/mavros/CMakeLists.txt b/mavros/CMakeLists.txt
|
||||||
|
index 3b3a0bd..bcc7924 100644
|
||||||
|
--- a/mavros/CMakeLists.txt
|
||||||
|
+++ b/mavros/CMakeLists.txt
|
||||||
|
@@ -26,14 +26,10 @@ find_package(catkin REQUIRED COMPONENTS
|
||||||
|
# find_package(Boost REQUIRED COMPONENTS system)
|
||||||
|
find_package(Boost REQUIRED COMPONENTS system)
|
||||||
|
|
||||||
|
-find_package(Eigen3)
|
||||||
|
-if(NOT EIGEN3_FOUND)
|
||||||
|
- # Fallback to cmake_modules
|
||||||
|
- find_package(cmake_modules REQUIRED)
|
||||||
|
- find_package(Eigen REQUIRED)
|
||||||
|
- set(EIGEN3_INCLUDE_DIRS ${EIGEN_INCLUDE_DIRS})
|
||||||
|
- set(EIGEN3_LIBRARIES ${EIGEN_LIBRARIES})
|
||||||
|
-endif()
|
||||||
|
+find_package(cmake_modules REQUIRED)
|
||||||
|
+find_package(Eigen REQUIRED)
|
||||||
|
+set(EIGEN3_INCLUDE_DIRS ${EIGEN_INCLUDE_DIRS})
|
||||||
|
+set(EIGEN3_LIBRARIES ${EIGEN_LIBRARIES})
|
||||||
|
|
||||||
|
include(EnableCXX11)
|
||||||
|
include(MavrosMavlink)
|
||||||
|
--
|
||||||
|
1.9.1
|
||||||
|
|
|
@ -8,12 +8,12 @@ LIC_FILES_CHKSUM = "file://package.xml;beginline=12;endline=14;md5=9b511d4c606b1
|
||||||
DEPENDS = " \
|
DEPENDS = " \
|
||||||
boost \
|
boost \
|
||||||
libeigen \
|
libeigen \
|
||||||
ros-mavlink \
|
mavlink \
|
||||||
"
|
"
|
||||||
|
|
||||||
RDEPENDS_${PN} = " \
|
RDEPENDS_${PN} = " \
|
||||||
boost \
|
boost \
|
||||||
ros-mavlink \
|
mavlink \
|
||||||
"
|
"
|
||||||
|
|
||||||
# ROS packages dependencies
|
# ROS packages dependencies
|
||||||
|
@ -47,3 +47,5 @@ RDEPENDS_${PN}_append = "${MAVROS_RUN_AND_BUILD_DEPENDS}"
|
||||||
require mavros.inc
|
require mavros.inc
|
||||||
|
|
||||||
ROS_PKG_SUBDIR = "mavros"
|
ROS_PKG_SUBDIR = "mavros"
|
||||||
|
|
||||||
|
SRC_URI += "file://0001-always-find-Eigen-with-cmake_modules-mechanism.patch;striplevel=2"
|
|
@ -184,9 +184,12 @@ RDEPENDS_${PN} = "\
|
||||||
cv-camera \
|
cv-camera \
|
||||||
object-recognition-msgs \
|
object-recognition-msgs \
|
||||||
srdfdom \
|
srdfdom \
|
||||||
|
libmavconn \
|
||||||
|
mavros \
|
||||||
|
mavros-extras \
|
||||||
|
mavlink \
|
||||||
"
|
"
|
||||||
|
|
||||||
# ros-mavlink fails while configuring; libmavconn, mavros, mavros-extras depend on ros-mavlink.
|
|
||||||
# urdfdom-headers is an empty deploy package.
|
# urdfdom-headers is an empty deploy package.
|
||||||
# image-view requires gtk+, but it cannot be found by cmake for some reason.
|
# image-view requires gtk+, but it cannot be found by cmake for some reason.
|
||||||
# sound-play requires python-gst (which is not available in any layers' master branch)
|
# sound-play requires python-gst (which is not available in any layers' master branch)
|
||||||
|
|
|
@ -1,31 +0,0 @@
|
||||||
From af522ba6b85be00a712618c719e831b941a8ffdc Mon Sep 17 00:00:00 2001
|
|
||||||
From: Gustavo Jose de Sousa <gustavo.sousa@intel.com>
|
|
||||||
Date: Wed, 16 Nov 2016 13:23:49 -0200
|
|
||||||
Subject: [PATCH] Fix @PKG_NAME@_INCLUDE_DIR variable
|
|
||||||
|
|
||||||
The previous approach hardcoded the path to the include directory and cross
|
|
||||||
compilation using a sysroot directory would fail. This patch takes the
|
|
||||||
resulting config files generated from other ROS packages as reference.
|
|
||||||
|
|
||||||
Upstream-Status: Backport [https://github.com/mavlink/mavlink-gbp-release/pull/5]
|
|
||||||
---
|
|
||||||
config.cmake.in | 3 ++-
|
|
||||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
||||||
|
|
||||||
diff --git a/config.cmake.in b/config.cmake.in
|
|
||||||
index b62ab64..34bed61 100644
|
|
||||||
--- a/config.cmake.in
|
|
||||||
+++ b/config.cmake.in
|
|
||||||
@@ -3,7 +3,8 @@ if (@PKG_NAME@_CONFIG_INCLUDED)
|
|
||||||
endif()
|
|
||||||
set(@PKG_NAME@_CONFIG_INCLUDED TRUE)
|
|
||||||
|
|
||||||
-set(@PKG_NAME@_INCLUDE_DIRS "@CMAKE_INSTALL_PREFIX@/include")
|
|
||||||
+get_filename_component(include "${@PKG_NAME@_DIR}/../../../include" ABSOLUTE)
|
|
||||||
+set(@PKG_NAME@_INCLUDE_DIRS ${include})
|
|
||||||
set(@PKG_NAME@_DIALECTS @PKG_MAVLINK_DIALECTS@)
|
|
||||||
set(@PKG2_NAME@_DIALECTS @PKG2_MAVLINK_DIALECTS@)
|
|
||||||
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
Loading…
Reference in New Issue