
On Mon, Oct 02, 2017 at 05:10:43PM +0200, Andrea Bolognani wrote:
Signed-off-by: Andrea Bolognani <abologna@redhat.com> --- ansible/host_vars/libvirt-centos-6/main.yml | 1 + ansible/host_vars/libvirt-centos-7/main.yml | 1 + ansible/host_vars/libvirt-fedora-25/main.yml | 1 + ansible/host_vars/libvirt-fedora-26/main.yml | 1 + ansible/host_vars/libvirt-fedora-rawhide/main.yml | 1 + ansible/tasks/build.yml | 19 +++++++++++++++---- ansible/tasks/packages.yml | 11 +++++++++++ ansible/vars/libvirt-cim/CentOS-6.yml | 11 +++++++++++ ansible/vars/libvirt-cim/CentOS-7.yml | 11 +++++++++++ ansible/vars/libvirt-cim/Fedora-25.yml | 11 +++++++++++ ansible/vars/libvirt-cim/Fedora-26.yml | 11 +++++++++++ ansible/vars/libvirt-cim/Fedora-Rawhide.yml | 11 +++++++++++ 12 files changed, 86 insertions(+), 4 deletions(-) create mode 100644 ansible/vars/libvirt-cim/CentOS-6.yml create mode 100644 ansible/vars/libvirt-cim/CentOS-7.yml create mode 100644 ansible/vars/libvirt-cim/Fedora-25.yml create mode 100644 ansible/vars/libvirt-cim/Fedora-26.yml create mode 100644 ansible/vars/libvirt-cim/Fedora-Rawhide.yml
diff --git a/ansible/host_vars/libvirt-centos-6/main.yml b/ansible/host_vars/libvirt-centos-6/main.yml index 4d53bb3..f6fe574 100644 --- a/ansible/host_vars/libvirt-centos-6/main.yml +++ b/ansible/host_vars/libvirt-centos-6/main.yml @@ -2,3 +2,4 @@ projects: - base - libvirt + - libvirt-cim diff --git a/ansible/host_vars/libvirt-centos-7/main.yml b/ansible/host_vars/libvirt-centos-7/main.yml index 7508f19..ec2e50f 100644 --- a/ansible/host_vars/libvirt-centos-7/main.yml +++ b/ansible/host_vars/libvirt-centos-7/main.yml @@ -3,3 +3,4 @@ projects: - base - libosinfo - libvirt + - libvirt-cim diff --git a/ansible/host_vars/libvirt-fedora-25/main.yml b/ansible/host_vars/libvirt-fedora-25/main.yml index 7508f19..ec2e50f 100644 --- a/ansible/host_vars/libvirt-fedora-25/main.yml +++ b/ansible/host_vars/libvirt-fedora-25/main.yml @@ -3,3 +3,4 @@ projects: - base - libosinfo - libvirt + - libvirt-cim diff --git a/ansible/host_vars/libvirt-fedora-26/main.yml b/ansible/host_vars/libvirt-fedora-26/main.yml index 7508f19..ec2e50f 100644 --- a/ansible/host_vars/libvirt-fedora-26/main.yml +++ b/ansible/host_vars/libvirt-fedora-26/main.yml @@ -3,3 +3,4 @@ projects: - base - libosinfo - libvirt + - libvirt-cim diff --git a/ansible/host_vars/libvirt-fedora-rawhide/main.yml b/ansible/host_vars/libvirt-fedora-rawhide/main.yml index 7508f19..ec2e50f 100644 --- a/ansible/host_vars/libvirt-fedora-rawhide/main.yml +++ b/ansible/host_vars/libvirt-fedora-rawhide/main.yml @@ -3,3 +3,4 @@ projects: - base - libosinfo - libvirt + - libvirt-cim diff --git a/ansible/tasks/build.yml b/ansible/tasks/build.yml index be9ecd3..2a26024 100644 --- a/ansible/tasks/build.yml +++ b/ansible/tasks/build.yml @@ -38,7 +38,15 @@ environment: when: - ( project == 'libosinfo' or - project == 'libvirt' ) + project == 'libvirt' or + project == 'libvirt-cim' ) + +- name: '{{ project }}: Run configure' + command: './configure {{ configure_options }}' + args: + chdir: '{{ project }}' + when: + - project == 'libvirt-cim'
- name: '{{ project }}: Build project' command: '{{ make }} -j{{ smp }}' @@ -46,7 +54,8 @@ chdir: '{{ project }}' when: - ( project == 'libosinfo' or - project == 'libvirt' ) + project == 'libvirt' or + project == 'libvirt-cim' )
- name: '{{ project }}: Run sanity checks' command: '{{ make }} -j{{ smp }} syntax-check' @@ -63,7 +72,8 @@ chdir: '{{ project }}' when: - ( ( project == 'libvirt' and - os_name != 'FreeBSD' ) ) + os_name != 'FreeBSD' ) or + project == 'libvirt-cim' )
- name: '{{ project }}: Build RPM package' command: '{{ make }} -j{{ smp }} rpm' @@ -72,4 +82,5 @@ when: - ( os_name == 'CentOS' or os_name == 'Fedora' ) - - ( project == 'libvirt' ) + - ( project == 'libvirt' or + project == 'libvirt-cim' ) diff --git a/ansible/tasks/packages.yml b/ansible/tasks/packages.yml index 630d794..7a66899 100644 --- a/ansible/tasks/packages.yml +++ b/ansible/tasks/packages.yml @@ -9,3 +9,14 @@ state: present with_items: '{{ packages }}' + +- name: '{{ project }}: Install extra packages' + package: + name: '{{ item }}' + state: present + with_items: + '{{ extra_packages }}' + when: + - extra_packages is defined + # Only extra additional packages if we're going to build later on + - build diff --git a/ansible/vars/libvirt-cim/CentOS-6.yml b/ansible/vars/libvirt-cim/CentOS-6.yml new file mode 100644 index 0000000..8ff80c1 --- /dev/null +++ b/ansible/vars/libvirt-cim/CentOS-6.yml @@ -0,0 +1,11 @@ +--- +packages: + - libcmpiutil-devel + - libconfig-devel + - libuuid-devel + - libxml2-devel + - libxslt + - wget + +extra_packages: + - libvirt-devel
This isn't right - we should never install libvirt-devel on any of the build hosts. Downstream projects are chained up to build against the version of libvirt we just built. The same applies for other deps we build that are used by other downstream pieces. Is there any way to get inheritance between these 'vars' files, so we don't copy+paste the same content for every Fedora/CentOS version ? Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|