raisin: Miscelaneous improvements
cover raisin: Miscelaneous improvements
Miscellaneous improvements
George Dunlap (5):
raisin: Handle aliases for packages, add pciutils-dev / libpci-dev
alias
raisin: Detect systemd
raisin: Allow iasl to alias acpica-tools, unify Fedora and CentOS deps
for xen
raisin: Change update/release parsing OSes
raisin: Add XEN_CONFIG_EXTRA to config file
components/qemu_traditional | 2 +- components/xen | 18 ++++++++++++++---- configs/config-4.5 | 4 ++++ configs/config-4.6 | 4 ++++ configs/config-master | 4 ++++ lib/common-functions.sh | 33 +++++++++++++++++++++++++-------- 6 files changed, 52 insertions(+), 13 deletions(-)
Signature · 1 line
2.1.4
PATCH 1/5 raisin: Handle aliases for packages, add pciutils-dev / libpci-dev alias
It's not uncommon for packages to be renamed, and for package managers to know the translation from old packages to new packages. For example:
# apt-get install pciutils-dev Reading package lists... Done Building dependency tree Reading state information... Done Note, selecting 'libpci-dev' instead of 'pciutils-dev' libpci-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
So the command succeeds, but the subsequent package check still fails, cince "pciutils-dev" wasn't actually installed. This means that even after running "install-builddep", "build" will prompt you to install the old package every time.
Allow components to specify known aliases for a given package by speficying a a|b|c. Check-package will check consecutively for a, b, and c; if it finds any of them, it will stop looking and install nothing. If it finds nothing, it will add the first package to the missing_packages list.
Assuming that package managers are backwards-compatible, components should put the oldest known package first for maximum compatibility.
Also add such an alias for pciutils-dev|libpci-dev in qemu_traditional
--- components/qemu_traditional | 2 +- lib/common-functions.sh | 25 ++++++++++++++++++++----- 2 files changed, 21 insertions(+), 6 deletions(-)
components/qemu_traditional +1 -1
@@ -10,7 +10,7 @@ function qemu_traditional_skip() { } function qemu_traditional_check_package() { - local DEP_Debian_common="build-essential zlib1g-dev pciutils-dev pkg-config \ + local DEP_Debian_common="build-essential zlib1g-dev pciutils-dev|libpci-dev pkg-config \ libncurses5-dev" local DEP_Debian_x86_32="$DEP_Debian_common" local DEP_Debian_x86_64="$DEP_Debian_common"
lib/common-functions.sh +20 -5
@@ -233,14 +233,29 @@ function _install-package-unknown() { # Modifies inherited variable "missing" function check-package() { + local OIFS=${IFS} + local p + local x + for p in $* do - if ! _check-package-${PKGTYPE} $p - then - missing+=("$p") - fi + local found=false + IFS='|' + for x in $p + do + if _check-package-${PKGTYPE} $x + then + found=true + fi + done + IFS="$OIFS" + if ! $found + then + # Add the first of the aliases, on the assumption that the package + # manager will be backwards-compatible + missing+=("${p%%|*}") + fi done - } function install-package() {
Signature · 1 line
2.1.4
Re: [PATCH 1/5] raisin: Handle aliases for packages, add pciutils-dev / libpci-dev alias
Quoted 23 lines · George Dunlap
It's not uncommon for packages to be renamed, and for package managers to know the translation from old packages to new packages. For example:
# apt-get install pciutils-dev Reading package lists... Done Building dependency tree Reading state information... Done Note, selecting 'libpci-dev' instead of 'pciutils-dev' libpci-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.So the command succeeds, but the subsequent package check still fails, cince "pciutils-dev" wasn't actually installed. This means that even after running "install-builddep", "build" will prompt you to install the old package every time.
Allow components to specify known aliases for a given package by speficying a a|b|c. Check-package will check consecutively for a, b, and c; if it finds any of them, it will stop looking and install nothing. If it finds nothing, it will add the first package to the
missing_packageslist.
Quoted 6 lines
Assuming that package managers are backwards-compatible, components should put the oldest known package first for maximum compatibility.
Also add such an alias for pciutils-dev|libpci-dev in
qemu_traditionalSigned-off-by George Dunlap <[email protected]>
Thanks for the patch, this is very useful and I like the way it is done.
Please use spaces for indentation.
Quoted 22 lines
components/qemu_traditional | 2 +- lib/common-functions.sh | 25 ++++++++++++++++++++----- 2 files changed, 21 insertions(+), 6 deletions(-)components/qemu_traditional +1
-1@@ -10,7 +10,7 @@ function qemu_traditional_skip() { } function qemu_traditional_check_package() { - local DEP_Debian_common="build-essential zlib1g-dev pciutils-dev pkg-config \ + local DEP_Debian_common="build-essential zlib1g-dev pciutils-dev|libpci-dev pkg-config \ libncurses5-dev" local DEP_Debian_x86_32="$DEP_Debian_common" local DEP_Debian_x86_64="$DEP_Debian_common"lib/common-functions.sh +0
-0
lib/common-functions.sh function _install-package-unknown() { · line 236
Quoted 4 lines
lib/common-functions.sh +1
-0@@ -233,14 +233,29 @@ function _install-package-unknown() { # Modifies inherited variable "missing" function check-package() { + local OIFS=${IFS}
local OIFS="$IFS"
Quoted 18 lines
lib/common-functions.sh +12
-4+ local p + local x + for p in $* do - if ! _check-package-${PKGTYPE} $p - then - missing+=("$p") - fi + local found=false + IFS='|' + for x in $p + do + if _check-package-${PKGTYPE} $x + then + found=true + fi + done
lib/common-functions.sh function _install-package-unknown() { · line 259
Quoted 10 lines
lib/common-functions.sh +7
-1+ IFS="$OIFS" + if ! $found + then + # Add the first of the aliases, on the assumption that the package + # manager will be backwards-compatible + missing+=("${p%%|*}") + fi done - }
Everything else is fine
Re: [PATCH 1/5] raisin: Handle aliases for packages, add pciutils-dev / libpci-dev alias
Quoted 27 lines · Stefano Stabellini
Quoted 26 lines · George Dunlap
It's not uncommon for packages to be renamed, and for package managers to know the translation from old packages to new packages. For example:
# apt-get install pciutils-dev Reading package lists... Done Building dependency tree Reading state information... Done Note, selecting 'libpci-dev' instead of 'pciutils-dev' libpci-dev is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.So the command succeeds, but the subsequent package check still fails, cince "pciutils-dev" wasn't actually installed. This means that even after running "install-builddep", "build" will prompt you to install the old package every time.
Allow components to specify known aliases for a given package by speficying a a|b|c. Check-package will check consecutively for a, b, and c; if it finds any of them, it will stop looking and install nothing. If it finds nothing, it will add the first package to the
missing_packageslist.Assuming that package managers are backwards-compatible, components should put the oldest known package first for maximum compatibility.
Quoted 7 lines
Quoted 3 lines
Also add such an alias for pciutils-dev|libpci-dev in
qemu_traditionalSigned-off-by George Dunlap <[email protected]>Thanks for the patch, this is very useful and I like the way it is done.
Please use spaces for indentation.
Oops -- used to emacs just doing that for me automatically.
Quoted 25 lines
Quoted 25 lines
components/qemu_traditional | 2 +- lib/common-functions.sh | 25 ++++++++++++++++++++----- 2 files changed, 21 insertions(+), 6 deletions(-)components/qemu_traditional +1
-1@@ -10,7 +10,7 @@ function qemu_traditional_skip() { } function qemu_traditional_check_package() { - local DEP_Debian_common="build-essential zlib1g-dev pciutils-dev pkg-config \ + local DEP_Debian_common="build-essential zlib1g-dev pciutils-dev|libpci-dev pkg-config \ libncurses5-dev" local DEP_Debian_x86_32="$DEP_Debian_common" local DEP_Debian_x86_64="$DEP_Debian_common"lib/common-functions.sh +0
-0@@ -233,14 +233,29 @@ function _install-package-unknown() {
Quoted 5 lines
lib/common-functions.sh function _install-package-unknown() { · line 236
Quoted 3 lines
lib/common-functions.sh +1
-0# Modifies inherited variable "missing" function check-package() { + local OIFS=${IFS}local OIFS="$IFS"
Ack
Quoted 24 lines
Quoted 24 lines
lib/common-functions.sh +16
-4+ local p + local x + for p in $* do - if ! _check-package-${PKGTYPE} $p - then - missing+=("$p") - fi + local found=false + IFS='|' + for x in $p + do + if _check-package-${PKGTYPE} $x + then + found=true + fi + done + IFS="$OIFS" + if ! $found + then + # Add the first of the aliases, on the assumption that the package
Quoted 8 lines
lib/common-functions.sh function _install-package-unknown() { · line 259
Quoted 6 lines
lib/common-functions.sh +3
-1+ # manager will be backwards-compatible + missing+=("${p%%|*}") + fi done - }Everything else is fine
Cool, thanks.
-George
PATCH 2/5 raisin: Detect systemd
In reply to George DunlapAdd systemd development libraries if we detect systemd present on the system
--- components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)
components/xen +10 -0
@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid-dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86 texinfo" local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"
@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid-devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl-devel \ patch pixman-devel glibc-devel bridge-utils grub2 wget tar bzip2" + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" + fi local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 acpica-tools texinfo" local DEP_Fedora_x86_64="$DEP_Fedora_x86_32 glibc-devel.i686"
@@ -23,6 +32,7 @@ function xen_check_package() { local DEP_CentOS_x86_32="$DEP_CentOS_common dev86 texinfo iasl" local DEP_CentOS_x86_64="$DEP_CentOS_x86_32 glibc-devel.i686" + verbose_echo Checking Xen dependencies eval check-package \$DEP_"$DISTRO"_"$RAISIN_ARCH" }
Signature · 1 line
2.1.4
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 3 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>
Sorry, meant to add a comment here...
Quoted 21 lines
--- components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)components/xen +5
-0@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid-dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86 texinfo" local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"
components/xen function xen_check_package() { · line 27
Quoted 7 lines
components/xen +4
-0@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid-devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl-devel \ patch pixman-devel glibc-devel bridge-utils grub2 wget tar bzip2" + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" + fi
This is a bit dodgy, as basically CentOS (and I think Fedora) have separate packages for systemd when inside a container vs on real hardware. But unfortunately I'm not sure there's a way to make yum smart enough to know, "Gee, I'm in a container, I should run systemd instead".
Having the "alias" like this allows the user to work around it by manually installing systemd-container-devel. It's not great though, because there's still nothing to prompt the user to install the correct package.
Also...
components/xen function xen_check_package() { · line 35
Quoted 8 lines
components/xen +1
-0local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 acpica-tools texinfo" local DEP_Fedora_x86_64="$DEP_Fedora_x86_32 glibc-devel.i686"@@ -23,6 +32,7 @@ function xen_check_package() { local DEP_CentOS_x86_32="$DEP_CentOS_common dev86 texinfo iasl" local DEP_CentOS_x86_64="$DEP_CentOS_x86_32 glibc-devel.i686" +
Oops.
-George
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 42 lines · George Dunlap
Quoted 3 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>Sorry, meant to add a comment here...
Quoted 21 lines
--- components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)components/xen +5
-0@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid-dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86 texinfo" local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"components/xen function xen_check_package() { · line 27
Quoted 7 lines
components/xen +4
-0@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid-devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl-devel \ patch pixman-devel glibc-devel bridge-utils grub2 wget tar bzip2" + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" + fiThis is a bit dodgy, as basically CentOS (and I think Fedora) have separate packages for systemd when inside a container vs on real hardware. But unfortunately I'm not sure there's a way to make yum smart enough to know, "Gee, I'm in a container, I should run systemd instead".
Quoted 4 lines
Having the "alias" like this allows the user to work around it by manually installing systemd-container-devel. It's not great though, because there's still nothing to prompt the user to install the correct package.
Can we check which package is installed on the system using check-package (systemd vs systemd-container)? Maybe that would be more reliable.
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 43 lines · Stefano Stabellini
Quoted 42 lines · George Dunlap
Quoted 3 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>Sorry, meant to add a comment here...
Quoted 21 lines
--- components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)components/xen +5
-0@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid-dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86 texinfo" local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"components/xen function xen_check_package() { · line 27
Quoted 7 lines
components/xen +4
-0@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid-devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl-devel \ patch pixman-devel glibc-devel bridge-utils grub2 wget tar bzip2" + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" + fiThis is a bit dodgy, as basically CentOS (and I think Fedora) have separate packages for systemd when inside a container vs on real hardware. But unfortunately I'm not sure there's a way to make yum smart enough to know, "Gee, I'm in a container, I should run systemd instead".
Quoted 8 lines
Quoted 4 lines
Having the "alias" like this allows the user to work around it by manually installing systemd-container-devel. It's not great though, because there's still nothing to prompt the user to install the correct package.
Can we check which package is installed on the system using check-package (systemd vs systemd-container)? Maybe that would be more reliable.
Oh, you mean check-package and then modify the list of required packages as a result? That could work.
-George
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 49 lines · George Dunlap
Quoted 48 lines · Stefano Stabellini
Quoted 46 lines · George Dunlap
Quoted 3 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>Sorry, meant to add a comment here...
Quoted 21 lines
--- components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)components/xen +5
-0@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid-dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86 texinfo" local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"components/xen function xen_check_package() { · line 27
Quoted 7 lines
components/xen +4
-0@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid-devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl-devel \ patch pixman-devel glibc-devel bridge-utils grub2 wget tar bzip2" + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" + fiThis is a bit dodgy, as basically CentOS (and I think Fedora) have separate packages for systemd when inside a container vs on real hardware. But unfortunately I'm not sure there's a way to make yum smart enough to know, "Gee, I'm in a container, I should run systemd instead".
Having the "alias" like this allows the user to work around it by manually installing systemd-container-devel. It's not great though, because there's still nothing to prompt the user to install the correct package.
Quoted 6 lines
Quoted 3 lines
Can we check which package is installed on the system using check-package (systemd vs systemd-container)? Maybe that would be more reliable.
Oh, you mean check-package and then modify the list of required packages as a result? That could work.
Yes, that is what I had in mind. Better than relying on a filesystem path.
Re: [PATCH 2/5] raisin: Detect systemd
In reply to George DunlapQuoted 3 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>
Please use spaces for indentation
components/xen function xen_check_package() { · line 12
Quoted 13 lines
components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)components/xen +2
-0@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid-dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]]
I don't know much about systemd but isn't there a better way to detect systemd? Check if it is running for example?
Quoted 18 lines
components/xen +7
-0+ then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86 texinfo" local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid-devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl-devel \ patch pixman-devel glibc-devel bridge-utils grub2 wget tar bzip2" + if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" + fi local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 acpica-tools texinfo" local DEP_Fedora_x86_64="$DEP_Fedora_x86_32 glibc-devel.i686"
components/xen function xen_check_package() { · line 35
Quoted 4 lines
components/xen +1
-0@@ -23,6 +32,7 @@ function xen_check_package() { local DEP_CentOS_x86_32="$DEP_CentOS_common dev86 texinfo iasl" local DEP_CentOS_x86_64="$DEP_CentOS_x86_32 glibc-devel.i686" +
spurious change
Quoted 6 lines
components/xen +0
-0verbose_echo Checking Xen dependencies eval check-package \$DEP_"$DISTRO"_"$RAISIN_ARCH" }Signature · 1 line
2.1.4
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 12 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>Please use spaces for indentation
Quoted 3 lines
components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)
Quoted 15 lines
components/xen function xen_check_package() { · line 13
Quoted 12 lines
components/xen +2
-1@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid -dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]]I don't know much about systemd but isn't there a better way to detect systemd? Check if it is running for example?
You might want to build with systemd support even if systemd isn't actually the current init system the system was booted with?
Quoted 37 lines
Quoted 26 lines
components/xen +3
-0+ then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86texinfo"
local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"components/xen +0
-2@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid -devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl -devel \ patch pixman-devel glibc-devel bridge-utils grub2 wgettar bzip2"
components/xen +4
-1+ if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd -container-devel" + fi local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 acpica-toolstexinfo"
local DEP_Fedora_x86_64="$DEP_Fedora_x86_32 glibc-devel.i686"components/xen function xen_check_package() { · line 35
Quoted 4 lines
components/xen +1
-0@@ -23,6 +32,7 @@ function xen_check_package() { local DEP_CentOS_x86_32="$DEP_CentOS_common dev86 texinfo iasl" local DEP_CentOS_x86_64="$DEP_CentOS_x86_32 glibc-devel.i686" +spurious change
Quoted 3 lines
components/xen +0
-0verbose_echo Checking Xen dependencies eval check-package \$DEP_"$DISTRO"_"$RAISIN_ARCH" }
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 29 lines · Ian Campbell
Quoted 12 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>Please use spaces for indentation
Quoted 3 lines
components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)Quoted 15 lines
components/xen function xen_check_package() { · line 13
Quoted 12 lines
components/xen +2
-1@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid -dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]]I don't know much about systemd but isn't there a better way to detect systemd? Check if it is running for example?
Quoted 2 lines
You might want to build with systemd support even if systemd isn't actually the current init system the system was booted with?
That is possible but also the vice versa might be true: one might want to build without systemd even if systemd is running. Maybe we need some kind of variable that can be overridden by the user?
Quoted 37 lines
Quoted 36 lines
Quoted 25 lines
components/xen +3
-0+ then + DEP_Debian_common="$DEP_Debian_common libsystemd-daemon-dev" + fi local DEP_Debian_x86_32="$DEP_Debian_common bcc iasl bin86texinfo"
local DEP_Debian_x86_64="$DEP_Debian_x86_32 libc6-dev-i386" local DEP_Debian_arm32="$DEP_Debian_common libfdt-dev"components/xen +0
-2@@ -16,6 +21,10 @@ function xen_check_package() { local DEP_Fedora_common="make gcc python-devel gettext libuuid -devel \ ncurses-devel glib2-devel libaio-devel openssl-devel yajl -devel \ patch pixman-devel glibc-devel bridge-utils grub2 wgettar bzip2"
components/xen +4
-1+ if [[ -e "/usr/lib/systemd" ]] + then + DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd -container-devel" + fi local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 acpica-toolstexinfo"
local DEP_Fedora_x86_64="$DEP_Fedora_x86_32 glibc-devel.i686"components/xen function xen_check_package() { · line 35
Quoted 4 lines
components/xen +1
-0@@ -23,6 +32,7 @@ function xen_check_package() { local DEP_CentOS_x86_32="$DEP_CentOS_common dev86 texinfo iasl" local DEP_CentOS_x86_64="$DEP_CentOS_x86_32 glibc-devel.i686" +spurious change
Quoted 3 lines
components/xen +0
-0verbose_echo Checking Xen dependencies eval check-package \$DEP_"$DISTRO"_"$RAISIN_ARCH" }
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 30 lines · Stefano Stabellini
Quoted 29 lines · Ian Campbell
Quoted 27 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>Please use spaces for indentation
Quoted 8 lines
components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)components/xen +0
-0components/xen function xen_check_package() { · line 13
Quoted 7 lines
components/xen +2
-1@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid -dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]]I don't know much about systemd but isn't there a better way to detect systemd? Check if it is running for example?
Quoted 6 lines
Quoted 2 lines
You might want to build with systemd support even if systemd isn't actually the current init system the system was booted with?
That is possible but also the vice versa might be true: one might want to build without systemd even if systemd is running. Maybe we need some kind of variable that can be overridden by the user?
You mean like XEN_CONFIG_EXTRA? :-D
For people frobbing around with XEN_CONFIG_EXTRA, I think it's reasonable for them to get a build error if they add --with-systemd but don't have the requisite packages. (I'm pretty sure that's what will happen now, at any rate.)
Since I'm going to be checking for systemd packages anyway due to the container issue, maybe it would just make sense to include the dep automatically only if the systemd packages are installed.
Alternately, I suppose we could extend the check-package "syntax" to have "if package X in stalled, add dependency Y" -- similar to the '|' operator we added earlier. Then we could do something like this:
systemd:systemd-devel systemd-container:systemd-container-devel
What do you think?
-George
Re: [PATCH 2/5] raisin: Detect systemd
Quoted 31 lines · George Dunlap
Quoted 30 lines · Stefano Stabellini
Quoted 29 lines · Ian Campbell
Quoted 27 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Add systemd development libraries if we detect systemd present on the system
Signed-off-by George Dunlap <[email protected]>Please use spaces for indentation
Quoted 8 lines
components/xen | 10 ++++++++++ 1 file changed, 10 insertions(+)components/xen +0
-0components/xen function xen_check_package() { · line 13
Quoted 7 lines
components/xen +2
-1@@ -8,6 +8,11 @@ function xen_check_package() { local DEP_Debian_common="build-essential python-dev gettext uuid -dev \ libncurses5-dev libyajl-dev libaio-dev pkg-config libglib2.0-dev \ libssl-dev libpixman-1-dev bridge-utils wget" + + if [[ -e "/usr/lib/systemd" ]]I don't know much about systemd but isn't there a better way to detect systemd? Check if it is running for example?
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines
You might want to build with systemd support even if systemd isn't actually the current init system the system was booted with?
That is possible but also the vice versa might be true: one might want to build without systemd even if systemd is running. Maybe we need some kind of variable that can be overridden by the user?
You mean like
XEN_CONFIG_EXTRA? :-D
Actually I was thinking of something more specific like:
if [[ -z "$WITH_SYSTEMD" ]]
then
if check-package systemd
then
WITH_SYSTEMD=y
else
WITH_SYSTEMD=n
fi
fi
so that people that don't want systemd but they have it installed for some reasons, they can export WITH_SYSTEMD=n and from raisin point of view we are not cluttering the interface too much. But I am also OK with just enable systemd if it is installed and not enable it if it is not.
Quoted 8 lines
For people frobbing around with
XEN_CONFIG_EXTRA, I think it's reasonable for them to get a build error if they add --with-systemd but don't have the requisite packages. (I'm pretty sure that's what will happen now, at any rate.)Since I'm going to be checking for systemd packages anyway due to the container issue, maybe it would just make sense to include the dep automatically only if the systemd packages are installed.
I agree, that works and it is simple.
Quoted 7 lines
Alternately, I suppose we could extend the check-package "syntax" to have "if package X in stalled, add dependency Y" -- similar to the '|' operator we added earlier. Then we could do something like this:
systemd:systemd-devel systemd-container:systemd-container-devel
What do you think?
I would prefer to avoid it unless strictly necessary.
PATCH 3/5 raisin: Allow iasl to alias acpica-tools, unify Fedora and CentOS deps for xen
In reply to George DunlapCentOS 7 now aliases acpica-tools instead of iasl, making its deps essentially the same as Fedora. Add iasl|acpica-tools as an alias in the Fedora deps, and make the CentOS deps a straight clone of the Fedora deps (as they are for the other components).
--- components/xen | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
components/xen +3 -3
@@ -25,12 +25,12 @@ function xen_check_package() { then DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" fi - local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 acpica-tools texinfo" + local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 iasl|acpica-tools texinfo" local DEP_Fedora_x86_64="$DEP_Fedora_x86_32 glibc-devel.i686" local DEP_CentOS_common="$DEP_Fedora_common" - local DEP_CentOS_x86_32="$DEP_CentOS_common dev86 texinfo iasl" - local DEP_CentOS_x86_64="$DEP_CentOS_x86_32 glibc-devel.i686" + local DEP_CentOS_x86_32="$DEP_Fedora_x86_32" + local DEP_CentOS_x86_64="$DEP_Fedora_x86_64" verbose_echo Checking Xen dependencies
Signature · 1 line
2.1.4
Re: [PATCH 3/5] raisin: Allow iasl to alias acpica-tools, unify Fedora and CentOS deps for xen
Quoted 6 lines · George Dunlap
CentOS 7 now aliases acpica-tools instead of iasl, making its deps essentially the same as Fedora. Add iasl|acpica-tools as an alias in the Fedora deps, and make the CentOS deps a straight clone of the Fedora deps (as they are for the other components).
Signed-off-by George Dunlap <[email protected]>
Quoted 26 lines
components/xen | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)components/xen +3
-3@@ -25,12 +25,12 @@ function xen_check_package() { then DEP_Fedora_common="$DEP_Fedora_common systemd-devel|systemd-container-devel" fi - local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 acpica-tools texinfo" + local DEP_Fedora_x86_32="$DEP_Fedora_common dev86 iasl|acpica-tools texinfo" local DEP_Fedora_x86_64="$DEP_Fedora_x86_32 glibc-devel.i686" local DEP_CentOS_common="$DEP_Fedora_common" - local DEP_CentOS_x86_32="$DEP_CentOS_common dev86 texinfo iasl" - local DEP_CentOS_x86_64="$DEP_CentOS_x86_32 glibc-devel.i686" + local DEP_CentOS_x86_32="$DEP_Fedora_x86_32" + local DEP_CentOS_x86_64="$DEP_Fedora_x86_64" verbose_echo Checking Xen dependenciesSignature · 1 line
2.1.4
PATCH 4/5 raisin: Change update/release parsing OSes
In reply to George DunlapAt the moment, something like 7.1.1503 will be parsed as RELEASE=7.1 UPDATE=1503. Change the bash string so that RELEASE=7 UPDATE=1.1503 in this case.
Also add an example CentOS 7 release string, and add the RELEASE / UPDATE parsing to lsb_release as well.
--- lib/common-functions.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)
lib/common-functions.sh +5 -3
@@ -103,13 +103,15 @@ function get_distro() { os_VENDOR=`lsb_release -i -s` os_RELEASE=`lsb_release -r -s` os_CODENAME=`lsb_release -c -s` - os_UPDATE="" + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} elif [[ -r /etc/redhat-release ]] then # Red Hat Enterprise Linux Server release 5.5 (Tikanga) # Red Hat Enterprise Linux Server release 7.0 Beta (Maipo) # CentOS release 5.5 (Final) # CentOS Linux release 6.0 (Final) + # CentOS Linux release 7.1.1503 (Core) # Fedora release 16 (Verne) # XenServer release 6.2.0-70446c (xenenterprise) os_CODENAME=""
@@ -120,8 +122,8 @@ function get_distro() { ver=`sed -e 's/^.* \([0-9].*\) (\(.*\)).*$/\1\|\2/' /etc/redhat-release` os_CODENAME=${ver#*|} os_RELEASE=${ver%|*} - os_UPDATE=${os_RELEASE##*.} - os_RELEASE=${os_RELEASE%.*} + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} break fi done
Signature · 1 line
2.1.4
Re: [PATCH 4/5] raisin: Change update/release parsing OSes
Quoted 34 lines · George Dunlap
At the moment, something like 7.1.1503 will be parsed as RELEASE=7.1 UPDATE=1503. Change the bash string so that RELEASE=7 UPDATE=1.1503 in this case.
Also add an example CentOS 7 release string, and add the RELEASE / UPDATE parsing to
lsb_releaseas well.Signed-off-by George Dunlap <[email protected]>--- lib/common-functions.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)lib/common-functions.sh +3
-1@@ -103,13 +103,15 @@ function get_distro() { os_VENDOR=`lsb_release -i -s` os_RELEASE=`lsb_release -r -s` os_CODENAME=`lsb_release -c -s` - os_UPDATE="" + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} elif [[ -r /etc/redhat-release ]] then # Red Hat Enterprise Linux Server release 5.5 (Tikanga) # Red Hat Enterprise Linux Server release 7.0 Beta (Maipo) # CentOS release 5.5 (Final) # CentOS Linux release 6.0 (Final) + # CentOS Linux release 7.1.1503 (Core) # Fedora release 16 (Verne) # XenServer release 6.2.0-70446c (xenenterprise) os_CODENAME=""
lib/common-functions.sh function get_distro() { · line 127
Quoted 8 lines
lib/common-functions.sh +2
-2@@ -120,8 +122,8 @@ function get_distro() { ver=`sed -e 's/^.* \([0-9].*\) (\(.*\)).*$/\1\|\2/' /etc/redhat-release` os_CODENAME=${ver#*|} os_RELEASE=${ver%|*} - os_UPDATE=${os_RELEASE##*.} - os_RELEASE=${os_RELEASE%.*} + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} break
This change is OK, but I don't know if this is what we want for the other case above. I would be tempted to leave the lsb_release case as is.
Re: [PATCH 4/5] raisin: Change update/release parsing OSes
Quoted 39 lines · Stefano Stabellini
Quoted 38 lines · George Dunlap
At the moment, something like 7.1.1503 will be parsed as RELEASE=7.1 UPDATE=1503. Change the bash string so that RELEASE=7 UPDATE=1.1503 in this case.
Also add an example CentOS 7 release string, and add the RELEASE / UPDATE parsing to
lsb_releaseas well.Signed-off-by George Dunlap <[email protected]>--- lib/common-functions.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)lib/common-functions.sh +3
-2@@ -103,13 +103,15 @@ function get_distro() { os_VENDOR=`lsb_release -i -s` os_RELEASE=`lsb_release -r -s` os_CODENAME=`lsb_release -c -s` - os_UPDATE="" + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} elif [[ -r /etc/redhat-release ]] then # Red Hat Enterprise Linux Server release 5.5 (Tikanga) # Red Hat Enterprise Linux Server release 7.0 Beta (Maipo) # CentOS release 5.5 (Final) # CentOS Linux release 6.0 (Final) + # CentOS Linux release 7.1.1503 (Core) # Fedora release 16 (Verne) # XenServer release 6.2.0-70446c (xenenterprise) os_CODENAME=""@@ -120,8 +122,8 @@ function get_distro() { ver=`sed -e 's/^.* \([0-9].*\) (\(.*\)).*$/\1\|\2/' /etc/redhat-release` os_CODENAME=${ver#*|} os_RELEASE=${ver%|*} - os_UPDATE=${os_RELEASE##*.}
Quoted 8 lines
lib/common-functions.sh function get_distro() { · line 127
Quoted 4 lines
lib/common-functions.sh +2
-1- os_RELEASE=${os_RELEASE%.*} + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} breakThis change is OK, but I don't know if this is what we want for the other case above. I would be tempted to leave the
lsb_releasecase as is.
?
Don't we want the resulting state of "get_distro()" to work the same whether you have lsb_release installed or not?
I wrote this patch quite a while ago, but I'm pretty sure that I tested it with the lsb package installed and not installed for C7 (and maybe C6 as well) and with this patch I got the same results.
(Or to put it a different way: The only reason I even modified the lsb_release section is because I installed the lsb package and got strange results.)
-George
Re: [PATCH 4/5] raisin: Change update/release parsing OSes
Quoted 54 lines · George Dunlap
Quoted 39 lines · Stefano Stabellini
Quoted 38 lines · George Dunlap
At the moment, something like 7.1.1503 will be parsed as RELEASE=7.1 UPDATE=1503. Change the bash string so that RELEASE=7 UPDATE=1.1503 in this case.
Also add an example CentOS 7 release string, and add the RELEASE / UPDATE parsing to
lsb_releaseas well.Signed-off-by George Dunlap <[email protected]>--- lib/common-functions.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)lib/common-functions.sh +3
-2@@ -103,13 +103,15 @@ function get_distro() { os_VENDOR=`lsb_release -i -s` os_RELEASE=`lsb_release -r -s` os_CODENAME=`lsb_release -c -s` - os_UPDATE="" + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} elif [[ -r /etc/redhat-release ]] then # Red Hat Enterprise Linux Server release 5.5 (Tikanga) # Red Hat Enterprise Linux Server release 7.0 Beta (Maipo) # CentOS release 5.5 (Final) # CentOS Linux release 6.0 (Final) + # CentOS Linux release 7.1.1503 (Core) # Fedora release 16 (Verne) # XenServer release 6.2.0-70446c (xenenterprise) os_CODENAME=""@@ -120,8 +122,8 @@ function get_distro() { ver=`sed -e 's/^.* \([0-9].*\) (\(.*\)).*$/\1\|\2/' /etc/redhat-release` os_CODENAME=${ver#*|} os_RELEASE=${ver%|*} - os_UPDATE=${os_RELEASE##*.}Quoted 8 lines
lib/common-functions.sh function get_distro() { · line 127
Quoted 4 lines
lib/common-functions.sh +2
-1- os_RELEASE=${os_RELEASE%.*} + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} breakThis change is OK, but I don't know if this is what we want for the other case above. I would be tempted to leave the
lsb_releasecase as is.?
Don't we want the resulting state of "
get_distro()" to work the same whether you havelsb_releaseinstalled or not?
Quoted 7 lines
I wrote this patch quite a while ago, but I'm pretty sure that I tested it with the lsb package installed and not installed for C7 (and maybe C6 as well) and with this patch I got the same results.
(Or to put it a different way: The only reason I even modified the
lsb_releasesection is because I installed the lsb package and got strange results.)
The problem is that the lsb_release change would affect other distros too. For example on Ubuntu, I get
sstabellini@kaball:~$ lsb_release -r -s 12.04
with the current scheme:
os_RELEASE=12.04
os_UPDATE=""
with the new scheme:
os_RELEASE=12
os_UPDATE=04
I don't think that's what we want: os_RELEASE should be the output of lsb_release -r -s, after all -r stands for "release". What do you think?
But maybe if there are two dots in the release number then you can extract the last number and that could be the update. For example, if
sstabellini@kaball:~$ lsb_release -r -s 12.04.1
then I guess it could make sense to set os_RELEASE=12.04 and os_UPDATE=1. Similarly for CentOS if lsb_release -r -s returns "7.1.1503", then we could set os_RELEASE=7.1 and os_UPDATE=1503. Would that be good enough?
Re: [PATCH 4/5] raisin: Change update/release parsing OSes
Quoted 85 lines · Stefano Stabellini
Quoted 54 lines · George Dunlap
Quoted 39 lines · Stefano Stabellini
Quoted 38 lines · George Dunlap
At the moment, something like 7.1.1503 will be parsed as RELEASE=7.1 UPDATE=1503. Change the bash string so that RELEASE=7 UPDATE=1.1503 in this case.
Also add an example CentOS 7 release string, and add the RELEASE / UPDATE parsing to
lsb_releaseas well.Signed-off-by George Dunlap <[email protected]>--- lib/common-functions.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)lib/common-functions.sh +3
-2@@ -103,13 +103,15 @@ function get_distro() { os_VENDOR=`lsb_release -i -s` os_RELEASE=`lsb_release -r -s` os_CODENAME=`lsb_release -c -s` - os_UPDATE="" + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} elif [[ -r /etc/redhat-release ]] then # Red Hat Enterprise Linux Server release 5.5 (Tikanga) # Red Hat Enterprise Linux Server release 7.0 Beta (Maipo) # CentOS release 5.5 (Final) # CentOS Linux release 6.0 (Final) + # CentOS Linux release 7.1.1503 (Core) # Fedora release 16 (Verne) # XenServer release 6.2.0-70446c (xenenterprise) os_CODENAME=""@@ -120,8 +122,8 @@ function get_distro() { ver=`sed -e 's/^.* \([0-9].*\) (\(.*\)).*$/\1\|\2/' /etc/redhat-release` os_CODENAME=${ver#*|} os_RELEASE=${ver%|*} - os_UPDATE=${os_RELEASE##*.}Quoted 8 lines
lib/common-functions.sh function get_distro() { · line 127
Quoted 4 lines
lib/common-functions.sh +2
-1- os_RELEASE=${os_RELEASE%.*} + os_UPDATE=${os_RELEASE#*.} + os_RELEASE=${os_RELEASE%%.*} breakThis change is OK, but I don't know if this is what we want for the other case above. I would be tempted to leave the
lsb_releasecase as is.?
Don't we want the resulting state of "
get_distro()" to work the same whether you havelsb_releaseinstalled or not?Quoted 7 lines
I wrote this patch quite a while ago, but I'm pretty sure that I tested it with the lsb package installed and not installed for C7 (and maybe C6 as well) and with this patch I got the same results.
(Or to put it a different way: The only reason I even modified the
lsb_releasesection is because I installed the lsb package and got strange results.)The problem is that the
lsb_releasechange would affect other distros too. For example on Ubuntu, I getsstabellini@kaball:~$ lsb_release -r -s 12.04with the current scheme:
os_RELEASE=12.04
os_UPDATE=""with the new scheme:
os_RELEASE=12
os_UPDATE=04I don't think that's what we want:
os_RELEASEshould be the output oflsb_release-r -s, after all -r stands for "release". What do you think?But maybe if there are two dots in the release number then you can extract the last number and that could be the update. For example, if
Quoted 6 lines
sstabellini@kaball:~$ lsb_release -r -s 12.04.1then I guess it could make sense to set os_RELEASE=12.04 and os_UPDATE=1. Similarly for CentOS if
lsb_release-r -s returns "7.1.1503", then we could set os_RELEASE=7.1 and os_UPDATE=1503. Would that be good enough?
So the reason I wanted os_RELEASE in this case to be "7" or "6" was because of the package rename issue with iasl|acpica-tools. But actually I've solved that using the "aliases" patch now (see 3/5), so in fact I don't think anyone is using this information anymore.
So maybe I'll just drop this patch for now and we can sort things out when we actually need it. :-)
-George
PATCH 5/5 raisin: Add XEN_CONFIG_EXTRA to config file
In reply to George DunlapAllowing the user to enable or disable specific functionality, such as stubdoms.
--- components/xen | 2 +- configs/config-4.5 | 4 ++++ configs/config-4.6 | 4 ++++ configs/config-master | 4 ++++ 4 files changed, 13 insertions(+), 1 deletion(-)
components/xen +1 -1
@@ -53,7 +53,7 @@ function xen_build() { ovmf_opt="--enable-ovmf --with-system-ovmf="$BASEDIR"/ovmf-dir/ovmf.bin" fi ./configure --prefix=$PREFIX --with-system-qemu=$PREFIX/lib/xen/bin/qemu-system-i386 \ - --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt + --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt $XEN_CONFIG_EXTRA $RAISIN_MAKE $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"
configs/config-4.5 +4 -0
@@ -41,6 +41,10 @@ LIBVIRT_REVISION="origin/xen-tested-master" OVMF_REVISION="cb9a7ebabcd6b8a49dc0854b2f9592d732b5afbd" LINUX_REVISION="master" +# Per-project options +## Passed to "./configure" when building Xen. Use to enable or disable specific features +# XEN_CONFIG_EXTRA="--disable-stubdom" + # Tests ## All tests: busybox-pv busybox-hvm ## ENABLED_TESTS is the list of test run by raise test
configs/config-4.6 +4 -0
@@ -41,6 +41,10 @@ LIBVIRT_REVISION="origin/xen-tested-master" OVMF_REVISION="cb9a7ebabcd6b8a49dc0854b2f9592d732b5afbd" LINUX_REVISION="master" +# Per-project options +## Passed to "./configure" when building Xen. Use to enable or disable specific features +# XEN_CONFIG_EXTRA="--disable-stubdom" + # Tests ## All tests: busybox-pv busybox-hvm ## ENABLED_TESTS is the list of test run by raise test
configs/config-master +4 -0
@@ -40,6 +40,10 @@ LIBVIRT_REVISION="origin/xen-tested-master" OVMF_REVISION="origin/xen-tested-master" LINUX_REVISION="master" +# Per-project options +## Passed to "./configure" when building Xen. Use to enable or disable specific features +# XEN_CONFIG_EXTRA="--disable-stubdom" + # Tests ## All tests: busybox-pv busybox-hvm ## ENABLED_TESTS is the list of test run by raise test
Signature · 1 line
2.1.4
Re: [PATCH 5/5] raisin: Add XEN_CONFIG_EXTRA to config file
Quoted 4 lines · George Dunlap
Allowing the user to enable or disable specific functionality, such as stubdoms.
Signed-off-by George Dunlap <[email protected]>
I don't like this very much: if we want to disable stubdoms by default with all configs, then I would prefer to simply add --disable-stubdom to components/xen without introducing XEN_CONFIG_EXTRA.
Otherwise if we want to give users the chance to add an extra config option, I would introduce a generic way to do that, so that people can use it with any components they want, QEMU, libvirt, etc.
Quoted 67 lines
components/xen | 2 +- configs/config-4.5 | 4 ++++ configs/config-4.6 | 4 ++++ configs/config-master | 4 ++++ 4 files changed, 13 insertions(+), 1 deletion(-)components/xen +1
-1@@ -53,7 +53,7 @@ function xen_build() { ovmf_opt="--enable-ovmf --with-system-ovmf="$BASEDIR"/ovmf-dir/ovmf.bin" fi ./configure --prefix=$PREFIX --with-system-qemu=$PREFIX/lib/xen/bin/qemu-system-i386 \ - --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt + --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt $XEN_CONFIG_EXTRA $RAISIN_MAKE $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"configs/config-4.5 +4
-0@@ -41,6 +41,10 @@ LIBVIRT_REVISION="origin/xen-tested-master" OVMF_REVISION="cb9a7ebabcd6b8a49dc0854b2f9592d732b5afbd" LINUX_REVISION="master" +# Per-project options +## Passed to "./configure" when building Xen. Use to enable or disable specific features +# XEN_CONFIG_EXTRA="--disable-stubdom" + # Tests ## All tests: busybox-pv busybox-hvm ## ENABLED_TESTS is the list of test run by raise testconfigs/config-4.6 +4
-0@@ -41,6 +41,10 @@ LIBVIRT_REVISION="origin/xen-tested-master" OVMF_REVISION="cb9a7ebabcd6b8a49dc0854b2f9592d732b5afbd" LINUX_REVISION="master" +# Per-project options +## Passed to "./configure" when building Xen. Use to enable or disable specific features +# XEN_CONFIG_EXTRA="--disable-stubdom" + # Tests ## All tests: busybox-pv busybox-hvm ## ENABLED_TESTS is the list of test run by raise testconfigs/config-master +4
-0@@ -40,6 +40,10 @@ LIBVIRT_REVISION="origin/xen-tested-master" OVMF_REVISION="origin/xen-tested-master" LINUX_REVISION="master" +# Per-project options +## Passed to "./configure" when building Xen. Use to enable or disable specific features +# XEN_CONFIG_EXTRA="--disable-stubdom" + # Tests ## All tests: busybox-pv busybox-hvm ## ENABLED_TESTS is the list of test run by raise testSignature · 1 line
2.1.4
Re: [PATCH 5/5] raisin: Add XEN_CONFIG_EXTRA to config file
Quoted 6 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Allowing the user to enable or disable specific functionality, such as stubdoms.
Signed-off-by George Dunlap <[email protected]>
Quoted 7 lines
I don't like this very much: if we want to disable stubdoms by default with all configs, then I would prefer to simply add --disable-stubdom to components/xen without introducing
XEN_CONFIG_EXTRA.Otherwise if we want to give users the chance to add an extra config option, I would introduce a generic way to do that, so that people can use it with any components they want, QEMU, libvirt, etc.
You did notice that this config option is disabled by default, right? I added the line commented-out as an example of the sort of thing you might want to do.
I don't think we want to disable stubdoms by default across the board.
I wouldn't object to adding empty config variables to the other components; I just don't have a good way to test them at the moment.
-George
Re: [PATCH 5/5] raisin: Add XEN_CONFIG_EXTRA to config file
Quoted 15 lines · George Dunlap
Quoted 6 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Allowing the user to enable or disable specific functionality, such as stubdoms.
Signed-off-by George Dunlap <[email protected]>Quoted 7 lines
I don't like this very much: if we want to disable stubdoms by default with all configs, then I would prefer to simply add --disable-stubdom to components/xen without introducing
XEN_CONFIG_EXTRA.Otherwise if we want to give users the chance to add an extra config option, I would introduce a generic way to do that, so that people can use it with any components they want, QEMU, libvirt, etc.
Quoted 8 lines
You did notice that this config option is disabled by default, right? I added the line commented-out as an example of the sort of thing you might want to do.
I don't think we want to disable stubdoms by default across the board.
I wouldn't object to adding empty config variables to the other components; I just don't have a good way to test them at the moment.
What if we just add an environmental variable named as COMPONENT_BUILD_CONFIGURE at the end of the configure line when appropriate? Of course it would need to be documented in the README.
Something like:
components/qemu +1 -1
@@ -27,7 +27,7 @@ function qemu_build() { --disable-docs \ --bindir=$PREFIX/lib/xen/bin \ --datadir=$PREFIX/share/qemu-xen \ - --disable-guest-agent + --disable-guest-agent $QEMU_BUILD_CONFIGURE $RAISIN_MAKE all $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"
components/xen +1 -1
@@ -39,7 +39,7 @@ function xen_build() { ovmf_opt="--enable-ovmf --with-system-ovmf="$BASEDIR"/ovmf-dir/ovmf.bin" fi ./configure --prefix=$PREFIX --with-system-qemu=$PREFIX/lib/xen/bin/qemu-system-i386 \ - --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt + --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt $XEN_BUILD_CONFIGURE $RAISIN_MAKE $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"
Re: [PATCH 5/5] raisin: Add XEN_CONFIG_EXTRA to config file
Quoted 20 lines · Stefano Stabellini
Quoted 19 lines · George Dunlap
Quoted 6 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Allowing the user to enable or disable specific functionality, such as stubdoms.
Signed-off-by George Dunlap <[email protected]>Quoted 7 lines
I don't like this very much: if we want to disable stubdoms by default with all configs, then I would prefer to simply add --disable-stubdom to components/xen without introducing
XEN_CONFIG_EXTRA.Otherwise if we want to give users the chance to add an extra config option, I would introduce a generic way to do that, so that people can use it with any components they want, QEMU, libvirt, etc.
You did notice that this config option is disabled by default, right? I added the line commented-out as an example of the sort of thing you might want to do.
Quoted 8 lines
Quoted 4 lines
I don't think we want to disable stubdoms by default across the board.
I wouldn't object to adding empty config variables to the other components; I just don't have a good way to test them at the moment.
What if we just add an environmental variable named as
COMPONENT_BUILD_CONFIGUREat the end of the configure line when appropriate? Of course it would need to be documented in the README.
Isn't this exactly the same as my patch, but
1) With a different name, and
2) No examples in the config files?
I don't mind #1, but #2 seems like the most logical place to document it.
-George
Quoted 31 lines
Something like:
components/qemu +1
-1@@ -27,7 +27,7 @@ function qemu_build() { --disable-docs \ --bindir=$PREFIX/lib/xen/bin \ --datadir=$PREFIX/share/qemu-xen \ - --disable-guest-agent + --disable-guest-agent $QEMU_BUILD_CONFIGURE $RAISIN_MAKE all $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"components/xen +1
-1@@ -39,7 +39,7 @@ function xen_build() { ovmf_opt="--enable-ovmf --with-system-ovmf="$BASEDIR"/ovmf-dir/ovmf.bin" fi ./configure --prefix=$PREFIX --with-system-qemu=$PREFIX/lib/xen/bin/qemu-system-i386 \ - --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt + --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt $XEN_BUILD_CONFIGURE $RAISIN_MAKE $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"
Re: [PATCH 5/5] raisin: Add XEN_CONFIG_EXTRA to config file
Quoted 30 lines · George Dunlap
Quoted 20 lines · Stefano Stabellini
Quoted 19 lines · George Dunlap
Quoted 6 lines · Stefano Stabellini
Quoted 4 lines · George Dunlap
Allowing the user to enable or disable specific functionality, such as stubdoms.
Signed-off-by George Dunlap <[email protected]>Quoted 7 lines
I don't like this very much: if we want to disable stubdoms by default with all configs, then I would prefer to simply add --disable-stubdom to components/xen without introducing
XEN_CONFIG_EXTRA.Otherwise if we want to give users the chance to add an extra config option, I would introduce a generic way to do that, so that people can use it with any components they want, QEMU, libvirt, etc.
You did notice that this config option is disabled by default, right? I added the line commented-out as an example of the sort of thing you might want to do.
Quoted 8 lines
Quoted 4 lines
I don't think we want to disable stubdoms by default across the board.
I wouldn't object to adding empty config variables to the other components; I just don't have a good way to test them at the moment.
What if we just add an environmental variable named as
COMPONENT_BUILD_CONFIGUREat the end of the configure line when appropriate? Of course it would need to be documented in the README.
Quoted 5 lines
Isn't this exactly the same as my patch, but
1) With a different name, and
2) No examples in the config files?I don't mind #1, but #2 seems like the most logical place to document it.
OK :-)
Please don't make it xen specific though.
Quoted 33 lines
Quoted 32 lines
Something like:
components/qemu +1
-1@@ -27,7 +27,7 @@ function qemu_build() { --disable-docs \ --bindir=$PREFIX/lib/xen/bin \ --datadir=$PREFIX/share/qemu-xen \ - --disable-guest-agent + --disable-guest-agent $QEMU_BUILD_CONFIGURE $RAISIN_MAKE all $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"components/xen +1
-1@@ -39,7 +39,7 @@ function xen_build() { ovmf_opt="--enable-ovmf --with-system-ovmf="$BASEDIR"/ovmf-dir/ovmf.bin" fi ./configure --prefix=$PREFIX --with-system-qemu=$PREFIX/lib/xen/bin/qemu-system-i386 \ - --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt + --disable-qemu-traditional --enable-rombios $seabios_opt $ovmf_opt $XEN_BUILD_CONFIGURE $RAISIN_MAKE $RAISIN_MAKE install DESTDIR="$INST_DIR" cd "$BASEDIR"