#10 WIP: Build mingw packages
Opened a year ago by orion. Modified a year ago
rpms/ orion/pulseaudio mingw  into  rawhide

file modified
+378 -1
@@ -33,10 +33,16 @@ 

  # where/how to apply multilib hacks

  %global multilib_archs x86_64 %{ix86} ppc64 ppc s390x s390 sparc64 sparcv9 ppc64le

  

+ %if 0%{?fedora}

+ %bcond_without mingw

+ %else

+ %bcond_with mingw

+ %endif

+ 

  Name:           pulseaudio

  Summary:        Improved Linux Sound Server

  Version:        %{pa_major}%{?pa_minor:.%{pa_minor}}

- Release:        4%{?snap:.%{snap}git%{shortcommit}}%{?dist}

+ Release:        5%{?snap:.%{snap}git%{shortcommit}}%{?dist}

  License:        LGPLv2+

  URL:            http://www.freedesktop.org/wiki/Software/PulseAudio

  %if 0%{?gitrel}
@@ -62,6 +68,7 @@ 

  ## upstream patches

  

  ## upstreamable patches

+ Patch300: pulseaudio-mingw.patch

  

  BuildRequires:  meson >= 0.50.0

  BuildRequires:  gcc
@@ -116,6 +123,28 @@ 

  BuildRequires:  pkgconfig(gstreamer-app-1.0) >= 1.16.0

  BuildRequires:  pkgconfig(gstreamer-rtp-1.0) >= 1.16.0

  

+ %if %{with mingw}

+ BuildRequires:  mingw32-gcc-c++

+ BuildRequires:  mingw32-dbus

+ BuildRequires:  mingw32-gettext

+ BuildRequires:  mingw32-glib2

+ BuildRequires:  mingw32-gtk3

+ BuildRequires:  mingw32-libltdl

+ BuildRequires:  mingw32-libsndfile

+ BuildRequires:  mingw32-openssl

+ BuildRequires:  mingw32-pcre

+ 

+ BuildRequires:  mingw64-gcc-c++

+ BuildRequires:  mingw64-dbus

+ BuildRequires:  mingw64-gettext

+ BuildRequires:  mingw64-glib2

+ BuildRequires:  mingw64-gtk3

+ BuildRequires:  mingw64-libltdl

+ BuildRequires:  mingw64-libsndfile

+ BuildRequires:  mingw64-openssl

+ BuildRequires:  mingw64-pcre

+ %endif

+ 

  # retired along with -libs-zeroconf, add Obsoletes here for lack of anything better

  Obsoletes:      padevchooser < 1.0

  Requires(pre):  shadow-utils
@@ -240,6 +269,41 @@ 

  This package contains GDM integration hooks for the PulseAudio sound server.

  %endif

  

+ %if %{with mingw}

+ # Win32

+ %package -n mingw32-%{name}

+ Summary: MinGW compiled %{name} library for the Win32 target

+ BuildArch: noarch

+ 

+ %description -n mingw32-%{name}

+ MinGW compiled %{name} library for the Win32 target.

+ 

+ %package -n mingw32-%{name}-static

+ Summary: Static version of the MinGW Win32 compiled %{name} library

+ Requires: mingw32-%{name} = %{version}-%{release}

+ BuildArch: noarch

+ 

+ %description -n mingw32-%{name}-static

+ Static version of the MinGW Win32 compiled %{name} library.

+ 

+ # Win64

+ %package -n mingw64-%{name}

+ Summary: MinGW compiled %{name} library for the Win64 target

+ BuildArch: noarch

+ 

+ %description -n mingw64-%{name}

+ MinGW compiled %{name} library for the Win64 target.

+ 

+ %package -n mingw64-%{name}-static

+ Summary: Static version of the MinGW Win64 compiled %{name} library

+ Requires: mingw64-%{name} = %{version}-%{release}

+ BuildArch: noarch

+ 

+ %description -n mingw64-%{name}-static

+ Static version of the MinGW Win64 compiled %{name} library.

+ 

+ %{?mingw_debug_package}

+ %endif

  

  %prep

  %setup -q -T -b0 -n %{name}-%{version}%{?gitrel:-%{gitrel}-g%{shortcommit}}
@@ -252,6 +316,7 @@ 

  %if 0%{?systemd}

  %patch206 -p1 -b .autospawn_disable

  %endif

+ %patch300 -p1 -b .mingw

  

  sed -i.no_consolekit -e \

    's/^load-module module-console-kit/#load-module module-console-kit/' \
@@ -294,6 +359,14 @@ 

  

  %meson_build doxygen

  

+ %if %{with mingw}

+ %mingw_meson \

+   -D database=simple \

+   -D tests=false

+ 

+ %mingw_ninja

+ %endif

+ 

  %install

  %meson_install

  
@@ -332,6 +405,14 @@ 

  

  %find_lang %{name}

  

+ %if %{with mingw}

+ %mingw_ninja_install

+ rm -rf %{buildroot}%{mingw32_datadir}/{doc,man}

+ rm -rf %{buildroot}%{mingw64_datadir}/{doc,man}

+ %mingw_find_lang %{name}

+ %{?mingw_debug_install_post}

+ %endif

+ 

  

  %check

  %if 0%{?tests}
@@ -632,8 +713,304 @@ 

  %attr(0600, gdm, gdm) %{_localstatedir}/lib/gdm/.pulse/default.pa

  %endif

  

+ %if %{with mingw}

+ # Win32

+ %files -n mingw32-%{name} -f mingw32-%{name}.lang

+ %{mingw32_sysconfdir}/dbus-1/system.d/pulseaudio-system.conf

+ %{mingw32_sysconfdir}/pulse/

+ %{mingw32_bindir}/libcli.dll

+ %{mingw32_bindir}/libcli.dll.a

+ %{mingw32_bindir}/libprotocol-cli.dll

+ %{mingw32_bindir}/libprotocol-cli.dll.a

+ %{mingw32_bindir}/libprotocol-http.dll

+ %{mingw32_bindir}/libprotocol-http.dll.a

+ %{mingw32_bindir}/libprotocol-native.dll

+ %{mingw32_bindir}/libprotocol-native.dll.a

+ %{mingw32_bindir}/libprotocol-simple.dll

+ %{mingw32_bindir}/libprotocol-simple.dll.a

+ %{mingw32_bindir}/libpulse-0.dll

+ %{mingw32_bindir}/libpulsecommon-16.1.dll

+ %{mingw32_bindir}/libpulsecommon-16.1.dll.a

+ %{mingw32_bindir}/libpulsecore-16.1.dll

+ %{mingw32_bindir}/libpulsecore-16.1.dll.a

+ %{mingw32_bindir}/libpulse-mainloop-glib-0.dll

+ %{mingw32_bindir}/libpulse-simple-0.dll

+ %{mingw32_bindir}/module-allow-passthrough.dll

+ %{mingw32_bindir}/module-allow-passthrough.dll.a

+ %{mingw32_bindir}/module-always-sink.dll

+ %{mingw32_bindir}/module-always-sink.dll.a

+ %{mingw32_bindir}/module-always-source.dll

+ %{mingw32_bindir}/module-always-source.dll.a

+ %{mingw32_bindir}/module-augment-properties.dll

+ %{mingw32_bindir}/module-augment-properties.dll.a

+ %{mingw32_bindir}/module-card-restore.dll

+ %{mingw32_bindir}/module-card-restore.dll.a

+ %{mingw32_bindir}/module-cli.dll

+ %{mingw32_bindir}/module-cli.dll.a

+ %{mingw32_bindir}/module-cli-protocol-tcp.dll

+ %{mingw32_bindir}/module-cli-protocol-tcp.dll.a

+ %{mingw32_bindir}/module-cli-protocol-unix.dll

+ %{mingw32_bindir}/module-cli-protocol-unix.dll.a

+ %{mingw32_bindir}/module-combine.dll

+ %{mingw32_bindir}/module-combine.dll.a

+ %{mingw32_bindir}/module-combine-sink.dll

+ %{mingw32_bindir}/module-combine-sink.dll.a

+ %{mingw32_bindir}/module-console-kit.dll

+ %{mingw32_bindir}/module-console-kit.dll.a

+ %{mingw32_bindir}/module-dbus-protocol.dll

+ %{mingw32_bindir}/module-dbus-protocol.dll.a

+ %{mingw32_bindir}/module-default-device-restore.dll

+ %{mingw32_bindir}/module-default-device-restore.dll.a

+ %{mingw32_bindir}/module-detect.dll

+ %{mingw32_bindir}/module-detect.dll.a

+ %{mingw32_bindir}/module-device-manager.dll

+ %{mingw32_bindir}/module-device-manager.dll.a

+ %{mingw32_bindir}/module-device-restore.dll

+ %{mingw32_bindir}/module-device-restore.dll.a

+ %{mingw32_bindir}/module-echo-cancel.dll

+ %{mingw32_bindir}/module-echo-cancel.dll.a

+ %{mingw32_bindir}/module-filter-apply.dll

+ %{mingw32_bindir}/module-filter-apply.dll.a

+ %{mingw32_bindir}/module-filter-heuristics.dll

+ %{mingw32_bindir}/module-filter-heuristics.dll.a

+ %{mingw32_bindir}/module-http-protocol-tcp.dll

+ %{mingw32_bindir}/module-http-protocol-tcp.dll.a

+ %{mingw32_bindir}/module-http-protocol-unix.dll

+ %{mingw32_bindir}/module-http-protocol-unix.dll.a

+ %{mingw32_bindir}/module-intended-roles.dll

+ %{mingw32_bindir}/module-intended-roles.dll.a

+ %{mingw32_bindir}/module-ladspa-sink.dll

+ %{mingw32_bindir}/module-ladspa-sink.dll.a

+ %{mingw32_bindir}/module-loopback.dll

+ %{mingw32_bindir}/module-loopback.dll.a

+ %{mingw32_bindir}/module-match.dll

+ %{mingw32_bindir}/module-match.dll.a

+ %{mingw32_bindir}/module-native-protocol-fd.dll

+ %{mingw32_bindir}/module-native-protocol-fd.dll.a

+ %{mingw32_bindir}/module-native-protocol-tcp.dll

+ %{mingw32_bindir}/module-native-protocol-tcp.dll.a

+ %{mingw32_bindir}/module-native-protocol-unix.dll

+ %{mingw32_bindir}/module-native-protocol-unix.dll.a

+ %{mingw32_bindir}/module-null-sink.dll

+ %{mingw32_bindir}/module-null-sink.dll.a

+ %{mingw32_bindir}/module-null-source.dll

+ %{mingw32_bindir}/module-null-source.dll.a

+ %{mingw32_bindir}/module-position-event-sounds.dll

+ %{mingw32_bindir}/module-position-event-sounds.dll.a

+ %{mingw32_bindir}/module-remap-sink.dll

+ %{mingw32_bindir}/module-remap-sink.dll.a

+ %{mingw32_bindir}/module-remap-source.dll

+ %{mingw32_bindir}/module-remap-source.dll.a

+ %{mingw32_bindir}/module-rescue-streams.dll

+ %{mingw32_bindir}/module-rescue-streams.dll.a

+ %{mingw32_bindir}/module-role-cork.dll

+ %{mingw32_bindir}/module-role-cork.dll.a

+ %{mingw32_bindir}/module-role-ducking.dll

+ %{mingw32_bindir}/module-role-ducking.dll.a

+ %{mingw32_bindir}/module-rygel-media-server.dll

+ %{mingw32_bindir}/module-rygel-media-server.dll.a

+ %{mingw32_bindir}/module-simple-protocol-tcp.dll

+ %{mingw32_bindir}/module-simple-protocol-tcp.dll.a

+ %{mingw32_bindir}/module-simple-protocol-unix.dll

+ %{mingw32_bindir}/module-simple-protocol-unix.dll.a

+ %{mingw32_bindir}/module-sine.dll

+ %{mingw32_bindir}/module-sine.dll.a

+ %{mingw32_bindir}/module-sine-source.dll

+ %{mingw32_bindir}/module-sine-source.dll.a

+ %{mingw32_bindir}/module-stream-restore.dll

+ %{mingw32_bindir}/module-stream-restore.dll.a

+ %{mingw32_bindir}/module-suspend-on-idle.dll

+ %{mingw32_bindir}/module-suspend-on-idle.dll.a

+ %{mingw32_bindir}/module-switch-on-connect.dll

+ %{mingw32_bindir}/module-switch-on-connect.dll.a

+ %{mingw32_bindir}/module-switch-on-port-available.dll

+ %{mingw32_bindir}/module-switch-on-port-available.dll.a

+ %{mingw32_bindir}/module-tunnel-sink.dll

+ %{mingw32_bindir}/module-tunnel-sink.dll.a

+ %{mingw32_bindir}/module-tunnel-sink-new.dll

+ %{mingw32_bindir}/module-tunnel-sink-new.dll.a

+ %{mingw32_bindir}/module-tunnel-source.dll

+ %{mingw32_bindir}/module-tunnel-source.dll.a

+ %{mingw32_bindir}/module-tunnel-source-new.dll

+ %{mingw32_bindir}/module-tunnel-source-new.dll.a

+ %{mingw32_bindir}/module-virtual-sink.dll

+ %{mingw32_bindir}/module-virtual-sink.dll.a

+ %{mingw32_bindir}/module-virtual-source.dll

+ %{mingw32_bindir}/module-virtual-source.dll.a

+ %{mingw32_bindir}/module-volume-restore.dll

+ %{mingw32_bindir}/module-volume-restore.dll.a

+ %{mingw32_bindir}/module-waveout.dll

+ %{mingw32_bindir}/module-waveout.dll.a

+ %{mingw32_bindir}/pacat.exe

+ %{mingw32_bindir}/pactl.exe

+ %{mingw32_bindir}/pa-info

+ %{mingw32_bindir}/pulseaudio.exe

+ %{mingw32_includedir}/pulse/

+ %{mingw32_libdir}/cmake/PulseAudio/

+ %{mingw32_libdir}/libpulse.dll.a

+ %{mingw32_libdir}/libpulse-mainloop-glib.dll.a

+ %{mingw32_libdir}/libpulse-simple.dll.a

+ %{mingw32_libdir}/pkgconfig/libpulse.pc

+ %{mingw32_libdir}/pkgconfig/libpulse-simple.pc

+ %{mingw32_libdir}/pkgconfig/libpulse-mainloop-glib.pc

+ %{mingw32_datadir}/bash-completion/

+ %{mingw32_datadir}/vala/

+ %{mingw32_datadir}/zsh/

+ 

+ #files -n mingw32-%{name}-static

+ #{mingw32_libdir}/libsndfile.a

+ 

+ # Win64

+ %files -n mingw64-%{name} -f mingw64-%{name}.lang

+ %{mingw64_sysconfdir}/dbus-1/system.d/pulseaudio-system.conf

+ %{mingw64_sysconfdir}/pulse/

+ %{mingw64_bindir}/libcli.dll

+ %{mingw64_bindir}/libcli.dll.a

+ %{mingw64_bindir}/libprotocol-cli.dll

+ %{mingw64_bindir}/libprotocol-cli.dll.a

+ %{mingw64_bindir}/libprotocol-http.dll

+ %{mingw64_bindir}/libprotocol-http.dll.a

+ %{mingw64_bindir}/libprotocol-native.dll

+ %{mingw64_bindir}/libprotocol-native.dll.a

+ %{mingw64_bindir}/libprotocol-simple.dll

+ %{mingw64_bindir}/libprotocol-simple.dll.a

+ %{mingw64_bindir}/libpulse-0.dll

+ %{mingw64_bindir}/libpulsecommon-16.1.dll

+ %{mingw64_bindir}/libpulsecommon-16.1.dll.a

+ %{mingw64_bindir}/libpulsecore-16.1.dll

+ %{mingw64_bindir}/libpulsecore-16.1.dll.a

+ %{mingw64_bindir}/libpulse-mainloop-glib-0.dll

+ %{mingw64_bindir}/libpulse-simple-0.dll

+ %{mingw64_bindir}/module-allow-passthrough.dll

+ %{mingw64_bindir}/module-allow-passthrough.dll.a

+ %{mingw64_bindir}/module-always-sink.dll

+ %{mingw64_bindir}/module-always-sink.dll.a

+ %{mingw64_bindir}/module-always-source.dll

+ %{mingw64_bindir}/module-always-source.dll.a

+ %{mingw64_bindir}/module-augment-properties.dll

+ %{mingw64_bindir}/module-augment-properties.dll.a

+ %{mingw64_bindir}/module-card-restore.dll

+ %{mingw64_bindir}/module-card-restore.dll.a

+ %{mingw64_bindir}/module-cli.dll

+ %{mingw64_bindir}/module-cli.dll.a

+ %{mingw64_bindir}/module-cli-protocol-tcp.dll

+ %{mingw64_bindir}/module-cli-protocol-tcp.dll.a

+ %{mingw64_bindir}/module-cli-protocol-unix.dll

+ %{mingw64_bindir}/module-cli-protocol-unix.dll.a

+ %{mingw64_bindir}/module-combine.dll

+ %{mingw64_bindir}/module-combine.dll.a

+ %{mingw64_bindir}/module-combine-sink.dll

+ %{mingw64_bindir}/module-combine-sink.dll.a

+ %{mingw64_bindir}/module-console-kit.dll

+ %{mingw64_bindir}/module-console-kit.dll.a

+ %{mingw64_bindir}/module-dbus-protocol.dll

+ %{mingw64_bindir}/module-dbus-protocol.dll.a

+ %{mingw64_bindir}/module-default-device-restore.dll

+ %{mingw64_bindir}/module-default-device-restore.dll.a

+ %{mingw64_bindir}/module-detect.dll

+ %{mingw64_bindir}/module-detect.dll.a

+ %{mingw64_bindir}/module-device-manager.dll

+ %{mingw64_bindir}/module-device-manager.dll.a

+ %{mingw64_bindir}/module-device-restore.dll

+ %{mingw64_bindir}/module-device-restore.dll.a

+ %{mingw64_bindir}/module-echo-cancel.dll

+ %{mingw64_bindir}/module-echo-cancel.dll.a

+ %{mingw64_bindir}/module-filter-apply.dll

+ %{mingw64_bindir}/module-filter-apply.dll.a

+ %{mingw64_bindir}/module-filter-heuristics.dll

+ %{mingw64_bindir}/module-filter-heuristics.dll.a

+ %{mingw64_bindir}/module-http-protocol-tcp.dll

+ %{mingw64_bindir}/module-http-protocol-tcp.dll.a

+ %{mingw64_bindir}/module-http-protocol-unix.dll

+ %{mingw64_bindir}/module-http-protocol-unix.dll.a

+ %{mingw64_bindir}/module-intended-roles.dll

+ %{mingw64_bindir}/module-intended-roles.dll.a

+ %{mingw64_bindir}/module-ladspa-sink.dll

+ %{mingw64_bindir}/module-ladspa-sink.dll.a

+ %{mingw64_bindir}/module-loopback.dll

+ %{mingw64_bindir}/module-loopback.dll.a

+ %{mingw64_bindir}/module-match.dll

+ %{mingw64_bindir}/module-match.dll.a

+ %{mingw64_bindir}/module-native-protocol-fd.dll

+ %{mingw64_bindir}/module-native-protocol-fd.dll.a

+ %{mingw64_bindir}/module-native-protocol-tcp.dll

+ %{mingw64_bindir}/module-native-protocol-tcp.dll.a

+ %{mingw64_bindir}/module-native-protocol-unix.dll

+ %{mingw64_bindir}/module-native-protocol-unix.dll.a

+ %{mingw64_bindir}/module-null-sink.dll

+ %{mingw64_bindir}/module-null-sink.dll.a

+ %{mingw64_bindir}/module-null-source.dll

+ %{mingw64_bindir}/module-null-source.dll.a

+ %{mingw64_bindir}/module-position-event-sounds.dll

+ %{mingw64_bindir}/module-position-event-sounds.dll.a

+ %{mingw64_bindir}/module-remap-sink.dll

+ %{mingw64_bindir}/module-remap-sink.dll.a

+ %{mingw64_bindir}/module-remap-source.dll

+ %{mingw64_bindir}/module-remap-source.dll.a

+ %{mingw64_bindir}/module-rescue-streams.dll

+ %{mingw64_bindir}/module-rescue-streams.dll.a

+ %{mingw64_bindir}/module-role-cork.dll

+ %{mingw64_bindir}/module-role-cork.dll.a

+ %{mingw64_bindir}/module-role-ducking.dll

+ %{mingw64_bindir}/module-role-ducking.dll.a

+ %{mingw64_bindir}/module-rygel-media-server.dll

+ %{mingw64_bindir}/module-rygel-media-server.dll.a

+ %{mingw64_bindir}/module-simple-protocol-tcp.dll

+ %{mingw64_bindir}/module-simple-protocol-tcp.dll.a

+ %{mingw64_bindir}/module-simple-protocol-unix.dll

+ %{mingw64_bindir}/module-simple-protocol-unix.dll.a

+ %{mingw64_bindir}/module-sine.dll

+ %{mingw64_bindir}/module-sine.dll.a

+ %{mingw64_bindir}/module-sine-source.dll

+ %{mingw64_bindir}/module-sine-source.dll.a

+ %{mingw64_bindir}/module-stream-restore.dll

+ %{mingw64_bindir}/module-stream-restore.dll.a

+ %{mingw64_bindir}/module-suspend-on-idle.dll

+ %{mingw64_bindir}/module-suspend-on-idle.dll.a

+ %{mingw64_bindir}/module-switch-on-connect.dll

+ %{mingw64_bindir}/module-switch-on-connect.dll.a

+ %{mingw64_bindir}/module-switch-on-port-available.dll

+ %{mingw64_bindir}/module-switch-on-port-available.dll.a

+ %{mingw64_bindir}/module-tunnel-sink.dll

+ %{mingw64_bindir}/module-tunnel-sink.dll.a

+ %{mingw64_bindir}/module-tunnel-sink-new.dll

+ %{mingw64_bindir}/module-tunnel-sink-new.dll.a

+ %{mingw64_bindir}/module-tunnel-source.dll

+ %{mingw64_bindir}/module-tunnel-source.dll.a

+ %{mingw64_bindir}/module-tunnel-source-new.dll

+ %{mingw64_bindir}/module-tunnel-source-new.dll.a

+ %{mingw64_bindir}/module-virtual-sink.dll

+ %{mingw64_bindir}/module-virtual-sink.dll.a

+ %{mingw64_bindir}/module-virtual-source.dll

+ %{mingw64_bindir}/module-virtual-source.dll.a

+ %{mingw64_bindir}/module-volume-restore.dll

+ %{mingw64_bindir}/module-volume-restore.dll.a

+ %{mingw64_bindir}/module-waveout.dll

+ %{mingw64_bindir}/module-waveout.dll.a

+ %{mingw64_bindir}/pacat.exe

+ %{mingw64_bindir}/pactl.exe

+ %{mingw64_bindir}/pa-info

+ %{mingw64_bindir}/pulseaudio.exe

+ %{mingw64_includedir}/pulse/

+ %{mingw64_libdir}/cmake/PulseAudio/

+ %{mingw64_libdir}/libpulse.dll.a

+ %{mingw64_libdir}/libpulse-mainloop-glib.dll.a

+ %{mingw64_libdir}/libpulse-simple.dll.a

+ %{mingw64_libdir}/pkgconfig/libpulse.pc

+ %{mingw64_libdir}/pkgconfig/libpulse-simple.pc

+ %{mingw64_libdir}/pkgconfig/libpulse-mainloop-glib.pc

+ %{mingw64_datadir}/bash-completion/

+ %{mingw64_datadir}/vala/

+ %{mingw64_datadir}/zsh/

+ 

+ #files -n mingw64-%{name}-static

+ #{mingw64_libdir}/libsndfile.a

+ %endif

  

  %changelog

+ * Wed May 10 2023 Orion Poplawski <orion@nwra.com> - 16.1-5

+ - Build mingw packages

+ 

  * Thu Jan 26 2023 Wim Taymans <wtaymans@redhat.com> - 16.1-4

  - Add padsp again (rhbz#2120847)

  

Just starting to poke at this

Build failed. More information on how to proceed and troubleshoot errors available at https://fedoraproject.org/wiki/Zuul-based-ci
https://fedora.softwarefactory-project.io/zuul/buildset/a4686b1d3f514cafbe104211a8f49fb3

Metadata