--- a/xen4j.spec 2025-01-24 12:02:33.000000000 -0800 +++ b/xen4j.spec 2025-02-02 13:02:26.000000000 -0800 @@ -76,7 +76,7 @@ Name: xen Version: 4.19.1 Epoch: 3 -Release: 3%{?dist} +Release: 4%{?dist} Group: Development/Libraries License: GPLv2+ and LGPLv2+ and BSD URL: http://xen.org/ @@ -136,6 +136,9 @@ Source34: README.cfg-dump Source35: README.install-sh #Source36: src-qemu-keymap.tar.xz +Source40: qemu-guest-agent.service +Source41: 99-qemu-guest-agent.rules +Source42: qemu-ga.sysconfig %if %{defined _with_minsize} NoSource: 0 @@ -398,9 +401,40 @@ %endif +%if %{defined _with_qga} +%package -n qemuu-guest-agent +Version: 9.1.0+j1 +Release: 4%{?dist} +Summary: QEMU guest agent +Requires(post): systemd-units +Requires(preun): systemd-units +Requires(postun): systemd-units +%description -n qemuu-guest-agent +%{name} is an open source virtualizer that provides hardware emulation for +the KVM hypervisor. + +This package provides an agent to run inside guests, which communicates +with the host over a virtio-serial channel named "org.qemu.guest_agent.0" + +This package does not need to be installed on the host OS. + +%files -n qemuu-guest-agent +%doc COPYING tools/qemu-xen/README.rst +%{_bindir}/qemu-ga +%{_mandir}/man8/qemu-ga.8* +%{_mandir}/man7/qemu-ga* +%{_unitdir}/qemu-guest-agent.service +%{_udevrulesdir}/99-qemu-guest-agent.rules +%exclude %{_xenlib}/xen/share/doc/qemu/interop/qemu-ga* +%config(noreplace) %{_sysconfdir}/sysconfig/qemu-ga +%{_sysconfdir}/sysconfig/qemu-ga +#{_datadir}/{name}/qemu-ga +%dir %{_localstatedir}/log/qemu-ga +%endif + %package -n qemuu Version: 9.1.0+j1 -Release: 3%{?dist} +Release: 4%{?dist} # build is staged to dist/uumeq Summary: Qemu upstream runtime environment Group: Development/Libraries @@ -419,7 +453,7 @@ %package -n qemuu-img Version: 9.1.0+j1 -Release: 3%{?dist} +Release: 4%{?dist} Conflicts: qemu-img >= 17:7.2.0 # build is staged to dist/uumeq Summary: QEMU command line tool for manipulating disk images @@ -430,7 +464,7 @@ %if %with_tumeq %package -n qemut Version: 0.10.2+j1 -Release: 3%{?dist} +Release: 4%{?dist} # build is staged to dist/uumeq Summary: Qemu traditional runtime environment Group: Development/Libraries @@ -526,7 +560,7 @@ # build - use bash now ## %build -%prep_reuse +#exit 0 ./autogen.sh @@ -627,7 +661,11 @@ export XTRACT_CFGS= %global _libexecdir %{_xenlib} # this makefile runs tools/configure -%{__make} -f %{SOURCE33} +%{__make} -f %{SOURCE33} tools-config + +%if %{defined _with_qga} +sed -i -e '/^CONFIG_QEMUU_EXTRA_ARGS/ s|$| --enable-guest-agent|' config/Tools.mk +%endif %if 1 == 0 # skip default hypervisor build in main xen root, reserve that for xsm build @@ -669,7 +707,7 @@ cp -p %{SOURCE27} $PWD/dist/uumeq/usr/bin/qemu-kvm mkdir -p $PWD/dist/uumeq/etc/ld.so.conf.d/ ; -echo "/usr/lib/xen/lib/qemu/" >> $PWD/dist/uumeq/etc/ld.so.conf.d/qemu-6.0.conf ; +echo "/usr/lib/xen/lib/qemu/" >> $PWD/dist/uumeq/etc/ld.so.conf.d/qemu-9.1.conf ; fi if [ -d $PWD/dist/uumeq/usr/lib/xen/lib/qemu ]; then chmod 755 $PWD/dist/uumeq/usr/lib/xen/lib/qemu/*.so @@ -760,12 +798,17 @@ fi fi -%if %{defined _with_xenperf} -cp -p %SOURCE25 ./ -%endif - (cd dist/uumeq;find . -type f -or -type l | sed -e s/^.// -e /^$/d) | sort -u > uumeq.lst +%if %{defined _with_qga} +cp -p dist/uumeq/usr/lib/xen/bin/qemu-ga dist/install/usr/bin +cp -p dist/uumeq/usr/share/man/man8/qemu-ga* dist/install/usr/share/man/man8/ +cp -p dist/uumeq/usr/share/man/man7/qemu-ga* dist/install/usr/share/man/man7/ +mkdir -p dist/install/%{_sysconfdir}/sysconfig/qemu-ga +mkdir -p dist/install/var/log/qemu-ga +sed -i -e '/qemu-ga/d' uumeq.lst +%endif + sed -i -e '/man\/man/ s|$|.gz|' uumeq.lst # need only one line for the bios dir @@ -803,6 +846,16 @@ #rm -rf \$RPM_BUILD_ROOT %{?ocaml_flags} dist/install.sh $RPM_BUILD_ROOT/ +%if %{defined _with_xenperf} +cp -p %SOURCE25 ./ +%endif + +%if %{defined _with_qga} +install -D -m 0644 %{_sourcedir}/qemu-guest-agent.service %{buildroot}%{_unitdir}/qemu-guest-agent.service +install -D -m 0644 %{_sourcedir}/qemu-ga.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/qemu-ga +install -D -m 0644 %{_sourcedir}/99-qemu-guest-agent.rules %{buildroot}%{_udevrulesdir}/99-qemu-guest-agent.rules +%endif + %if %{defined _with_uncom} cp -p dist/uumeq/usr/lib/%name/bin/qemu-keymap $RPM_BUILD_ROOT/usr/bin %endif @@ -925,7 +978,7 @@ #cp -p ./usr/lib/{name}/bin/qemu-keymap ./usr/bin/qemu-keymap %package -n qemuu-uncom Version: 9.1.0+j1 -Release: 3%{?dist} +Release: 4%{?dist} Summary: extra qemuu build depends for %{name} Group: Development/Lbraries #Requires: xen-hypervisor-abi = {hv_abi} @@ -1255,11 +1308,13 @@ rm -rf %{buildroot} %changelog +* Sun Feb 02 2025 Mark Pryor - 3:4.19.1-4 +- qemuu-guest-agent: new package for domU client + * Fri Jan 24 2025 Mark Pryor - 3:4.19.1-3 - HEAD @ 77d95386a783273ded28e xen/events: fix race with set_global_virq_handler-Tue 21 Jan 2025 00:30 - * Sat Dec 28 2024 Mark Pryor - 3:4.19.1-2 - HEAD @ 8dd897e691194929 MISRA: Unmark Rules 1.1 and 2.1 as clean following Eclair upgrade-Tue 17 Dec 2024 14:01