summaryrefslogtreecommitdiffstats
path: root/patches/fuel-plugin-ovs/0009-install.sh-AArch64-Fix-dpkg-installation-issues.patch
diff options
context:
space:
mode:
authorAlexandru Avadanii <Alexandru.Avadanii@enea.com>2016-09-14 14:58:53 +0000
committerGerrit Code Review <gerrit@172.30.200.206>2016-09-14 14:58:53 +0000
commit7f4c6609599316eee4a48f34a31e15926289cd6e (patch)
treef22f053df6783ef7c0313419128b7f455c3294ae /patches/fuel-plugin-ovs/0009-install.sh-AArch64-Fix-dpkg-installation-issues.patch
parent1efd72febdd208d4dee9e1fb000493d837febb71 (diff)
parent5b49b2f7ea1485b56ebc7815b5a3803363ec29af (diff)
Merge "AArch64: fuel-plugin-ovs enable"
Diffstat (limited to 'patches/fuel-plugin-ovs/0009-install.sh-AArch64-Fix-dpkg-installation-issues.patch')
-rw-r--r--patches/fuel-plugin-ovs/0009-install.sh-AArch64-Fix-dpkg-installation-issues.patch82
1 files changed, 82 insertions, 0 deletions
diff --git a/patches/fuel-plugin-ovs/0009-install.sh-AArch64-Fix-dpkg-installation-issues.patch b/patches/fuel-plugin-ovs/0009-install.sh-AArch64-Fix-dpkg-installation-issues.patch
new file mode 100644
index 00000000..8f7a259f
--- /dev/null
+++ b/patches/fuel-plugin-ovs/0009-install.sh-AArch64-Fix-dpkg-installation-issues.patch
@@ -0,0 +1,82 @@
+From: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
+Date: Wed, 14 Sep 2016 16:42:48 +0200
+Subject: [PATCH] install.sh: AArch64: Fix dpkg installation issues
+
+There are 2 minor issues with our Armband version string of
+openvswitch packages shipped for fuel-plugin-ovs:
+
+1. Setting up openvswitch-datapath-dkms (2.5.90~08.08-1+amos1)
+ ... Error! Could not find module source directory.
+
+This happens because our version string has a "+" char in it,
+and the /usr/src path looked for is trimmed at that char,
+hence dkms installation is looking for
+"/usr/src/openvswitch-2.5.90~08.08" directory instead of
+"/usr/src/openvswitch-2.5.90~08.08+amos1".
+
+Temporary fix will be to add the following to install.sh:
+ln -s openvswitch-2.5.90~08.08+amos1/ openvswitch-2.5.90~08.08
+
+2. dpkg -i complains about "breaks" dependencies in debian/control
+when reinstalling OVS 2.5.90.
+
+This happens because of faulty dpkg version comparison algorithm:
+$ dpkg --compare-versions 2.5.90~08.08-1+amos1
+ gt 2.5.90 && echo "This should work!"
+$
+
+The temporary fix will be to add --force-breaks to dpkg invocation.
+
+Related-bug: ARMBAND-89
+
+Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
+---
+ deployment_scripts/install.sh | 26 ++++++++++++++++++--------
+ 1 file changed, 18 insertions(+), 8 deletions(-)
+
+diff --git a/deployment_scripts/install.sh b/deployment_scripts/install.sh
+index 46d74bb..169c64a 100644
+--- a/deployment_scripts/install.sh
++++ b/deployment_scripts/install.sh
+@@ -17,10 +17,20 @@ if [ $nsh = 'true' ]; then
+ fi
+
+ curl http://$host:8080/plugins/fuel-plugin-ovs-0.9/repositories/ubuntu/${ovs} | tar -xzv
+-dpkg -i openvswitch-datapath-dkms_*.deb
+-dpkg -i openvswitch-common_*.deb
+-dpkg -i openvswitch-switch_*.deb
+-dpkg -i python-openvswitch_*.deb
++
++# FIXME(armband): https://jira.opnfv.org/browse/ARMBAND-89
++# e.g.: ln -s openvswitch-2.5.90~08.08+amos1 openvswitch-2.5.90~08.08
++for usr_src_ovs in /usr/src/openvswitch-*+*; do
++ echo ${usr_src_ovs}
++ if [ -d ${usr_src_ovs} ]; then
++ ln -sf ${usr_src_ovs} ${usr_src_ovs%+*}
++ fi
++done
++
++dpkg -i --force-breaks openvswitch-datapath-dkms_*.deb
++dpkg -i --force-breaks openvswitch-common_*.deb
++dpkg -i --force-breaks openvswitch-switch_*.deb
++dpkg -i --force-breaks python-openvswitch_*.deb
+ if [ $dpdk = 'true' ]; then
+ if [ $nsh = 'true' -o -n $dpdk_socket_mem ]; then
+ dpkg -i libxenstore3.0*.deb
+@@ -28,12 +38,12 @@ if [ $dpdk = 'true' ]; then
+ # FIXME(armband): arm64 DPDK ships individual libs, install them all
+ dpdk_deb_name=$(ls dpdk_*)
+ dpdk_deb_suffix=${dpdk_deb_name#dpdk_}
+- dpkg -i *${dpdk_deb_suffix%_*}*.deb
++ dpkg -i --force-breaks *${dpdk_deb_suffix%_*}*.deb
+ else
+- dpkg -i libdpdk0_*.deb
+- dpkg -i dpdk_*.deb
++ dpkg -i --force-breaks libdpdk0_*.deb
++ dpkg -i --force-breaks dpdk_*.deb
+ fi
+- dpkg -i openvswitch-switch-dpdk_*.deb
++ dpkg -i --force-breaks openvswitch-switch-dpdk_*.deb
+ fi
+ if ! [ $nsh = 'true' -a -n $dpdk_socket_mem ]; then
+ #Set to 0, dpdk init script mount hugepages but don't change current allocation