Debian Codegraph @

scripts/packaging/l0_gpu_driver/rhel_8/SPECS/l0_gpu_driver.spec

raw
1 #it's changed by external script
2 %global ver xxx
3 %global rel xxx
4 %global build_id xxx
5 %global NEO_RELEASE_WITH_REGKEYS FALSE
6 %global NEO_ENABLE_XE_EU_DEBUG_SUPPORT FALSE
7 %global NEO_I915_PRELIM_HEADERS_DIR %{nil}
8
9 %define _source_payload w5T16.xzdio
10 %define _binary_payload w5T16.xzdio
11
12 Name: intel-level-zero-gpu
13 Version: %{ver}
14 Release: %{rel}%{?dist}
15 Summary: Intel(R) GPU Driver for oneAPI Level Zero.
16
17 Group: System Environment/Libraries
18 License: MIT
19 URL: https://github.com/intel/compute-runtime
20 Source0: %{url}/archive/%{version}/compute-runtime.tar.xz
21 Source1: copyright
22 %if "%{NEO_I915_PRELIM_HEADERS_DIR}" != ""
23 Source2: uapi.tar.xz
24 %endif
25
26 BuildRequires: libva-devel gcc-c++ cmake ninja-build make
27 BuildRequires: intel-gmmlib-devel
28 BuildRequires: intel-igc-opencl-devel
29
30 Requires: intel-gmmlib
31 Requires: intel-igc-opencl
32
33 %description
34 Runtime library providing the ability to use Intel GPUs with the oneAPI Level
35 Zero programming interface.
36 Level Zero is the primary low-level interface for language and runtime
37 libraries. Level Zero offers fine-grain control over accelerators capabilities,
38 delivering a simplified and low-latency interface to hardware, and efficiently
39 exposing hardware capabilities to applications.
40
41 %package -n intel-level-zero-gpu-devel
42 Summary: Development files for Intel(R) GPU Driver for oneAPI Level Zero.
43 Group: Development/Libraries/C and C++
44 Requires: intel-level-zero-gpu = %{version}
45 Provides: intel-level-zero-gpu-devel
46
47 %description -n intel-level-zero-gpu-devel
48 Intel(R) Graphics Compute Runtime for oneAPI Level Zero - development headers
49
50 %define debug_package %{nil}
51
52 %prep
53 %if "%{NEO_I915_PRELIM_HEADERS_DIR}" == ""
54 %autosetup -p1 -n compute-runtime
55 %else
56 %autosetup -p1 -n compute-runtime -b 2
57 %endif
58
59 %build
60 mkdir build
61 cd build
62 %cmake .. \
63 -GNinja ${NEO_BUILD_EXTRA_OPTS} \
64 -DNEO_VERSION_BUILD=%{build_id} \
65 -DCMAKE_BUILD_TYPE=Release \
66 -DNEO_BUILD_WITH_OCL=FALSE \
67 -DNEO_SKIP_UNIT_TESTS=TRUE \
68 -DNEO_ENABLE_i915_PRELIM_DETECTION=TRUE \
69 -DNEO_ENABLE_XE_EU_DEBUG_SUPPORT=%{NEO_ENABLE_XE_EU_DEBUG_SUPPORT} \
70 -DRELEASE_WITH_REGKEYS=%{NEO_RELEASE_WITH_REGKEYS} \
71 -DL0_INSTALL_UDEV_RULES=1 \
72 -DUDEV_RULES_DIR=/etc/udev/rules.d/ \
73 -DCMAKE_VERBOSE_MAKEFILE=FALSE \
74 -DNEO_I915_PRELIM_HEADERS_DIR=$(realpath %{NEO_I915_PRELIM_HEADERS_DIR})
75 %ninja_build
76
77 %install
78 cd build
79 %ninja_install
80
81 #Remove OpenCL files
82 rm -rvf %{buildroot}%{_libdir}/intel-opencl/
83 rm -rvf %{buildroot}%{_sysconfdir}/OpenCL/
84 rm -rvf %{buildroot}%{_bindir}/ocloc
85 rm -rvf %{buildroot}%{_libdir}/libocloc.so
86 rm -rvf %{buildroot}%{_includedir}/ocloc_api.h
87 #Remove debug files
88 rm -vf %{buildroot}/%{_libdir}/intel-opencl/libigdrcl.so.debug
89 rm -vf %{buildroot}/%{_libdir}/libocloc.so.debug
90 rm -rvf %{buildroot}/usr/lib/debug/
91 #insert license into package
92 mkdir -p %{buildroot}/usr/share/doc/intel-level-zero-gpu/
93 cp -pvR %{_sourcedir}/copyright %{buildroot}/usr/share/doc/intel-level-zero-gpu/.
94
95 if [ -d "${NEO_NINJA_DUMP}" ]; then
96 cp -v .ninja* ${NEO_NINJA_DUMP}/
97 fi
98
99 %files
100 %defattr(-,root,root)
101 %{_libdir}/libze_intel_gpu.so.*
102 /usr/share/doc/intel-level-zero-gpu/copyright
103 %config(noreplace)
104
105 %files devel
106 %{_includedir}/level_zero/zet_intel_gpu_debug.h
107
108 %doc
109
110 %changelog
111 * Mon Aug 10 2020 Spruit, Neil R <[email protected]> - 1.0.17625
112 - Update to 1.0.17625
113
114 * Tue Apr 28 2020 Jacek Danecki <[email protected]> - 0.8.16582-1
115 - Update to 0.8.16582
116
117 * Tue Mar 24 2020 Spruit, Neil R <[email protected]> - 0.8.0
118 * Update to 0.8.0
119
120 * Fri Mar 13 2020 Pavel Androniychuk <[email protected]> - 0.4.1
121 - Spec file init