mvadkert / rpms / vulkan

Forked from rpms/vulkan 6 years ago
Clone

Blame vulkan.spec

cba7e8b
%global srcname Vulkan-LoaderAndValidationLayers
cba7e8b
140576a
%global commit1 3a21c880500eac21cdf79bef5b80f970a55ac6af
cba7e8b
%global srcname1 glslang
cba7e8b
140576a
%global commit2 2bb92e6fe2c6aa410152fc6c63443f452acb1a65
62d9cb1
%global srcname2 SPIRV-Headers
d563cea
140576a
%global commit3 7e2d26c77b606b21af839b37fd21381c4a669f23
62d9cb1
%global srcname3 SPIRV-Tools
cba7e8b
cba7e8b
Name:           vulkan
86dacbc
Version:        1.0.61.1
45e05a1
Release:        3%{?dist}
cba7e8b
Summary:        Vulkan loader and validation layers
cba7e8b
License:        ASL 2.0
cba7e8b
URL:            https://github.com/KhronosGroup
cba7e8b
Source0:        %url/%{srcname}/archive/sdk-%{version}.tar.gz#/%{srcname}-sdk-%{version}.tar.gz
cba7e8b
Source1:        %url/%{srcname1}/archive/%{commit1}.tar.gz#/%{srcname1}-%{commit1}.tar.gz
cba7e8b
Source2:        %url/%{srcname2}/archive/%{commit2}.tar.gz#/%{srcname2}-%{commit2}.tar.gz
cba7e8b
Source3:        %url/%{srcname3}/archive/%{commit3}.tar.gz#/%{srcname3}-%{commit3}.tar.gz
62d9cb1
cba7e8b
Patch0:         0003-layers-Don-t-set-an-rpath.patch
e068e7c
Patch1:         0008-demos-Don-t-build-tri-or-cube.patch
00072c4
Patch2:         %url/%{srcname}/commit/560f9cdf78d3d03dbf97be638becd1a7df5fa154.patch#/fix_x86_TEXTREL.patch
cba7e8b
cba7e8b
BuildRequires:  gcc-c++
cba7e8b
BuildRequires:  bison
a8bb022
BuildRequires:  cmake3
cba7e8b
BuildRequires:  /usr/bin/chrpath
eba641d
BuildRequires:  pkgconfig(libsystemd)
eba641d
BuildRequires:  pkgconfig(pciaccess)
87bc4ed
BuildRequires:  python3
eba641d
BuildRequires:  pkgconfig(wayland-client)
eba641d
BuildRequires:  pkgconfig(wayland-cursor)
eba641d
BuildRequires:  pkgconfig(wayland-server)
eba641d
BuildRequires:  pkgconfig(wayland-egl)
eba641d
BuildRequires:  pkgconfig(x11)
eba641d
BuildRequires:  pkgconfig(xcb)
e49ff98
BuildRequires:  pkgconfig(xrandr)
cba7e8b
9b5a331
Requires:       vulkan-filesystem = %{version}-%{release}
324a82d
Recommends:     mesa-vulkan-drivers
324a82d
cba7e8b
%description
cba7e8b
Vulkan is a new generation graphics and compute API that provides
cba7e8b
high-efficiency, cross-platform access to modern GPUs used in a wide variety of
cba7e8b
devices from PCs and consoles to mobile phones and embedded platforms.
cba7e8b
cba7e8b
This package contains the reference ICD loader and validation layers for
cba7e8b
Vulkan.
cba7e8b
cba7e8b
%package devel
cba7e8b
Summary:        Vulkan development package
cba7e8b
Requires:       %{name}%{?_isa} = %{version}-%{release}
cba7e8b
cba7e8b
%description devel
cba7e8b
Development headers for Vulkan applications.
cba7e8b
cba7e8b
%package filesystem
cba7e8b
Summary:        Vulkan filesystem package
cba7e8b
BuildArch:      noarch
cba7e8b
cba7e8b
%description filesystem
cba7e8b
Filesystem for Vulkan.
cba7e8b
cba7e8b
%prep
cba7e8b
%autosetup -p1 -n %{srcname}-sdk-%{version}
a8bb022
cba7e8b
mkdir -p build/ external/glslang/build/install external/spirv-tools/build/ external/spirv-tools/external/spirv-headers
cba7e8b
tar -xf %{SOURCE1} -C external/glslang --strip 1
62d9cb1
tar -xf %{SOURCE2} -C external/spirv-tools/external/spirv-headers --strip 1
62d9cb1
tar -xf %{SOURCE3} -C external/spirv-tools --strip 1
cba7e8b
# fix spurious-executable-perm
cba7e8b
chmod 0644 README.md
cba7e8b
chmod 0644 external/glslang/SPIRV/spirv.hpp
a8bb022
cba7e8b
# fix wrong-script-end-of-line-encoding
cba7e8b
sed -i 's/\r//' README.md
cba7e8b
cba7e8b
# sigh inttypes
e068e7c
sed -i 's/inttypes.h/cinttypes/' layers/*.{cpp,h}
cba7e8b
cba7e8b
%build
cba7e8b
pushd external/glslang/build/
45e05a1
%cmake3 -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=./install ..
cba7e8b
%make_build
cba7e8b
make install
cba7e8b
popd
05ac64d
cba7e8b
pushd external/spirv-tools/build/
45e05a1
%cmake3 -DCMAKE_BUILD_TYPE=Release ..
cba7e8b
%make_build
cba7e8b
popd
05ac64d
cba7e8b
pushd build/
05ac64d
%cmake3 -DCMAKE_BUILD_TYPE=Release \
45e05a1
       -DGLSLANG_VALIDATOR=../external/glslang/build/StandAlone/glslangValidator \
87bc4ed
       -DCMAKE_SKIP_RPATH:BOOL=yes \
87bc4ed
       -DBUILD_VKJSON=OFF \
a8bb022
       -DCMAKE_INSTALL_SYSCONFDIR:PATH=%{_datadir} \
45e05a1
       -DBUILD_WSI_MIR_SUPPORT=OFF ..
cba7e8b
%make_build
cba7e8b
popd
cba7e8b
cba7e8b
%install
cba7e8b
pushd build/
45e05a1
%make_install
cba7e8b
popd
cba7e8b
a8bb022
a8bb022
# create the filesystem
a8bb022
mkdir -p %{buildroot}%{_sysconfdir}/vulkan/{explicit,implicit}_layer.d/ \
a8bb022
%{buildroot}%{_datadir}/vulkan/{explicit,implicit}_layer.d/ \
a8bb022
%{buildroot}{%{_sysconfdir},%{_datadir}}/vulkan/icd.d
a8bb022
f8d40dd
# rename smoketest
f8d40dd
mv %{buildroot}%{_bindir}/smoketest %{buildroot}%{_bindir}/vulkan-smoketest
62d9cb1
cba7e8b
# remove RPATH
cba7e8b
chrpath -d %{buildroot}%{_bindir}/vulkaninfo
cba7e8b
cba7e8b
%post -p /sbin/ldconfig
cba7e8b
%postun -p /sbin/ldconfig
cba7e8b
cba7e8b
%files
9b5a331
%license LICENSE.txt COPYRIGHT.txt
9b5a331
%doc README.md CONTRIBUTING.md
cba7e8b
%{_bindir}/vulkaninfo
5d28910
%{_bindir}/vulkan-smoketest
cba7e8b
%{_datadir}/vulkan/explicit_layer.d/*.json
cba7e8b
%{_libdir}/libVkLayer_*.so
62d9cb1
%{_libdir}/libvulkan.so.*
cba7e8b
cba7e8b
%files devel
62d9cb1
%{_includedir}/vulkan/
62d9cb1
%{_libdir}/pkgconfig/vulkan.pc
62d9cb1
%{_libdir}/libvulkan.so
cba7e8b
cba7e8b
%files filesystem
a8bb022
%dir %{_sysconfdir}/vulkan/
a8bb022
%dir %{_sysconfdir}/vulkan/explicit_layer.d/
a8bb022
%dir %{_sysconfdir}/vulkan/icd.d/
a8bb022
%dir %{_sysconfdir}/vulkan/implicit_layer.d/
a8bb022
%dir %{_datadir}/vulkan/
a8bb022
%dir %{_datadir}/vulkan/explicit_layer.d/
a8bb022
%dir %{_datadir}/vulkan/icd.d/
a8bb022
%dir %{_datadir}/vulkan/implicit_layer.d/
cba7e8b
cba7e8b
%changelog
45e05a1
* Tue Oct 31 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.61.1-3
45e05a1
- Remove epel conditionals
45e05a1
- Remove vulkan git conditionals
45e05a1
- Use cmake macro for everything
45e05a1
00072c4
* Fri Oct 06 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.61.1-2
45e05a1
- Add upstream fix for 32bit TEXTREL issue (like anyone gives a damn)
00072c4
86dacbc
* Thu Sep 21 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.61.1-1
86dacbc
- Update to 1.0.61.1 release (rhbz 1493425)
86dacbc
140576a
* Tue Sep 19 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.61.0-1
140576a
- Update to 1.0.61.0 release
140576a
de00f72
* Mon Aug 14 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.57.0-1
de00f72
- Update to 1.0.57.0 release
de00f72
359b760
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.54.0-4
359b760
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
359b760
4f28c7b
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.54.0-3
4f28c7b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
4f28c7b
05ac64d
* Sat Jul 22 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.54.0-2
05ac64d
- Cleanup cmake commands
05ac64d
a8bb022
* Sat Jul 22 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.54.0-1
a8bb022
- Update to 1.0.54.0 release
a8bb022
- Use build requires cmake3 for epel build
a8bb022
- Build layers for epel
a8bb022
f8d40dd
* Fri Jun 16 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.51.0-1
f8d40dd
- Update to 1.0.51.0 release
f8d40dd
29c5a8a
* Mon May 15 2017 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.46.0-3
29c5a8a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_27_Mass_Rebuild
29c5a8a
5d28910
* Fri Apr 14 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.46.0-2
5d28910
- Fix epel build
5d28910
62d9cb1
* Fri Apr 14 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.46.0-1
62d9cb1
- Update to 1.0.46.0 release
62d9cb1
d563cea
* Sat Apr 01 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.42.2-1
d563cea
- Update to 1.0.42.2 release
d563cea
20c82e0
* Fri Mar 03 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.42.0-1
20c82e0
- Update to 1.0.42.0 release
20c82e0
291f9e0
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.39.1-2
291f9e0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
291f9e0
e486b64
* Tue Jan 31 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.39.1-1
e486b64
- Update to 1.0.39.1 release
e486b64
51eb752
* Tue Jan 24 2017 Leigh Scott <leigh123linux@googlemail.com> - 1.0.39.0-1
51eb752
- Update to 1.0.39.0 release
e49ff98
- Add build requires libXrandr-devel
51eb752
9666316
* Fri Dec 16 2016 leigh scott <leigh123linux@googlemail.com> - 1.0.37.0-1
9666316
- Update to 1.0.37.0 release
9666316
- Disable Mir as it's lame ubuntu rubbish
9666316
e068e7c
* Fri Dec 02 2016 leigh scott <leigh123linux@googlemail.com> - 1.0.34.0-0.1.gitd4cd34f
e068e7c
- Update to latest git
e068e7c
320812d
* Thu Dec 01 2016 leigh scott <leigh123linux@googlemail.com> - 1.0.30.0-2
320812d
- Fix VkLayer undefined symbol: util_GetExtensionProperties
320812d
9b5a331
* Sat Oct 15 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.30.0-1
9b5a331
- Update to 1.0.30.0 release
9b5a331
eba641d
* Mon Oct 10 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.26.0-4
eba641d
- Build with wayland support (rhbz 1383115)
eba641d
cba7e8b
* Tue Sep 27 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.26.0-3
cba7e8b
- Move unversioned libraries
cba7e8b
- Disable vkjson build
cba7e8b
- Fix license tag
cba7e8b
cba7e8b
* Sun Sep 11 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.26.0-2
cba7e8b
- Make layers conditional. 
cba7e8b
cba7e8b
* Sun Sep 11 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.26.0-1
cba7e8b
- Update to 1.0.26.0 release
cba7e8b
cba7e8b
* Thu Sep 08 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.26.0-0.3.gitfbb8667
cba7e8b
- Clean up
cba7e8b
cba7e8b
* Thu Sep 08 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.26.0-0.2.gitfbb8667
cba7e8b
- Change build requires python3
cba7e8b
- Use release for cmake
cba7e8b
- Make build verbose
cba7e8b
cba7e8b
* Wed Sep 07 2016 Leigh Scott <leigh123linux@googlemail.com> - 1.0.26.0-0.1.gitfbb8667
cba7e8b
- Update to latest git
cba7e8b
cba7e8b
* Tue Feb 16 2016 Igor Gnatenko <i.gnatenko.brain@gmail.com> - 1.0.3-0.1.git1affe90
cba7e8b
- Add ldconfig in post/postun
cba7e8b
- Use upstream tarball from commit + patches
cba7e8b
- Fix versioning. In fact it was never released
cba7e8b
- Fixup mixing of spaces/tabs
cba7e8b
- Remove rpath from vulkaninfo
cba7e8b
- Make filesystem subpkg noarch (it is really noarch)
cba7e8b
- BuildRequire gcc and gcc-c++ explicitly
cba7e8b
- Require main pkg with isa tag
cba7e8b
- Fix perms and perm of README.md
cba7e8b
- Use %%license tag
cba7e8b
cba7e8b
* Tue Feb 16 2016 Adam Jackson <ajax@redhat.com> - 1.0.3-0
cba7e8b
- Update loader to not build cube or tri. Drop bundled LunarGLASS and llvm
cba7e8b
  since they're only needed for those demos.
cba7e8b
cba7e8b
* Tue Feb 16 2016 Adam Jackson <ajax@redhat.com> - 1.0.3-0
cba7e8b
- Initial packaging