mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-22 04:25:18 +00:00
rpm: convert mingw spec to meson
The meson build system is configured to only ever build shared libraries, so we delete the -static sub-RPMs. The few driver conditionals are deleted as there was never any scenario in which their value changed. Reviewed-by: Michal Privoznik <mprivozn@redhat.com> Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
parent
4ac265173c
commit
d251129b36
@ -11,26 +11,6 @@
|
|||||||
%define supported_platform 0
|
%define supported_platform 0
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# Default to skipping autoreconf. Distros can change just this one line
|
|
||||||
# (or provide a command-line override) if they backport any patches that
|
|
||||||
# touch configure.ac or Makefile.am.
|
|
||||||
%{!?enable_autotools:%define enable_autotools 0}
|
|
||||||
|
|
||||||
# The mingw build is client only. Set up defaults for hypervisor drivers
|
|
||||||
# that talk via a native remote protocol, and for which prereq mingw
|
|
||||||
# libraries exist.
|
|
||||||
%define with_esx 0%{!?_without_esx:1}
|
|
||||||
# missing libwsman, so can't build hyper-v
|
|
||||||
%define with_hyperv 0%{!?_without_hyperv:0}
|
|
||||||
%define with_xenapi 0%{!?_without_xenapi:1}
|
|
||||||
%define with_vz 0%{!?_without_vz:0}
|
|
||||||
|
|
||||||
# RHEL ships ESX but not PowerHypervisor, HyperV, or libxenserver (xenapi)
|
|
||||||
%if 0%{?rhel}
|
|
||||||
%define with_xenapi 0
|
|
||||||
%define with_hyperv 0
|
|
||||||
%endif
|
|
||||||
|
|
||||||
Name: mingw-libvirt
|
Name: mingw-libvirt
|
||||||
Version: @VERSION@
|
Version: @VERSION@
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
@ -74,20 +54,15 @@ BuildRequires: libxslt
|
|||||||
BuildRequires: python3
|
BuildRequires: python3
|
||||||
BuildRequires: perl-interpreter
|
BuildRequires: perl-interpreter
|
||||||
BuildRequires: perl(Getopt::Long)
|
BuildRequires: perl(Getopt::Long)
|
||||||
%if 0%{?enable_autotools}
|
BuildRequires: make
|
||||||
BuildRequires: autoconf
|
BuildRequires: meson
|
||||||
BuildRequires: automake
|
BuildRequires: ninja-build
|
||||||
BuildRequires: gettext-devel
|
|
||||||
BuildRequires: libtool
|
|
||||||
%endif
|
|
||||||
BuildRequires: python3-docutils
|
BuildRequires: python3-docutils
|
||||||
|
|
||||||
BuildRequires: mingw32-libssh2
|
BuildRequires: mingw32-libssh2
|
||||||
BuildRequires: mingw64-libssh2
|
BuildRequires: mingw64-libssh2
|
||||||
%if %{with_esx}
|
|
||||||
BuildRequires: mingw32-curl
|
BuildRequires: mingw32-curl
|
||||||
BuildRequires: mingw64-curl
|
BuildRequires: mingw64-curl
|
||||||
%endif
|
|
||||||
BuildRequires: cpp
|
BuildRequires: cpp
|
||||||
%if 0%{?fedora} || 0%{?rhel} > 7
|
%if 0%{?fedora} || 0%{?rhel} > 7
|
||||||
BuildRequires: rpcgen
|
BuildRequires: rpcgen
|
||||||
@ -101,31 +76,19 @@ MinGW Windows libvirt virtualization library.
|
|||||||
# Mingw32
|
# Mingw32
|
||||||
%package -n mingw32-libvirt
|
%package -n mingw32-libvirt
|
||||||
Summary: %{summary}
|
Summary: %{summary}
|
||||||
|
Obsoletes: mingw32-libvirt < 7.0.0
|
||||||
|
|
||||||
%description -n mingw32-libvirt
|
%description -n mingw32-libvirt
|
||||||
MinGW Windows libvirt virtualization library.
|
MinGW Windows libvirt virtualization library.
|
||||||
|
|
||||||
%package -n mingw32-libvirt-static
|
|
||||||
Summary: %{summary}
|
|
||||||
Requires: mingw32-libvirt = %{version}-%{release}
|
|
||||||
|
|
||||||
%description -n mingw32-libvirt-static
|
|
||||||
MinGW Windows libvirt virtualization library, static version.
|
|
||||||
|
|
||||||
# Mingw64
|
# Mingw64
|
||||||
%package -n mingw64-libvirt
|
%package -n mingw64-libvirt
|
||||||
Summary: %{summary}
|
Summary: %{summary}
|
||||||
|
Obsoletes: mingw64-libvirt < 7.0.0
|
||||||
|
|
||||||
%description -n mingw64-libvirt
|
%description -n mingw64-libvirt
|
||||||
MinGW Windows libvirt virtualization library.
|
MinGW Windows libvirt virtualization library.
|
||||||
|
|
||||||
%package -n mingw64-libvirt-static
|
|
||||||
Summary: %{summary}
|
|
||||||
Requires: mingw64-libvirt = %{version}-%{release}
|
|
||||||
|
|
||||||
%description -n mingw64-libvirt-static
|
|
||||||
MinGW Windows libvirt virtualization library, static version.
|
|
||||||
|
|
||||||
%{?mingw_debug_package}
|
%{?mingw_debug_package}
|
||||||
|
|
||||||
|
|
||||||
@ -138,55 +101,82 @@ echo "This RPM requires Fedora >= %{min_fedora}"
|
|||||||
exit 1
|
exit 1
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if ! %{with_esx}
|
%mingw_meson \
|
||||||
%define _without_esx --without-esx
|
--auto-features=enabled \
|
||||||
%endif
|
-Ddriver_remote=enabled \
|
||||||
|
-Ddriver_esx=enabled \
|
||||||
%if ! %{with_hyperv}
|
-Dcurl=enabled \
|
||||||
%define _without_hyperv --without-hyperv
|
-Ddocs=enabled \
|
||||||
%endif
|
-Dapparmor=disabled \
|
||||||
|
-Dattr=disabled \
|
||||||
%if ! %{with_xenapi}
|
-Daudit=disabled \
|
||||||
%define _without_xenapi --without-xenapi
|
-Dbash_completion=disabled \
|
||||||
%endif
|
-Dblkid=disabled \
|
||||||
|
-Dcapng=disabled \
|
||||||
%if ! %{with_vz}
|
-Ddriver_bhyve=disabled \
|
||||||
%define _without_vz --without-vz
|
-Ddriver_hyperv=disabled \
|
||||||
%endif
|
-Ddriver_interface=disabled \
|
||||||
|
-Ddriver_libvirtd=disabled \
|
||||||
%if 0%{?enable_autotools}
|
-Ddriver_libxl=disabled \
|
||||||
autoreconf -if
|
-Ddriver_lxc=disabled \
|
||||||
%endif
|
-Ddriver_network=disabled \
|
||||||
|
-Ddriver_openvz=disabled \
|
||||||
# XXX enable SASL in future
|
-Ddriver_qemu=disabled \
|
||||||
%mingw_configure \
|
-Ddriver_secrets=disabled \
|
||||||
--enable-static \
|
-Ddriver_vbox=disabled \
|
||||||
--without-xen \
|
-Ddriver_vmware=disabled \
|
||||||
--without-qemu \
|
-Ddriver_vz=disabled \
|
||||||
--without-openvz \
|
-Ddtrace=disabled \
|
||||||
--without-lxc \
|
-Dexpensive_tests=enabled \
|
||||||
--without-vbox \
|
-Dfirewalld=disabled \
|
||||||
%{?_without_xenapi} \
|
-Dfirewalld_zone=disabled \
|
||||||
--without-sasl \
|
-Dfuse=disabled \
|
||||||
--without-polkit \
|
-Dglusterfs=disabled \
|
||||||
--without-libvirtd \
|
-Dhost_validate=disabled \
|
||||||
%{?_without_esx} \
|
-Dlibiscsi=disabled \
|
||||||
%{?_without_hyperv} \
|
-Dlibnl=disabled \
|
||||||
--without-vmware \
|
-Dlibpcap=disabled \
|
||||||
--without-parallels \
|
-Dlibssh2=disabled \
|
||||||
--without-netcf \
|
-Dlibssh=disabled \
|
||||||
--without-audit \
|
-Dlogin_shell=disabled \
|
||||||
--without-dtrace \
|
-Dnetcf=disabled \
|
||||||
--enable-expensive-tests
|
-Dnls=disabled \
|
||||||
|
-Dnss=disabled \
|
||||||
%mingw_make %{?_smp_mflags}
|
-Dnumactl=disabled \
|
||||||
|
-Dnumad=disabled \
|
||||||
|
-Dopenwsman=disabled \
|
||||||
|
-Dpciaccess=disabled \
|
||||||
|
-Dpm_utils=disabled \
|
||||||
|
-Dpolkit=disabled \
|
||||||
|
-Dreadline=disabled \
|
||||||
|
-Drpath=disabled \
|
||||||
|
-Dsanlock=disabled \
|
||||||
|
-Dsasl=disabled \
|
||||||
|
-Dsecdriver_apparmor=disabled \
|
||||||
|
-Dsecdriver_selinux=disabled \
|
||||||
|
-Dselinux=disabled \
|
||||||
|
-Dstorage_dir=disabled \
|
||||||
|
-Dstorage_disk=disabled \
|
||||||
|
-Dstorage_fs=disabled \
|
||||||
|
-Dstorage_gluster=disabled \
|
||||||
|
-Dstorage_iscsi_direct=disabled \
|
||||||
|
-Dstorage_iscsi=disabled \
|
||||||
|
-Dstorage_lvm=disabled \
|
||||||
|
-Dstorage_mpath=disabled \
|
||||||
|
-Dstorage_rbd=disabled \
|
||||||
|
-Dstorage_scsi=disabled \
|
||||||
|
-Dstorage_sheepdog=disabled \
|
||||||
|
-Dstorage_vstorage=disabled \
|
||||||
|
-Dstorage_zfs=disabled \
|
||||||
|
-Dsysctl_config=disabled \
|
||||||
|
-Dtests=disabled \
|
||||||
|
-Dudev=disabled \
|
||||||
|
-Dwireshark_dissector=disabled \
|
||||||
|
-Dyajl=disabled
|
||||||
|
%mingw_ninja
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%mingw_make_install "DESTDIR=$RPM_BUILD_ROOT"
|
%mingw_ninja_install
|
||||||
|
|
||||||
# Libtool files don't need to be bundled
|
|
||||||
find $RPM_BUILD_ROOT -name "*.la" -delete
|
|
||||||
|
|
||||||
rm -rf $RPM_BUILD_ROOT%{mingw32_sysconfdir}/libvirt/nwfilter
|
rm -rf $RPM_BUILD_ROOT%{mingw32_sysconfdir}/libvirt/nwfilter
|
||||||
rm -rf $RPM_BUILD_ROOT%{mingw64_sysconfdir}/libvirt/nwfilter
|
rm -rf $RPM_BUILD_ROOT%{mingw64_sysconfdir}/libvirt/nwfilter
|
||||||
@ -267,12 +257,6 @@ rm -rf $RPM_BUILD_ROOT%{mingw64_libexecdir}/libvirt-guests.sh
|
|||||||
%{mingw32_mandir}/man1/virt-pki-validate.1*
|
%{mingw32_mandir}/man1/virt-pki-validate.1*
|
||||||
%{mingw32_mandir}/man7/virkey*.7*
|
%{mingw32_mandir}/man7/virkey*.7*
|
||||||
|
|
||||||
%files -n mingw32-libvirt-static
|
|
||||||
%{mingw32_libdir}/libvirt.a
|
|
||||||
%{mingw32_libdir}/libvirt-lxc.a
|
|
||||||
%{mingw32_libdir}/libvirt-qemu.a
|
|
||||||
%{mingw32_libdir}/libvirt-admin.a
|
|
||||||
|
|
||||||
# Mingw64
|
# Mingw64
|
||||||
%files -n mingw64-libvirt
|
%files -n mingw64-libvirt
|
||||||
%dir %{mingw64_sysconfdir}/libvirt/
|
%dir %{mingw64_sysconfdir}/libvirt/
|
||||||
@ -299,28 +283,8 @@ rm -rf $RPM_BUILD_ROOT%{mingw64_libexecdir}/libvirt-guests.sh
|
|||||||
|
|
||||||
%dir %{mingw64_datadir}/libvirt/
|
%dir %{mingw64_datadir}/libvirt/
|
||||||
%dir %{mingw64_datadir}/libvirt/schemas/
|
%dir %{mingw64_datadir}/libvirt/schemas/
|
||||||
%{mingw64_datadir}/libvirt/schemas/basictypes.rng
|
%{mingw64_datadir}/libvirt/schemas/*.rng
|
||||||
%{mingw64_datadir}/libvirt/schemas/capability.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/cputypes.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/domain.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/domainbackup.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/domaincaps.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/domaincheckpoint.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/domaincommon.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/domainsnapshot.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/interface.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/network.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/networkcommon.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/networkport.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/nodedev.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/nwfilter.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/nwfilter_params.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/nwfilterbinding.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/secret.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/storagecommon.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/storagepool.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/storagepoolcaps.rng
|
|
||||||
%{mingw64_datadir}/libvirt/schemas/storagevol.rng
|
|
||||||
%dir %{mingw64_datadir}/libvirt/api/
|
%dir %{mingw64_datadir}/libvirt/api/
|
||||||
%{mingw64_datadir}/libvirt/api/libvirt-api.xml
|
%{mingw64_datadir}/libvirt/api/libvirt-api.xml
|
||||||
%{mingw64_datadir}/libvirt/api/libvirt-lxc-api.xml
|
%{mingw64_datadir}/libvirt/api/libvirt-lxc-api.xml
|
||||||
@ -359,11 +323,4 @@ rm -rf $RPM_BUILD_ROOT%{mingw64_libexecdir}/libvirt-guests.sh
|
|||||||
%{mingw64_mandir}/man1/virt-pki-validate.1*
|
%{mingw64_mandir}/man1/virt-pki-validate.1*
|
||||||
%{mingw64_mandir}/man7/virkey*.7*
|
%{mingw64_mandir}/man7/virkey*.7*
|
||||||
|
|
||||||
%files -n mingw64-libvirt-static
|
|
||||||
%{mingw64_libdir}/libvirt.a
|
|
||||||
%{mingw64_libdir}/libvirt-lxc.a
|
|
||||||
%{mingw64_libdir}/libvirt-qemu.a
|
|
||||||
%{mingw64_libdir}/libvirt-admin.a
|
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
x
Reference in New Issue
Block a user