]>
Commit | Line | Data |
---|---|---|
1 | %define basever 5.17 | |
2 | %define postver 1 | |
3 | Summary: Linux kernel headers for use with C libraries | |
4 | Summary(pl.UTF-8): Nagłówki jądra Linuksa do użytku z bibliotekami C | |
5 | Name: linux-libc-headers | |
6 | Version: %{basever}.%{postver} | |
7 | Release: 1 | |
8 | Epoch: 7 | |
9 | License: GPL v2 | |
10 | Group: Development | |
11 | Source0: https://www.kernel.org/pub/linux/kernel/v5.x/linux-%{basever}.tar.xz | |
12 | # Source0-md5: 07321a70a48d062cebd0358132f11771 | |
13 | %if "%{postver}" > "0" | |
14 | Source1: https://www.kernel.org/pub/linux/kernel/v5.x/patch-%{version}.xz | |
15 | # Source1-md5: 5a015eeaa9a3bf5bea84290f54ccf48d | |
16 | %endif | |
17 | Patch0: %{name}-esfq.patch | |
18 | Patch1: %{name}-wrr.patch | |
19 | Patch2: %{name}-fbsplash.patch | |
20 | Patch3: %{name}-imq.patch | |
21 | Patch4: %{name}-pom-set.patch | |
22 | Patch5: %{name}-atm-vbr.patch | |
23 | Patch6: vserver.patch | |
24 | URL: https://www.kernel.org/ | |
25 | AutoReqProv: no | |
26 | BuildRequires: perl-base | |
27 | BuildRequires: rpmbuild(macros) >= 1.568 | |
28 | BuildRequires: rsync | |
29 | BuildRequires: tar >= 1:1.22 | |
30 | BuildRequires: xz | |
31 | Requires(pretrans): coreutils | |
32 | Obsoletes: alsa-driver-devel | |
33 | Obsoletes: glibc-kernel-headers | |
34 | Obsoletes: glibc-kernheaders | |
35 | Conflicts: lm_sensors-devel < 2.8.2-2 | |
36 | ExclusiveOS: Linux | |
37 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
38 | ||
39 | %ifarch ppc ppc64 | |
40 | %define target_arch powerpc | |
41 | %else | |
42 | %ifarch x32 | |
43 | %define target_arch x86_64 | |
44 | %else | |
45 | %ifarch aarch64 | |
46 | %define target_arch arm64 | |
47 | %else | |
48 | %define target_arch %{_target_base_arch} | |
49 | %endif | |
50 | %endif | |
51 | %endif | |
52 | ||
53 | # no objects to extract debug info from | |
54 | %define _enable_debug_packages 0 | |
55 | ||
56 | %description | |
57 | This package includes the C header files that specify the interface | |
58 | between the Linux kernel and userspace libraries and programs. The | |
59 | header files define structures and constants that are needed for | |
60 | building most standard programs and are also needed for rebuilding the | |
61 | glibc package. | |
62 | ||
63 | %description -l pl.UTF-8 | |
64 | Ten pakiet zawiera pliki nagłówkowe C, które definiują interfejs | |
65 | między jądrem Linuksa a bibliotekami i programami działającymi w | |
66 | przestrzeni użytkownika. Pliki nagłówkowe definiują struktury i stałe | |
67 | potrzebne do zbudowania większości standardowych programów, są także | |
68 | potrzebne do przebudowania pakietu glibc. | |
69 | ||
70 | %prep | |
71 | %setup -q -c | |
72 | cd linux-%{basever} | |
73 | %if "%{postver}" > "0" | |
74 | bzip2 -dc %{SOURCE1} | patch -p1 | |
75 | %endif | |
76 | %patch0 -p1 | |
77 | %patch1 -p1 | |
78 | %patch2 -p1 | |
79 | %patch3 -p1 | |
80 | %patch4 -p1 | |
81 | %patch5 -p1 | |
82 | %patch6 -p1 | |
83 | ||
84 | %install | |
85 | rm -rf $RPM_BUILD_ROOT | |
86 | %{__make} -C linux-%{basever} headers_install \ | |
87 | INSTALL_HDR_PATH=$RPM_BUILD_ROOT%{_prefix} \ | |
88 | ARCH=%{target_arch} | |
89 | ||
90 | # provided by glibc-headers | |
91 | %{__rm} -r $RPM_BUILD_ROOT%{_includedir}/scsi | |
92 | ||
93 | # currently provided by libdrm-devel | |
94 | %{__rm} -r $RPM_BUILD_ROOT%{_includedir}/drm | |
95 | ||
96 | %clean | |
97 | rm -rf $RPM_BUILD_ROOT | |
98 | ||
99 | %pretrans | |
100 | [ ! -L /usr/include/linux ] || rm -f /usr/include/linux | |
101 | [ ! -L /usr/include/asm ] || rm -f /usr/include/asm | |
102 | [ ! -L /usr/include/sound ] || rm -f /usr/include/sound | |
103 | ||
104 | %files | |
105 | %defattr(644,root,root,755) | |
106 | %{_includedir}/asm | |
107 | %{_includedir}/asm-generic | |
108 | %{_includedir}/linux | |
109 | %{_includedir}/misc | |
110 | %{_includedir}/mtd | |
111 | %{_includedir}/rdma | |
112 | %{_includedir}/sound | |
113 | %{_includedir}/video | |
114 | %{_includedir}/xen |