Browse code

Fix quoting in vercmp check for kernel version

I352362cf59e492fa9f7725190f0243f2436ac347 switched this to vercmp, but
using single-quote (') will mean that the kernel version isn't
actually expanded for the comparision.

I guess, like the original change, the fact it isn't working is
hidden. Trusty seems to have 3.13 ... I can't imagine we support
anything before this ... so I'd also be happy if someone with some OVS
knowledge wants to just delete it.

(This change was originally an alternative to
I352362cf59e492fa9f7725190f0243f2436ac347 but got the quoting right)

Change-Id: I9fa514885c20b1135fb0680cf61fc04628fbecbe
Closes-Bug: #1580850

Yi Zhao authored on 2016/05/12 13:11:24
Showing 1 changed files
... ...
@@ -54,7 +54,7 @@ function _neutron_ovs_base_install_ubuntu_dkms {
54 54
     local kernel_major_minor
55 55
     kernel_major_minor=`echo $kernel_version | cut -d. -f1-2`
56 56
     # From kernel 3.13 on, openvswitch-datapath-dkms is not needed
57
-    if vercmp '$kernel_major_minor' '<' '3.13'; then
57
+    if vercmp "$kernel_major_minor" "<" "3.13" ; then
58 58
         install_package "dkms openvswitch-datapath-dkms linux-headers-$kernel_version"
59 59
     fi
60 60
 }