Merge "Fix devstack/lib/ovs to run with Fedora 28"

This commit is contained in:
Zuul 2018-09-03 22:52:39 +00:00 committed by Gerrit Code Review
commit 381d1cc715
1 changed files with 4 additions and 1 deletions

View File

@ -53,7 +53,10 @@ function prepare_for_compilation {
if is_fedora ; then
# is_fedora covers Fedora, RHEL, CentOS, etc...
if [[ ${KERNEL_VERSION:0:2} != "3." ]]; then
if [[ "$os_VENDOR" == "Fedora" ]]; then
install_package elfutils-libelf-devel
KERNEL_VERSION=`echo $KERNEL_VERSION | cut --delimiter='-' --field 1`
elif [[ ${KERNEL_VERSION:0:2} != "3." ]]; then
# dash is illegal character in rpm version so replace
# them with underscore like it is done in the kernel
# https://github.com/torvalds/linux/blob/master/scripts/package/mkspec#L25