]>
Commit | Line | Data |
---|---|---|
06b6a911 | 1 | |
8b0584c7 | 2 | # requires the OpenCL patches |
2b81df68 | 3 | %define llvm_version 11.0.0 |
8b0584c7 | 4 | |
2b81df68 | 5 | %define opencl_clang_version 11.0.0 |
06b6a911 JK |
6 | |
7 | Summary: The Intel Graphics Compiler for OpenCL | |
8 | Name: intel-graphics-compiler | |
2b81df68 | 9 | Version: 1.0.5353 |
6c3cbaee | 10 | Release: 3 |
06b6a911 JK |
11 | License: MIT |
12 | Group: Libraries | |
13 | Source0: https://github.com/intel/intel-graphics-compiler/archive/igc-%{version}/igc-%{version}.tar.gz | |
2b81df68 | 14 | # Source0-md5: bf101f596f63d1c9d6cddca10b9623ef |
06b6a911 | 15 | Patch0: pkgconfig.patch |
9b211843 | 16 | Patch1: cxx_flags.patch |
06b6a911 JK |
17 | URL: https://github.com/intel/intel-graphics-compiler/ |
18 | BuildRequires: llvm-devel >= %{llvm_version} | |
19 | BuildRequires: opencl-clang-devel >= %{opencl_clang_version} | |
20 | BuildRequires: cmake >= 3.2.0 | |
21 | BuildRequires: pkgconfig | |
22 | Requires: %{name}-libs = %{version}-%{release} | |
23 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
24 | ||
25 | %description | |
3ac63ffc JP |
26 | The Intel Graphics Compiler for OpenCL is an LLVM based compiler for |
27 | OpenCL targeting Intel Gen graphics hardware architecture. | |
06b6a911 JK |
28 | |
29 | %package libs | |
30 | Summary: The Intel Graphics Compiler for OpenCL libraries | |
31 | Group: Libraries | |
32 | ||
33 | %description libs | |
34 | The Intel Graphics Compiler for OpenCL libraries. | |
35 | ||
36 | %package devel | |
37 | Summary: Header files for %{name} library | |
38 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki %{name} | |
39 | Group: Development/Libraries | |
ba53ee66 | 40 | Requires: llvm-devel >= %{llvm_version} |
06b6a911 JK |
41 | Requires: %{name}-libs = %{version}-%{release} |
42 | ||
43 | %description devel | |
44 | Header files for %{name} library. | |
45 | ||
46 | %description devel -l pl.UTF-8 | |
47 | Pliki nagłówkowe biblioteki %{name}. | |
48 | ||
49 | %prep | |
50 | %setup -qn %{name}-igc-%{version} | |
51 | ||
52 | %patch0 -p1 | |
9b211843 | 53 | %patch1 -p1 |
06b6a911 | 54 | |
2b81df68 JP |
55 | %{__sed} -i -e 's/-Werror/-Werror -Wno-error=deprecated-declarations/' IGC/CMakeLists.txt |
56 | ||
06b6a911 JK |
57 | %build |
58 | install -d build | |
59 | cd build | |
60 | %cmake \ | |
9b211843 JK |
61 | -DCMAKE_BUILD_TYPE=Release \ |
62 | -DCMAKE_CXX_FLAGS_RELEASE="${CXXFLAGS:-%{rpmcxxflags} -DNDEBUG -DQT_NO_DEBUG}" \ | |
06b6a911 | 63 | -DCCLANG_FROM_SYSTEM=ON \ |
b64329ce | 64 | -DIGC_PREFERRED_LLVM_VERSION=%{llvm_version} \ |
2b81df68 | 65 | -DIGC_BUILD__VC_ENABLED=OFF \ |
06b6a911 JK |
66 | ../ |
67 | %{__make} | |
68 | ||
69 | cd .. | |
70 | ||
71 | %install | |
72 | rm -rf $RPM_BUILD_ROOT | |
73 | ||
74 | %{__make} -C build install \ | |
75 | DESTDIR=$RPM_BUILD_ROOT | |
76 | ||
77 | %clean | |
78 | rm -rf $RPM_BUILD_ROOT | |
79 | ||
80 | %files | |
81 | %defattr(644,root,root,755) | |
82 | %doc README.md | |
83 | %attr(755,root,root) %{_bindir}/GenX_IR | |
8bad0443 | 84 | %ifarch %{x8664} |
06b6a911 | 85 | %attr(755,root,root) %{_bindir}/iga64 |
8bad0443 JK |
86 | %else |
87 | %attr(755,root,root) %{_bindir}/iga32 | |
88 | %endif | |
06b6a911 JK |
89 | |
90 | %files libs | |
91 | %defattr(644,root,root,755) | |
8bad0443 | 92 | %ifarch %{x8664} |
06b6a911 JK |
93 | %attr(755,root,root) %{_libdir}/libiga64.so.1.*.* |
94 | %ghost %attr(755,root,root) %{_libdir}/libiga64.so.1 | |
8bad0443 | 95 | %else |
aea765ea | 96 | %attr(755,root,root) %{_libdir}/libiga32.so.1.*.* |
8bad0443 JK |
97 | %ghost %attr(755,root,root) %{_libdir}/libiga32.so.1 |
98 | %endif | |
06b6a911 JK |
99 | %attr(755,root,root) %{_libdir}/libigc.so.1.*.* |
100 | %ghost %attr(755,root,root) %{_libdir}/libigc.so.1 | |
101 | %attr(755,root,root) %{_libdir}/libigdfcl.so.1.*.* | |
102 | %ghost %attr(755,root,root) %{_libdir}/libigdfcl.so.1 | |
103 | ||
104 | %files devel | |
105 | %defattr(644,root,root,755) | |
380530b6 | 106 | %{_includedir}/iga |
06b6a911 | 107 | %{_includedir}/igc |
380530b6 | 108 | %{_includedir}/visa |
8bad0443 | 109 | %ifarch %{x8664} |
06b6a911 | 110 | %attr(755,root,root) %{_libdir}/libiga64.so |
8bad0443 JK |
111 | %else |
112 | %attr(755,root,root) %{_libdir}/libiga32.so | |
113 | %endif | |
06b6a911 JK |
114 | %attr(755,root,root) %{_libdir}/libigc.so |
115 | %attr(755,root,root) %{_libdir}/libigdfcl.so | |
116 | %{_pkgconfigdir}/igc-opencl.pc |