genlisp: Setup python script path during runtime via find_program
The python script path for gen_lisp.py is hard coded in the CMake file and doesn't work during cross compile. Setup it via find_program during runtime. This closes #87 with the following error: *** No rule to make target `/usr/lib/genlisp/gen_lisp.py', needed by `devel/share/common-lisp/ros/std_msgs/msg/Bool.lisp'. Stop Signed-off-by: Stefan Herbrechtsmeier <stefan@herbrechtsmeier.net>
This commit is contained in:
parent
a04ef9b695
commit
5592bfe881
|
@ -0,0 +1,38 @@
|
|||
From 4efc32314f5ee02e5be759ea288e11b6de64f1a1 Mon Sep 17 00:00:00 2001
|
||||
From: Stefan Herbrechtsmeier <stefan@herbrechtsmeier.net>
|
||||
Date: Tue, 4 Jun 2013 17:58:41 +0200
|
||||
Subject: [PATCH] genlisp-extras.cmake.em: Use find_program for GENLISP_BIN
|
||||
|
||||
Signed-off-by: Stefan Herbrechtsmeier <stefan@herbrechtsmeier.net>
|
||||
---
|
||||
cmake/genlisp-extras.cmake.em | 10 +++++++---
|
||||
1 files changed, 7 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/cmake/genlisp-extras.cmake.em b/cmake/genlisp-extras.cmake.em
|
||||
index 0d135d0..db52d54 100644
|
||||
--- a/cmake/genlisp-extras.cmake.em
|
||||
+++ b/cmake/genlisp-extras.cmake.em
|
||||
@@ -1,13 +1,17 @@
|
||||
@[if DEVELSPACE]@
|
||||
# bin and template dir variables in develspace
|
||||
-set(GENLISP_BIN @(CMAKE_CURRENT_SOURCE_DIR)/scripts/gen_lisp.py)
|
||||
+set(GENLISP_BIN_DIR @(CMAKE_CURRENT_SOURCE_DIR)/scripts/gen_lisp.py)
|
||||
set(GENLISP_TEMPLATE_DIR @(CMAKE_CURRENT_SOURCE_DIR)/scripts)
|
||||
+set(CATKIN_FIND_ROOT_PATH_MODE NO_CMAKE_FIND_ROOT_PATH)
|
||||
@[else]@
|
||||
# bin and template dir variables in installspace
|
||||
-set(GENLISP_BIN @(CMAKE_INSTALL_PREFIX)/@(CATKIN_PACKAGE_BIN_DESTINATION)/gen_lisp.py)
|
||||
-set(GENLISP_TEMPLATE_DIR @(CMAKE_INSTALL_PREFIX)/@(CATKIN_PACKAGE_SHARE_DESTINATION))
|
||||
+set(GENLISP_BIN_DIR @(CMAKE_INSTALL_PREFIX)/@(CATKIN_PACKAGE_BIN_DESTINATION)/)
|
||||
+set(GENLISP_TEMPLATE_DIR "${CMAKE_CURRENT_LIST_DIR}/..")
|
||||
+set(CATKIN_FIND_ROOT_PATH_MODE "")
|
||||
@[end if]@
|
||||
|
||||
+find_program(GENLISP_BIN gen_lisp.py PATHS ${GENLISP_BIN_DIR} NO_DEFAULT_PATH ${CATKIN_FIND_ROOT_PATH_MODE})
|
||||
+
|
||||
# Generate .msg or .srv -> .lisp
|
||||
# The generated .lisp files should be added ALL_GEN_OUTPUT_FILES_lisp
|
||||
macro(_generate_lisp ARG_PKG ARG_MSG ARG_IFLAGS ARG_MSG_DEPS ARG_GEN_OUTPUT_DIR)
|
||||
--
|
||||
1.7.0.4
|
||||
|
|
@ -5,7 +5,10 @@ LIC_FILES_CHKSUM = "file://package.xml;beginline=9;endline=9;md5=d566ef916e9dedc
|
|||
|
||||
DEPENDS = "genmsg-native"
|
||||
|
||||
SRC_URI = "https://github.com/ros/${BPN}/archive/${PV}.tar.gz;downloadfilename=${BP}.tar.gz"
|
||||
PR = "r1"
|
||||
|
||||
SRC_URI = "https://github.com/ros/${BPN}/archive/${PV}.tar.gz;downloadfilename=${BP}.tar.gz \
|
||||
file://0001-genlisp-extras.cmake.em-Use-find_program-for-GENLISP.patch"
|
||||
SRC_URI[md5sum] = "ae3026fd36a31d286f79a9111450adfa"
|
||||
SRC_URI[sha256sum] = "13f606f23eec18c0f653a259d972d9bdb13251111e4af280830a961a4858c475"
|
||||
|
||||
|
|
Loading…
Reference in New Issue