%global debug_package %{nil} Name: wine-dxvk Version: 1.3.2 Release: 1%{?dist} Summary: Vulkan-based D3D11 and D3D10 implementation for Linux / Wine License: zlib URL: https://github.com/doitsujin/dxvk Source0: %{url}/archive/v%{version}/dxvk-%{version}.tar.gz BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: glslang BuildRequires: meson BuildRequires: wine-devel %ifarch x86_64 BuildRequires: mingw64-filesystem BuildRequires: mingw64-binutils BuildRequires: mingw64-headers BuildRequires: mingw64-cpp BuildRequires: mingw64-gcc BuildRequires: mingw64-gcc-c++ BuildRequires: mingw64-winpthreads-static %else BuildRequires: mingw32-filesystem BuildRequires: mingw32-binutils BuildRequires: mingw32-headers BuildRequires: mingw32-cpp BuildRequires: mingw32-gcc BuildRequires: mingw32-gcc-c++ BuildRequires: mingw32-winpthreads-static %endif Requires: wine >= 4.13 Requires: wine-dxvk-dxgi%{?_isa} = %{version}-%{release} Requires: vulkan-loader%{?_isa} Requires(posttrans): %{_sbindir}/alternatives Requires(preun): %{_sbindir}/alternatives ExclusiveArch: %{ix86} x86_64 %description %{summary} %package dxgi Summary: DXVK DXGI implementation %description dxgi %{summary} %prep %setup -q -n dxvk-%{version} %build %ifarch x86_64 /usr/bin/meson --buildtype=plain --wrap-mode=nodownload --auto-features=enabled . x86_64-redhat-linux-gnu \ --cross-file build-wine64.txt --buildtype release --prefix /builddir/build/BUILD/dxvk-%{version}/build.w64 %meson_build cp /builddir/build/BUILD/dxvk-%{version}/x86_64-redhat-linux-gnu/src/dxgi/dxgi.dll.so /builddir/build/BUILD/dxvk-%{version}/dxgi.dll.so /usr/bin/meson --wipe --buildtype=plain --wrap-mode=nodownload --auto-features=enabled . x86_64-redhat-linux-gnu \ --cross-file build-win64.txt --buildtype release --prefix /builddir/build/BUILD/dxvk-%{version}/build.w64 %meson_build %else /usr/bin/meson --buildtype=plain --wrap-mode=nodownload --auto-features=enabled . i686-redhat-linux-gnu \ --cross-file build-wine32.txt --buildtype release --prefix /builddir/build/BUILD/dxvk-%{version}/build.w32 %meson_build cp /builddir/build/BUILD/dxvk-%{version}/i686-redhat-linux-gnu/src/dxgi/dxgi.dll.so /builddir/build/BUILD/dxvk-%{version}/dxgi.dll.so /usr/bin/meson --wipe --buildtype=plain --wrap-mode=nodownload --auto-features=enabled . i686-redhat-linux-gnu \ --cross-file build-win32.txt --buildtype release --prefix /builddir/build/BUILD/dxvk-%{version}/build.w32 %meson_build %endif %install %meson_install mkdir -p %{buildroot}%{_libdir}/wine/ install -p -m 755 /builddir/build/BUILD/dxvk-%{version}/dxgi.dll.so %{buildroot}%{_libdir}/wine/ %ifarch x86_64 install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w64/bin/d3d10.dll %{buildroot}%{_libdir}/wine/ install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w64/bin/d3d10core.dll %{buildroot}%{_libdir}/wine/ install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w64/bin/d3d10_1.dll %{buildroot}%{_libdir}/wine/ install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w64/bin/d3d11.dll %{buildroot}%{_libdir}/wine/ rm -rf %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w64 %else install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w32/bin/d3d10.dll %{buildroot}%{_libdir}/wine/ install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w32/bin/d3d10core.dll %{buildroot}%{_libdir}/wine/ install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w32/bin/d3d10_1.dll %{buildroot}%{_libdir}/wine/ install -p -m 755 %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w32/bin/d3d11.dll %{buildroot}%{_libdir}/wine/ rm -rf %buildroot/builddir/build/BUILD/dxvk-%{version}/build.w32 %endif mv %{buildroot}%{_libdir}/wine/dxgi.dll.so %{buildroot}%{_libdir}/wine/dxvk-dxgi.dll.so mv %{buildroot}%{_libdir}/wine/d3d10.dll %{buildroot}%{_libdir}/wine/dxvk-d3d10.dll mv %{buildroot}%{_libdir}/wine/d3d10core.dll %{buildroot}%{_libdir}/wine/dxvk-d3d10core.dll mv %{buildroot}%{_libdir}/wine/d3d10_1.dll %{buildroot}%{_libdir}/wine/dxvk-d3d10_1.dll mv %{buildroot}%{_libdir}/wine/d3d11.dll %{buildroot}%{_libdir}/wine/dxvk-d3d11.dll touch %{buildroot}%{_libdir}/wine/dxgi.dll.so touch %{buildroot}%{_libdir}/wine/d3d10.dll touch %{buildroot}%{_libdir}/wine/d3d10core.dll touch %{buildroot}%{_libdir}/wine/d3d10_1.dll touch %{buildroot}%{_libdir}/wine/d3d11.dll %posttrans %{_sbindir}/alternatives --install %{_libdir}/wine/dxgi.dll.so 'wine-dxgi%{?_isa}' %{_libdir}/wine/dxvk-dxgi.dll.so 20 %{_sbindir}/alternatives --install %{_libdir}/wine/d3d10.dll 'wine-d3d10%{?_isa}' %{_libdir}/wine/dxvk-d3d10.dll 20 \ --slave %{_libdir}/wine/d3d10_1.dll 'wine-d3d10_1%{?_isa}' %{_libdir}/wine/dxvk-d3d10_1.dll \ --slave %{_libdir}/wine/d3d10core.dll 'wine-d3d10core%{?_isa}' %{_libdir}/wine/dxvk-d3d10core.dll %{_sbindir}/alternatives --install %{_libdir}/wine/d3d11.dll 'wine-d3d11%{?_isa}' %{_libdir}/wine/dxvk-d3d11.dll 20 %postun %{_sbindir}/alternatives --remove 'wine-dxgi%{?_isa}' %{_libdir}/wine/dxvk-dxgi.dll.so %{_sbindir}/alternatives --remove 'wine-d3d10%{?_isa}' %{_libdir}/wine/dxvk-d3d10.dll %{_sbindir}/alternatives --remove 'wine-d3d11%{?_isa}' %{_libdir}/wine/dxvk-d3d11.dll %files %license LICENSE %doc README.md %ghost %{_libdir}/wine/d3d10.dll %ghost %{_libdir}/wine/d3d10_1.dll %ghost %{_libdir}/wine/d3d10core.dll %ghost %{_libdir}/wine/d3d11.dll %{_libdir}/wine/dxvk-d3d10.dll %{_libdir}/wine/dxvk-d3d10_1.dll %{_libdir}/wine/dxvk-d3d10core.dll %{_libdir}/wine/dxvk-d3d11.dll %files dxgi %license LICENSE %ghost %{_libdir}/wine/dxgi.dll.so %{_libdir}/wine/dxvk-dxgi.dll.so %changelog * Thu Aug 08 2019 Frantisek Zatloukal - 1.3.2-1 - Release 1.3.2 - Use alternatives for dxgi.dll.so * Thu Jul 25 2019 Frantisek Zatloukal - 1.3.1-1 - Initial packaging