From b6dc9613cda67df165e6d0a058e82ccb33282a1d Mon Sep 17 00:00:00 2001 From: Mark Asselstine Date: Wed, 26 Jun 2013 11:21:54 -0400 Subject: openvswitch: add split between host and target python and perl paths Openvswitch is built with the assumption that the PYTHON and PERL variables are common between the host and target. This can result in improper paths used for script substitutions which in turn causes scripts which will fail to run on the target and the generated packages to have improper REQUIRES, making them impossible to install. These are usually not an issue since python and perl are found in the same location on the host and target, but there is no guarantee of this so the possibility of failure exists. By explicitly defining the location of the python and perl on the target we can avoid these assumptions and possibility of failure. Signed-off-by: Mark Asselstine Signed-off-by: Bruce Ashfield --- .../openvswitch-add-target-perl-handling.patch | 61 ++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 recipes-networking/openvswitch/files/openvswitch-add-target-perl-handling.patch (limited to 'recipes-networking/openvswitch/files/openvswitch-add-target-perl-handling.patch') diff --git a/recipes-networking/openvswitch/files/openvswitch-add-target-perl-handling.patch b/recipes-networking/openvswitch/files/openvswitch-add-target-perl-handling.patch new file mode 100644 index 00000000..35a3d5b3 --- /dev/null +++ b/recipes-networking/openvswitch/files/openvswitch-add-target-perl-handling.patch @@ -0,0 +1,61 @@ +From 569ac1066cd3046b8ac899153df9f07908d45145 Mon Sep 17 00:00:00 2001 +From: Mark Asselstine +Date: Fri, 21 Jun 2013 11:16:00 -0400 +Subject: [PATCH] openvswitch: add target perl handling + +Allow the build to specify a path for the perl instead of reusing +the PERL variable which can lead to inconsistencies if we are cross +compiling. The TARGET_PERL variable will be used for script +substitutions to ensure the scripts will be able to properly execute +if the target system has a different path for the perl. + +Signed-off-by: Mark Asselstine +--- + Makefile.am | 1 + + configure.ac | 7 +++++++ + utilities/ovs-parse-leaks.in | 2 +- + 3 files changed, 9 insertions(+), 1 deletion(-) + +diff --git a/Makefile.am b/Makefile.am +index c4f8341..45488f2 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -111,6 +111,7 @@ SUFFIXES += .in + -e 's,[@]LOGDIR[@],$(LOGDIR),g' \ + -e 's,[@]DBDIR[@],$(DBDIR),g' \ + -e 's,[@]PERL[@],$(PERL),g' \ ++ -e 's,[@]TARGET_PERL[@],$(TARGET_PERL),g' \ + -e 's,[@]PYTHON[@],$(PYTHON),g' \ + -e 's,[@]TARGET_PYTHON[@],$(TARGET_PYTHON),g' \ + -e 's,[@]RUNDIR[@],$(RUNDIR),g' \ +diff --git a/configure.ac b/configure.ac +index 74cb691..5e39893 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -101,6 +101,13 @@ AC_ARG_VAR(KARCH, [Kernel Architecture String]) + AC_SUBST(KARCH) + OVS_CHECK_LINUX + ++if test "$TARGET_PERL"; then ++ TARGET_PERL=$TARGET_PERL ++else ++ TARGET_PERL=$PERL ++fi ++AC_SUBST(TARGET_PERL) ++ + if test "$TARGET_PYTHON"; then + TARGET_PYTHON=$TARGET_PYTHON + else +diff --git a/utilities/ovs-parse-leaks.in b/utilities/ovs-parse-leaks.in +index 72417e5..7c9436c 100755 +--- a/utilities/ovs-parse-leaks.in ++++ b/utilities/ovs-parse-leaks.in +@@ -1,4 +1,4 @@ +-#! @PERL@ ++#! @TARGET_PERL@ + + # Copyright (c) 2009, 2010 Nicira, Inc. + # +-- +1.8.1.2 + -- cgit v1.2.3-54-g00ecf