]> git.pld-linux.org Git - packages/kernel.git/blame - kernel.spec
- more notify fixes
[packages/kernel.git] / kernel.spec
CommitLineData
a7313793 1#
0fec42fa 2# NOTE:
351f379b
JR
3# the following bcond combos will not work
4# - without_vserver and any of the following
15a064bf 5# - with_grsecurity
a5585a68 6#
8ad00cb1
ER
7# LATEST VERSION CHECKER:
8# # curl -s http://www.kernel.org/kdist/finger_banner
9#
a5585a68 10# TODO:
953406b4 11# - update aufs2 patch when final version for 2.6.36 exists
d615e060 12#
351f379b 13# - benchmark NO_HZ & HZ=1000 vs HZ=300 on i686
351f379b 14#
fc5a68a2
AM
15# HOWTO update configuration files:
16# - run build
17# - add new options to proper config (kernel-multiarch.config, kernel-x86.config, kernel-powerpc.config etc)
18# - sort configuration files using:
ee5dc1b8 19# ./kernel-config-sort.pl ~/rpm/BUILD/kernel-%{version}/linux-%{version}/ -a x86 kernel-x86.config
fc5a68a2 20# ./kernel-config-sort.pl ~/rpm/BUILD/kernel-%{version}/linux-%{version} kernel-multiarch.config
a5585a68
AM
21#
22# Conditional build:
a5585a68 23%bcond_without source # don't build kernel-source package
1848fd38 24%bcond_without doc # don't build kernel-doc package
351f379b
JR
25%bcond_without pcmcia # don't build pcmcia
26
a5585a68 27%bcond_with verbose # verbose build (V=1)
351f379b
JR
28%bcond_without reiser4 # support for reiser4 fs (experimental)
29
30%bcond_without grsecurity # don't build grsecurity nor pax at all
d615e060 31%bcond_with pax # build pax and grsecurity (ie. grsecurity && pax)
351f379b
JR
32
33%bcond_with fbcondecor # build fbcondecor (disable FB_TILEBLITTING and affected fb modules)
34%bcond_with pae # build PAE (HIGHMEM64G) support on uniprocessor
35%bcond_with nfsroot # build with root on NFS support
36
7f07242b 37%bcond_without imq # imq support
1b75c2b4
JR
38%bcond_without wrr # wrr support
39%bcond_without esfq # esfq support
351f379b
JR
40%bcond_without ipv6 # ipv6 support
41
42%bcond_without vserver # support for VServer (enabled by default)
43%bcond_without tuxonice # support for tuxonice (ex-suspend2) (enabled by default)
351f379b
JR
44
45%bcond_with rescuecd # build kernel for our rescue
46
351f379b 47%bcond_with myown # build with your own config (kernel-myown.config)
a5585a68
AM
48
49%{?debug:%define with_verbose 1}
50
351f379b 51%if %{without grsecurity}
b488384f 52%unglobal with_pax
a5585a68 53%endif
351f379b 54
17da405a 55%if %{with pax}
351f379b
JR
56%define with_grsecurity 1
57%define with_pax 1
58%endif
59
351f379b
JR
60%define have_drm 1
61%define have_oss 1
62%define have_sound 1
101ae904 63%define have_pcmcia 1
351f379b
JR
64
65%if %{with rescuecd}
b488384f
AM
66%unglobal with_tuxonice
67%unglobal with_grsecurity
b488384f
AM
68%unglobal with_pax
69%unglobal with_vserver
351f379b
JR
70%define have_drm 0
71%define have_sound 0
72%endif
73
101ae904 74%if %{with myown}
75%define have_drm 0
76%define have_oss 0
77%define have_sound 0
78%define have_pcmcia 0
351f379b
JR
79%endif
80
81%ifarch sparc sparc64
b488384f 82%unglobal with_pcmcia
351f379b
JR
83%define have_drm 0
84%define have_oss 0
85%endif
86
101ae904 87%if %{without pcmcia}
88%define have_pcmcia 0
89%endif
90
28eb7fa5
AM
91%define basever 2.6.36
92%define postver %{nil}
93%define rel 0.1
a5585a68
AM
94
95%define _enable_debug_packages 0
a5585a68 96
28eb7fa5 97%define tuxonice_version 3.2
351f379b
JR
98%define netfilter_snap 20070806
99
101ae904 100%if %{with myown}
101%if "%{_alt_kernel}" == ""
102%define alt_kernel myown
351f379b 103%endif
101ae904 104%else
105%if %{without rescuecd}
15a064bf 106%define __alt_kernel %{?with_pax:pax}%{!?with_grsecurity:nogrsecurity}%{?with_pae:pae}
351f379b
JR
107%if "%{__alt_kernel}" != ""
108%define alt_kernel %{__alt_kernel}
109%endif
101ae904 110%else
111%define alt_kernel rescuecd
112%endif
113%endif
351f379b
JR
114
115# kernel release (used in filesystem and eventually in uname -r)
116# modules will be looked from /lib/modules/%{kernel_release}
117# localversion is just that without version for "> localversion"
118%define localversion %{rel}
119%define kernel_release %{version}%{?alt_kernel:_%{alt_kernel}}-%{localversion}
a5585a68
AM
120
121Summary: The Linux kernel (the core of the Linux operating system)
351f379b
JR
122Summary(de.UTF-8): Der Linux-Kernel (Kern des Linux-Betriebssystems)
123Summary(et.UTF-8): Linuxi kernel (ehk operatsioonisüsteemi tuum)
124Summary(fr.UTF-8): Le Kernel-Linux (La partie centrale du systeme)
125Summary(pl.UTF-8): Jądro Linuksa
126Name: kernel%{_alt_kernel}
127Version: %{basever}%{postver}
128Release: %{rel}
a5585a68 129Epoch: 3
c491b43b 130License: GPL v2
a5585a68 131Group: Base/Kernel
351f379b 132Source0: http://www.kernel.org/pub/linux/kernel/v2.6/linux-%{basever}.tar.bz2
28eb7fa5 133# Source0-md5: 61f3739a73afb6914cb007f37fb09b62
351f379b
JR
134%if "%{postver}" != "%{nil}"
135Source1: http://www.kernel.org/pub/linux/kernel/v2.6/patch-%{version}.bz2
7b80c872 136# Source1-md5: 7115d47e87afef1b9a14dbc9c387cd20
351f379b
JR
137%endif
138
139Source3: kernel-autoconf.h
140Source4: kernel-config.h
351f379b
JR
141Source6: kernel-config.awk
142Source7: kernel-module-build.pl
143Source8: kernel-track-config-change.awk
144# not used by kernel.spec, but it's good to have it in SOURCES
145Source9: kernel-config-sort.pl
146Source10: kernel.make
147
148Source20: kernel-multiarch.config
149Source21: kernel-x86.config
150Source22: kernel-sparc.config
5a99ae3d 151Source23: kernel-alpha.config
152Source24: kernel-powerpc.config
153Source25: kernel-ia64.config
351f379b
JR
154
155Source40: kernel-netfilter.config
156Source41: kernel-patches.config
157Source42: kernel-tuxonice.config
158Source43: kernel-vserver.config
159Source45: kernel-grsec.config
160
161Source49: kernel-pax.config
162Source50: kernel-no-pax.config
351f379b
JR
163Source55: kernel-imq.config
164Source56: kernel-reiser4.config
165Source57: kernel-wrr.config
166
167Source58: kernel-inittmpfs.config
168Source59: kernel-bzip2-lzma.config
169
351f379b
JR
170# http://dev.gentoo.org/~spock/projects/fbcondecor/archive/fbcondecor-0.9.4-2.6.25-rc6.patch
171Patch3: kernel-fbcondecor.patch
60bb736d 172Patch4: kernel-fbcon-margins.patch
351f379b
JR
173
174# netfilter related stuff mostly based on patch-o-matic-ng
17da405a 175# snapshot 20070806 with some fixes. Some modules
e69c45e8 176# were ported to nf_conntrack.
351f379b
JR
177
178Patch10: kernel-pom-ng-IPV4OPTSSTRIP.patch
179Patch11: kernel-pom-ng-ipv4options.patch
180
351f379b
JR
181Patch16: kernel-pom-ng-mms-conntrack-nat.patch
182Patch22: kernel-pom-ng-rsh.patch
183Patch23: kernel-pom-ng-rpc.patch
184
185# based on http://mike.it-loops.com/rtsp/rtsp-2.6.26.patch
186Patch36: kernel-nf_rtsp.patch
187
188# http://ftp.linux-vserver.org/pub/people/dhozac/p/k/delta-owner-xid-feat02.diff
189Patch37: kernel-owner-xid.patch
190
351f379b
JR
191# based on kernel-2.6.25-layer7-2.20.patch from
192# http://switch.dl.sourceforge.net/sourceforge/l7-filter/netfilter-layer7-v2.20.tar.gz
193Patch40: kernel-layer7.patch
194
78978408 195# http://www.ssi.bg/~ja/nfct/ipvs-nfct-2.6.34-1.diff
351f379b
JR
196Patch41: kernel-ipvs-nfct.patch
197
351f379b
JR
198### End netfilter
199
200# http://zph.bratcheda.org/linux-2.6.26.3-zph.patch
201Patch49: kernel-zph.patch
202
f6396b7e 203# based on http://www.linuximq.net/patchs/linux-2.6.35-imq-multiqueue-test1.diff
351f379b
JR
204Patch50: kernel-imq.patch
205
76514441 206# http://www.kernel.org/pub/linux/kernel/people/edward/reiser4/reiser4-for-2.6/reiser4-for-2.6.35.patch.bz2
351f379b
JR
207Patch51: kernel-reiser4.patch
208
209# http://www.zz9.dk/patches/wrr-linux-071203-2.6.25.patch.gz
210Patch52: kernel-wrr.patch
211
212# http://fatooh.org/esfq-2.6/sfq-2.6.24.1.tar.bz2
60bb736d 213Patch53: kernel-esfq.patch
351f379b
JR
214
215# http://memebeam.org/free-software/toshiba_acpi/toshiba_acpi-dev_toshiba_test5-linux_2.6.26.patch
60bb736d 216Patch54: kernel-toshiba_acpi.patch
351f379b
JR
217
218# by Baggins request:
219# derived from ftp://ftp.cmf.nrl.navy.mil/pub/chas/linux-atm/vbr/vbr-kernel-diffs
60bb736d
JR
220Patch55: kernel-atm-vbr.patch
221Patch56: kernel-atmdd.patch
351f379b 222
40bf088a
AM
223# https://trac.pentoo.ch/pentoo/export/1600/kernel/trunk/2.6/2.6.34/4305_sqlzma.patch
224Patch57: kernel-squashfs-lzma.patch
225
351f379b
JR
226# http://synce.svn.sourceforge.net/svnroot/synce/trunk/patches/linux-2.6.22-rndis_host-wm5.patch
227Patch59: kernel-rndis_host-wm5.patch
228
229# Project suspend2 renamed to tuxonice
f1ae092c 230# http://tuxonice.net/files/tuxonice-3.2-rc2-for-2.6.36.patch.bz2
60bb736d
JR
231Patch69: kernel-tuxonice.patch
232Patch70: kernel-tuxonice-headers.patch
351f379b
JR
233
234# adds some ids for hostap suported cards and monitor_enable from/for aircrack-ng
235# http://patches.aircrack-ng.org/hostap-kernel-2.6.18.patch
60bb736d 236Patch85: kernel-hostap.patch
351f379b 237
ba86f833 238# http://vserver.13thfloor.at/Experimental/patch-2.6.36-vs2.3.0.36.36.diff
60bb736d 239Patch100: kernel-vserver-2.3.patch
351f379b
JR
240Patch101: kernel-vserver-fixes.patch
241
242# Wake-On-Lan fix for nForce drivers; using http://atlas.et.tudelft.nl/verwei90/nforce2/wol.html
243# Fix verified for that kernel version.
60bb736d 244Patch130: kernel-forcedeth-WON.patch
351f379b 245
76b36ddb 246# add tty ioctl to figure physical device of the console. used by showconsole.spec (blogd)
f687bd1f
AM
247# raw from http://download.opensuse.org/update/11.2/rpm/src/kernel-source-2.6.31.12-0.2.1.src.rpm
248# from patches.fixes.tar.bz2
249# from patches.fixes/tiocgdev
76b36ddb
ER
250Patch131: kernel-TIOCGDEV.patch
251
76514441
AM
252# http://download.filesystems.org/unionfs/unionfs-2.x/unionfs-2.5.4_for_2.6.34-rc0.diff.gz
253# based on mandriva kernel src.rpm patches
351f379b 254Patch140: kernel-unionfs.patch
351f379b 255
4a4d8108 256# http://git.c3sl.ufpr.br/pub/scm/aufs/aufs2-standalone.git, read README
b752ccd1
AM
257# Patch creation:
258# git clone http://git.c3sl.ufpr.br/pub/scm/aufs/aufs2-standalone.git
953406b4 259# cd aufs2-standalone
4f0767ce 260# git checkout -b aufs2.1-35 origin/aufs2.1-35
b752ccd1
AM
261# cat aufs2-kbuild.patch aufs2-base.patch aufs2-standalone.patch > ~/rpm/packages/kernel/kernel-aufs2.patch
262# mkdir linux
263# cp -a Documentation fs include linux
264# diff -urN /usr/share/empty linux >> ~/rpm/packages/kernel/kernel-aufs2.patch
265
20493b41
JR
266Patch145: kernel-aufs2.patch
267Patch146: kernel-aufs2-unionfs.patch
268Patch147: kernel-aufs2-no-const-grsec.patch
4f0767ce 269Patch148: kernel-aufs2-reiser4.patch
a899ef35 270
54fd642e 271# Show normal colors in menuconfig with ncurses ABI 6
272Patch250: kernel-fix_256colors_menuconfig.patch
273
351f379b
JR
274# The following patch extend the routing functionality in Linux
275# to support static routes (defined by user), new way to use the
276# alternative routes, the reverse path protection (rp_filter),
277# the NAT processing to use correctly the routing when multiple
278# gateways are used.
975c63cc 279# http://www.ssi.bg/~ja/routes-2.6.36-16.diff
351f379b
JR
280Patch300: kernel-routes.patch
281
351f379b 282Patch2000: kernel-small_fixes.patch
60bb736d 283Patch2001: kernel-pwc-uncompress.patch
351f379b
JR
284Patch2003: kernel-regressions.patch
285
286# kill some thousands of warnings
287# (only warnings, so just remove parts of this patch if conflics)
60bb736d 288Patch2500: kernel-warnings.patch
351f379b 289
fc63ffa9
AM
290# 0001-AppArmor-compatibility-patch-for-v5-network-controll.patch
291# 0002-AppArmor-compatibility-patch-for-v5-interface.patch
292# from http://kernel.org/pub/linux/security/apparmor/apparmor-2.6.36-patches.tgz
351f379b 293Patch5000: kernel-apparmor.patch
351f379b
JR
294
295# for rescuecd
296# based on http://ftp.leg.uct.ac.za/pub/linux/rip/inittmpfs-2.6.14.diff.gz
297Patch7000: kernel-inittmpfs.patch
298
5f0db327 299# based on http://www.grsecurity.net/~spender/grsecurity-2.2.0-2.6.35.7-201010191911.patch
4a6985f1
AM
300# NOTE: put raw upstream patches on kernel-grsec_full.patch:GRSECURITY_RAW for reference
301# (since upstream deletes older patches)
60bb736d
JR
302Patch9999: kernel-grsec_full.patch
303Patch10000: kernel-grsec-caps.patch
304Patch10001: kernel-grsec-common.patch
351f379b 305Patch10002: kernel-grsec_fixes.patch
bf6838be 306
a5585a68 307URL: http://www.kernel.org/
351f379b 308BuildRequires: binutils >= 3:2.18
a5585a68
AM
309%ifarch sparc sparc64
310BuildRequires: elftoaout
311%endif
351f379b
JR
312%ifarch ppc
313BuildRequires: uboot-mkimage
314%endif
351f379b
JR
315BuildRequires: /sbin/depmod
316BuildRequires: gcc >= 5:3.2
cfce203c 317BuildRequires: xz >= 1:4.999.7
e69c45e8 318AutoReqProv: no
351f379b 319# for hostname command
c8ff6387 320BuildRequires: module-init-tools >= 3.5
351f379b 321BuildRequires: net-tools
a5585a68 322BuildRequires: perl-base
b488384f 323BuildRequires: rpm-build >= 4.5-24
351f379b
JR
324BuildRequires: rpmbuild(macros) >= 1.217
325Requires(post): coreutils
326Requires(post): geninitrd >= 10000-3
327Requires(post): module-init-tools >= 0.9.9
328Requires: /sbin/depmod
329Requires: coreutils
330Requires: geninitrd >= 10000-3
331Requires: module-init-tools >= 0.9.9
b75546f3 332Suggests: keyutils
351f379b
JR
333Provides: %{name}(netfilter) = %{netfilter_snap}
334Provides: %{name}(vermagic) = %{kernel_release}
335Obsoletes: kernel%{_alt_kernel}-isdn-mISDN
26b1ceeb 336Obsoletes: kernel-firmware
351f379b
JR
337Obsoletes: kernel-misc-acer_acpi
338Obsoletes: kernel-misc-fuse
339Obsoletes: kernel-misc-uvc
a5585a68 340Obsoletes: kernel-modules
351f379b
JR
341Obsoletes: kernel-net-ar81
342Obsoletes: kernel-net-hostap
343Obsoletes: kernel-net-ieee80211
344Obsoletes: kernel-net-ipp2p
345Obsoletes: kernel-net-rt61
346Obsoletes: kernel-smp
347Conflicts: e2fsprogs < 1.29
348Conflicts: isdn4k-utils < 3.1pre1
349Conflicts: jfsutils < 1.1.3
cf8de22f 350Conflicts: lvm2 < 2.02.40
351f379b
JR
351Conflicts: module-init-tools < 0.9.10
352Conflicts: nfs-utils < 1.0.5
353Conflicts: oprofile < 0.9
354Conflicts: ppp < 1:2.4.0
355Conflicts: procps < 3.2.0
356Conflicts: quota-tools < 3.09
4dabe329 357%{?with_reiserfs4:Conflicts: reiser4progs < 1.0.0}
351f379b 358Conflicts: reiserfsprogs < 3.6.3
4dabe329 359Conflicts: rpm < 4.4.2-0.2
351f379b
JR
360Conflicts: udev < 1:081
361Conflicts: util-linux < 2.10o
d3c4e01e 362Conflicts: util-vserver < 0.30.216
351f379b
JR
363Conflicts: xfsprogs < 2.6.0
364%if %{with pae}
365ExcludeArch: i386 i486 i586
366%else
367ExclusiveArch: %{ix86} %{x8664} alpha arm ia64 ppc ppc64 sparc sparc64
368%endif
a5585a68
AM
369ExclusiveOS: Linux
370BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
371
351f379b
JR
372%ifarch %{ix86} %{x8664}
373%define target_arch_dir x86
374%endif
375%ifarch ppc ppc64
376%define target_arch_dir powerpc
377%endif
5a99ae3d 378%ifarch sparc sparc64
379%define target_arch_dir sparc
380%endif
381%ifnarch %{ix86} %{x8664} ppc ppc64 sparc sparc64
351f379b
JR
382%define target_arch_dir %{_target_base_arch}
383%endif
384
385%define defconfig arch/%{target_arch_dir}/defconfig
386
387# No ELF objects there to strip (skips processing 27k files)
ded910ba 388%define _noautostrip \\(.*%{_kernelsrcdir}/.*\\|.*/vmlinux.*\\)
351f379b
JR
389%define _noautochrpath .*%{_kernelsrcdir}/.*
390
a5585a68
AM
391%ifarch ia64
392%define initrd_dir /boot/efi
393%else
394%define initrd_dir /boot
395%endif
396
351f379b
JR
397%define topdir %{_builddir}/%{name}-%{version}
398%define srcdir %{topdir}/linux-%{basever}
399%define objdir %{topdir}/%{targetobj}
400%define targetobj %{_target_base_arch}-gcc-%(%{kgcc} -dumpversion)
401
402%define _kernelsrcdir /usr/src/linux%{_alt_kernel}-%{version}
403
404%if "%{_target_base_arch}" != "%{_arch}"
405 %define CrossOpts ARCH=%{_target_base_arch} CROSS_COMPILE=%{_target_cpu}-pld-linux-
406 %define DepMod /bin/true
407
408 %if "%{_arch}" == "sparc" && "%{_target_base_arch}" == "sparc64"
409 %define CrossOpts ARCH=%{_target_base_arch} CC="%{__cc}"
410 %define DepMod /sbin/depmod
411 %endif
412
413 %if "%{_arch}" == "sparc64" && "%{_target_base_arch}" == "sparc"
414 %define CrossOpts ARCH=%{_target_base_arch} CC="%{__cc}"
415 %define DepMod /sbin/depmod
416 %endif
417
418 %if "%{_arch}" == "x86_64" && "%{_target_base_arch}" == "i386"
419 %define CrossOpts ARCH=%{_target_base_arch} CC="%{__cc}"
420 %define DepMod /sbin/depmod
421 %endif
422
5a99ae3d 423 %if "%{_target_base_arch}" == "ppc" || "%{_target_base_arch}" == "ppc64"
351f379b
JR
424 %define CrossOpts ARCH=powerpc CROSS_COMPILE=%{_target_cpu}-pld-linux-
425 %endif
426%else
427 %ifarch ppc ppc64
428 %define CrossOpts ARCH=powerpc CC="%{__cc}"
429 %else
430 %define CrossOpts ARCH=%{_target_base_arch} CC="%{__cc}"
431 %endif
432 %define DepMod /sbin/depmod
433%endif
434%define MakeOpts %{CrossOpts} HOSTCC="%{__cc}"
435
436%define __features Netfilter module dated: %{netfilter_snap}\
15a064bf 437%{?with_grsecurity:Grsecurity support - enabled}\
351f379b
JR
438%{?with_pax:PaX support - enabled}\
439%{?with_fbcondecor:Fbsplash/fbcondecor - enabled }\
440%{?with_nfsroot:Root on NFS - enabled}\
351f379b
JR
441
442%define Features %(echo "%{__features}" | sed '/^$/d')
443
a5585a68
AM
444%description
445This package contains the Linux kernel that is used to boot and run
446your system. It contains few device drivers for specific hardware.
447Most hardware is instead supported by modules loaded after booting.
448
351f379b
JR
449%{Features}
450
3a467bc1
JR
451%description -l de.UTF-8
452Das Kernel-Paket enthält den Linux-Kernel (vmlinuz), den Kern des
453Linux-Betriebssystems. Der Kernel ist für grundliegende
a5585a68 454Systemfunktionen verantwortlich: Speicherreservierung,
3a467bc1 455Prozeß-Management, Geräte Ein- und Ausgaben, usw.
a5585a68 456
351f379b
JR
457%{Features}
458
3a467bc1 459%description -l fr.UTF-8
a5585a68 460Le package kernel contient le kernel linux (vmlinuz), la partie
3a467bc1
JR
461centrale d'un système d'exploitation Linux. Le noyau traite les
462fonctions basiques d'un système d'exploitation: allocation mémoire,
463allocation de process, entrée/sortie de peripheriques, etc.
a5585a68 464
351f379b
JR
465%{Features}
466
3a467bc1
JR
467%description -l pl.UTF-8
468Pakiet zawiera jądro Linuksa niezbędne do prawidłowego działania
469Twojego komputera. Zawiera w sobie sterowniki do sprzętu znajdującego
470się w komputerze, takiego jak sterowniki dysków itp.
a5585a68 471
351f379b
JR
472%{Features}
473
474%package vmlinux
475Summary: vmlinux - uncompressed kernel image
476Summary(de.UTF-8): vmlinux - dekompressiertes Kernel Bild
477Summary(pl.UTF-8): vmlinux - rozpakowany obraz jądra
478Group: Base/Kernel
479Obsoletes: kernel-smp-vmlinux
480
481%description vmlinux
482vmlinux - uncompressed kernel image.
483
484%description vmlinux -l de.UTF-8
485vmlinux - dekompressiertes Kernel Bild.
486
487%description vmlinux -l pl.UTF-8
488vmlinux - rozpakowany obraz jądra.
489
a5585a68
AM
490%package drm
491Summary: DRM kernel modules
351f379b
JR
492Summary(de.UTF-8): DRM Kernel Treiber
493Summary(pl.UTF-8): Sterowniki DRM
a5585a68 494Group: Base/Kernel
351f379b
JR
495Requires(postun): %{name} = %{epoch}:%{version}-%{release}
496Requires: %{name} = %{epoch}:%{version}-%{release}
497Obsoletes: kernel-smp-drm
07ff8614 498AutoReqProv: no
a5585a68
AM
499
500%description drm
351f379b
JR
501DRM kernel modules.
502
503%description drm -l de.UTF-8
504DRM Kernel Treiber.
a5585a68 505
3a467bc1 506%description drm -l pl.UTF-8
351f379b 507Sterowniki DRM.
a5585a68
AM
508
509%package pcmcia
510Summary: PCMCIA modules
351f379b
JR
511Summary(de.UTF-8): PCMCIA Module
512Summary(pl.UTF-8): Moduły PCMCIA
a5585a68 513Group: Base/Kernel
351f379b
JR
514Requires(postun): %{name} = %{epoch}:%{version}-%{release}
515Requires: %{name} = %{epoch}:%{version}-%{release}
516Obsoletes: kernel-smp-pcmcia
517Conflicts: pcmcia-cs < 3.1.21
518Conflicts: pcmciautils < 004
07ff8614 519AutoReqProv: no
a5585a68
AM
520
521%description pcmcia
351f379b
JR
522PCMCIA modules.
523
524%description pcmcia -l de.UTF-8
525PCMCIA Module.
a5585a68 526
3a467bc1 527%description pcmcia -l pl.UTF-8
351f379b
JR
528Moduły PCMCIA.
529
a5585a68
AM
530%package sound-alsa
531Summary: ALSA kernel modules
351f379b
JR
532Summary(de.UTF-8): ALSA Kernel Module
533Summary(pl.UTF-8): Sterowniki dźwięku ALSA
a5585a68 534Group: Base/Kernel
351f379b
JR
535Requires(postun): %{name} = %{epoch}:%{version}-%{release}
536Requires: %{name} = %{epoch}:%{version}-%{release}
537Obsoletes: kernel-smp-sound-alsa
07ff8614 538AutoReqProv: no
a5585a68
AM
539
540%description sound-alsa
541ALSA (Advanced Linux Sound Architecture) sound drivers.
542
351f379b
JR
543%description sound-alsa -l de.UTF-8
544ALSA (Advanced Linux Sound Architecture) Sound-Treiber.
545
3a467bc1
JR
546%description sound-alsa -l pl.UTF-8
547Sterowniki dźwięku ALSA (Advanced Linux Sound Architecture).
a5585a68
AM
548
549%package sound-oss
550Summary: OSS kernel modules
351f379b
JR
551Summary(de.UTF-8): OSS Kernel Module
552Summary(pl.UTF-8): Sterowniki dźwięku OSS
a5585a68 553Group: Base/Kernel
351f379b
JR
554Requires(postun): %{name} = %{epoch}:%{version}-%{release}
555Requires: %{name} = %{epoch}:%{version}-%{release}
556Obsoletes: kernel-smp-sound-oss
07ff8614 557AutoReqProv: no
a5585a68
AM
558
559%description sound-oss
560OSS (Open Sound System) drivers.
561
351f379b
JR
562%description sound-oss -l de.UTF-8
563OSS (Open Sound System) Treiber.
564
3a467bc1
JR
565%description sound-oss -l pl.UTF-8
566Sterowniki dźwięku OSS (Open Sound System).
a5585a68 567
a5585a68
AM
568%package headers
569Summary: Header files for the Linux kernel
351f379b
JR
570Summary(de.UTF-8): Header Dateien für den Linux-Kernel
571Summary(pl.UTF-8): Pliki nagłówkowe jądra Linuksa
572Group: Development/Building
573Provides: %{name}-headers(netfilter) = %{netfilter_snap}
07ff8614 574AutoReqProv: no
a5585a68
AM
575
576%description headers
577These are the C header files for the Linux kernel, which define
351f379b
JR
578structures and constants that are needed when rebuilding the kernel or
579building kernel modules.
580
581%description headers -l de.UTF-8
582Dies sind die C Header Dateien für den Linux-Kernel, die definierte
583Strukturen und Konstante beinhalten, die beim rekompilieren des
584Kernels oder bei Kernel Modul kompilationen gebraucht werden.
a5585a68 585
3a467bc1
JR
586%description headers -l pl.UTF-8
587Pakiet zawiera pliki nagłówkowe jądra, niezbędne do rekompilacji jądra
588oraz budowania modułów jądra.
a5585a68
AM
589
590%package module-build
591Summary: Development files for building kernel modules
351f379b
JR
592Summary(de.UTF-8): Development Dateien die beim Kernel Modul kompilationen gebraucht werden
593Summary(pl.UTF-8): Pliki służące do budowania modułów jądra
594Group: Development/Building
a5585a68 595Requires: %{name}-headers = %{epoch}:%{version}-%{release}
fd19fa89 596Conflicts: rpmbuild(macros) < 1.550
07ff8614 597AutoReqProv: no
a5585a68
AM
598
599%description module-build
600Development files from kernel source tree needed to build Linux kernel
601modules from external packages.
602
351f379b
JR
603%description module-build -l de.UTF-8
604Development Dateien des Linux-Kernels die beim kompilieren externer
605Kernel Module gebraucht werden.
606
3a467bc1
JR
607%description module-build -l pl.UTF-8
608Pliki ze drzewa źródeł jądra potrzebne do budowania modułów jądra
609Linuksa z zewnętrznych pakietów.
a5585a68
AM
610
611%package source
612Summary: Kernel source tree
351f379b
JR
613Summary(de.UTF-8): Der Kernel Quelltext
614Summary(pl.UTF-8): Kod źródłowy jądra Linuksa
615Group: Development/Building
a5585a68 616Requires: %{name}-module-build = %{epoch}:%{version}-%{release}
07ff8614 617AutoReqProv: no
a5585a68
AM
618
619%description source
351f379b
JR
620This is the source code for the Linux kernel. You can build a custom
621kernel that is better tuned to your particular hardware.
a5585a68 622
3a467bc1
JR
623%description source -l de.UTF-8
624Das Kernel-Source-Paket enthält den source code (C/Assembler-Code) des
a5585a68 625Linux-Kernels. Die Source-Dateien werden gebraucht, um viele
351f379b 626C-Programme zu kompilieren, da sie auf Konstanten zurückgreifen, die
3a467bc1 627im Kernel-Source definiert sind. Die Source-Dateien können auch
351f379b 628benutzt werden, um einen Kernel zu kompilieren, der besser auf Ihre
a5585a68
AM
629Hardware ausgerichtet ist.
630
3a467bc1 631%description source -l fr.UTF-8
a5585a68 632Le package pour le kernel-source contient le code source pour le noyau
3a467bc1
JR
633linux. Ces sources sont nécessaires pour compiler la plupart des
634programmes C, car il dépend de constantes définies dans le code
635source. Les sources peuvent être aussi utilisée pour compiler un noyau
636personnalisé pour avoir de meilleures performances sur des matériels
a5585a68
AM
637particuliers.
638
3a467bc1
JR
639%description source -l pl.UTF-8
640Pakiet zawiera kod źródłowy jądra systemu.
a5585a68
AM
641
642%package doc
643Summary: Kernel documentation
351f379b
JR
644Summary(de.UTF-8): Kernel Dokumentation
645Summary(pl.UTF-8): Dokumentacja do jądra Linuksa
646Group: Documentation
07ff8614 647AutoReqProv: no
a5585a68
AM
648
649%description doc
650This is the documentation for the Linux kernel, as found in
651/usr/src/linux/Documentation directory.
652
351f379b
JR
653%description doc -l de.UTF-8
654Dies ist die Kernel Dokumentation wie sie im 'Documentation'
655Verzeichniss vorgefunden werden kann.
656
3a467bc1
JR
657%description doc -l pl.UTF-8
658Pakiet zawiera dokumentację do jądra Linuksa pochodzącą z katalogu
a5585a68
AM
659/usr/src/linux/Documentation.
660
661%prep
351f379b
JR
662%setup -qc
663ln -s %{SOURCE7} kernel-module-build.pl
664ln -s %{SOURCE10} Makefile
665cd linux-%{basever}
a5585a68 666
351f379b 667# hack against warning in pax/grsec
351f379b 668sed -i 's/-Werror//' arch/alpha/kernel/Makefile
a5585a68 669
351f379b
JR
670%if "%{postver}" != "%{nil}"
671%{__bzip2} -dc %{SOURCE1} | patch -p1 -s
672%endif
a5585a68 673
351f379b
JR
674# tuxonice:
675%if %{with tuxonice}
351f379b
JR
676%patch69 -p1
677%patch70 -p1
351f379b 678%endif
bf6838be 679
351f379b
JR
680%if %{with fbcondecor}
681%patch3 -p1
a5585a68 682%endif
351f379b 683%patch4 -p1
a5585a68 684
351f379b
JR
685## netfilter
686#
a5585a68 687
351f379b
JR
688# kernel-pom-ng-IPV4OPTSSTRIP.patch
689%patch10 -p1
a5585a68 690
351f379b
JR
691# kernel-pom-ng-ipv4options.patch
692%patch11 -p1
a5585a68 693
351f379b
JR
694# kernel-pom-ng-mms-conntrack-nat.patch
695%patch16 -p1
a5585a68 696
351f379b
JR
697# kernel-pom-ng-rsh.patch
698%patch22 -p1
a5585a68 699
351f379b
JR
700# kernel-pom-ng-rpc.patch
701%patch23 -p1
a5585a68 702
351f379b
JR
703# kernel-nf_rtsp.patch
704%patch36 -p1
a5585a68 705
351f379b
JR
706# kernel-owner-xid.patch
707%if %{with vserver}
708%patch37 -p1
a5585a68 709%endif
a5585a68 710
351f379b
JR
711# kernel-layer7.patch
712%patch40 -p1
713
714# ipvs-nfct
78978408 715%patch41 -p1
351f379b
JR
716
717##
718# end of netfilter
719
720# zph
721%patch49 -p1
722
723%if %{with imq}
724%patch50 -p1
a5585a68 725%endif
351f379b
JR
726
727# reiser4
728%if %{with reiser4}
729%patch51 -p1
a5585a68 730%endif
351f379b 731
351f379b 732# esfq
068b6c82
AM
733%if %{with esfq}
734%patch53 -p1
735%endif
351f379b
JR
736
737%if %{with wrr}
738%patch52 -p1
a5585a68 739%endif
351f379b
JR
740
741# toshiba_acpi
742%patch54 -p1
743
744%patch55 -p1
745%patch56 -p1
746
40bf088a
AM
747# squashfs lzma support
748%patch57 -p1
749
351f379b
JR
750# kernel-rndis_host-wm5.patch
751%patch59 -p1
752
753# hostap enhancements from/for aircrack-ng
754%patch85 -p1
755
351f379b
JR
756# vserver
757%if %{with vserver}
758%patch100 -p1
759%patch101 -p1
a5585a68 760%endif
351f379b 761
351f379b
JR
762# forcedeth
763%patch130 -p1
a5585a68 764
76b36ddb
ER
765%patch131 -p1
766
17da405a 767# aufs2
4f0767ce
JR
768%if %{with reiser4}
769%patch148 -p1
770%endif
20493b41
JR
771%patch145 -p1
772%patch146 -p1
773
774# unionfs
775%patch140 -p1
a5585a68 776
351f379b 777%patch2500 -p1
a5585a68 778
351f379b
JR
779%if %{with rescuecd}
780%patch7000 -p1
e981df17 781%endif
a5585a68 782
351f379b
JR
783# grsecurity & pax stuff
784#
351f379b 785
17da405a 786%if %{with grsecurity}
351f379b 787%patch9999 -p1
20493b41
JR
788# aufs2 needs to modify those pointers
789%patch147 -p1
351f379b
JR
790%{?with_vserver:%patch10000 -p1}
791%{?with_vserver:%patch10001 -p1}
792%{?with_vserver:%patch10002 -p1}
351f379b 793%endif
351f379b
JR
794#
795# end of grsecurity & pax stuff
796
df4db69a 797# apparmor
df4db69a 798%patch5000 -p1
df4db69a 799
54fd642e 800%patch250 -p1
801
351f379b
JR
802# routes
803%patch300 -p1
a5585a68 804
351f379b
JR
805# Small fixes:
806%patch2000 -p1
807%patch2001 -p1
808#%patch2003 -p1
a5585a68 809
351f379b
JR
810# Fix EXTRAVERSION in main Makefile
811sed -i 's#EXTRAVERSION =.*#EXTRAVERSION = %{postver}%{?alt_kernel:_%{alt_kernel}}#g' Makefile
a5585a68 812
351f379b
JR
813# cleanup backups after patching
814find '(' -name '*~' -o -name '*.orig' -o -name '.gitignore' ')' -print0 | xargs -0 -r -l512 rm -f
a5585a68 815
351f379b
JR
816%build
817install -d %{objdir}
818cat > %{targetobj}.mk <<'EOF'
819# generated by %{name}.spec
820KERNELSRC := %{_builddir}/%{name}-%{version}/linux-%{basever}
821KERNELOUTPUT := %{objdir}
822
823SRCARCH := %{target_arch_dir}
824ARCH := %{_target_base_arch}
825Q := %{!?with_verbose:@}
826MAKE_OPTS := %{MakeOpts}
827DEFCONFIG := %{defconfig}
828EOF
a5585a68 829
351f379b
JR
830PaXconfig() {
831 set -x
832 cat <<-EOCONFIG > $1
833 %ifarch %{ix86}
834 CONFIG_PAX_SEGMEXEC=y
835 # performance impact on CPUs without NX bit
836 CONFIG_PAX_PAGEEXEC=n
837 # Testing KERNEXEC
838
839 CONFIG_HOTPLUG_PCI_COMPAQ_NVRAM=n
840 CONFIG_PCI_BIOS=n
841 CONFIG_EFI=n
842 %endif
a5585a68 843
351f379b
JR
844 %ifarch ppc64
845 CONFIG_PAX_NOELFRELOCS=n
846 %endif
847 %ifarch ppc
848 CONFIG_PAX_EMUTRAMP=y
849 CONFIG_PAX_EMUSIGRT=y
850 CONFIG_PAX_EMUPLT=y
851 %endif
a5585a68 852
351f379b
JR
853 %ifarch sparc sparc64 alpha
854 CONFIG_PAX_EMUPLT=y
855 %endif
a5585a68 856
d615e060 857 # Now we have to check MAC system integration. Grsecurity uses PAX_HAVE_ACL_FLAGS
351f379b
JR
858 # setting (direct acces). grsec_minimal probably have no idea about PaX so we probably
859 # could use PAX_NO_ACL_FLAGS, but for testing the hooks setting will be used
e69c45e8 860 # PAX_HOOK_ACL_FLAGS.
351f379b 861
15a064bf 862 %if %{with grsecurity}
351f379b
JR
863 # Hardening grsec options if with pax
864 CONFIG_GRKERNSEC_PROC_MEMMAP=y
865 # almost rational (see HIDESYM help)
866 CONFIG_GRKERNSEC_HIDESYM=y
867
868 # no change needed CONFIG=PAX_HAVE_ACL_FLAGS=y is taken from the kernel-pax.config
869 %else
351f379b
JR
870 CONFIG_PAX_HAVE_ACL_FLAGS=n
871 CONFIG_PAX_HOOK_ACL_FLAGS=y
872 %endif
873EOCONFIG
a5585a68 874
351f379b
JR
875 return 0
876}
a5585a68 877
351f379b
JR
878RescueConfig() {
879 set -x
880 cat <<-EOCONFIG > $1
881 # CONFIG_SOUND is not set
882 # CONFIG_AUDIT is not set
883 # CONFIG_TR is not set
884 # CONFIG_BT is not set
885 # CONFIG_VIDEO_DEV is not set
886 # CONFIG_DVB_CORE is not set
887 # CONFIG_HAMRADIO is not set
888 # CONFIG_ARCNET is not set
889 # CONFIG_FB is not set
890 # CONFIG_DRM is not set
891 # CONFIG_WATCHDOG is not set
892 # CONFIG_INPUT_JOYSTICK is not set
893 # CONFIG_DEBUG_KERNEL is not set
894 # CONFIG_ISDN is not set
895 # CONFIG_AGP is not set
896 # CONFIG_SECURITY is not set
897 # CONFIG_PARIDE is not set
898 # CONFIG_CPU_FREQ is not set
899 # CONFIG_GAMEPORT is not set
900 # CONFIG_KVM is not set
901 # CONFIG_PHONE is not set
dd55897d 902 # CONFIG_STRICT_DEVMEM is not set
6bab3a31 903 # CONFIG_IMA is not set
351f379b 904 CONFIG_AUFS=y
a899ef35 905 CONFIG_AUFS_FS=y
906 CONFIG_AUFS_BR_RAMFS=y
62fff140 907 CONFIG_AUFS_RDU=y
351f379b
JR
908 CONFIG_BLK_DEV_LOOP=y
909 CONFIG_ISO9660_FS=y
910 CONFIG_NLS_UTF8=y
911EOCONFIG
912
913 return 0
914}
a5585a68 915
351f379b
JR
916BuildConfig() {
917 %{?debug:set -x}
918 set -e
a5585a68 919
351f379b
JR
920 Config="kernel-%{target_arch_dir}.config"
921 echo >&2 "Building config file for %{_target_cpu} using $Config et al."
a5585a68 922
351f379b
JR
923 # prepare local and important options
924 cat <<-EOCONFIG > important.config
925 LOCALVERSION="-%{localversion}"
fb4e3822 926
351f379b
JR
927%if 0%{?debug:1}
928 CONFIG_DEBUG_SLAB=y
929 CONFIG_DEBUG_SLAB_LEAK=y
930 CONFIG_DEBUG_PREEMPT=y
931 CONFIG_RT_DEADLOCK_DETECT=y
a5585a68 932%endif
351f379b 933
351f379b
JR
934%if %{without ipv6}
935 CONFIG_IPV6=n
936%endif
a5585a68 937
351f379b
JR
938%ifarch i686 athlon pentium3 pentium4
939 %if %{with pae}
940 CONFIG_HIGHMEM4G=n
941 CONFIG_HIGHMEM64G=y
942 CONFIG_X86_PAE=y
7c99a84b 943 CONFIG_NUMA=n
351f379b
JR
944 %endif
945%endif
a5585a68 946
351f379b
JR
947%if %{without pcmcia}
948 CONFIG_PCMCIA=n
949%endif
a5585a68 950
351f379b
JR
951%if %{with fbcondecor}
952 CONFIG_FB_S3=n
953 CONFIG_FB_VT8623=n
954 CONFIG_FB_ARK=n
955 CONFIG_FB_TILEBLITTING=n
956 CONFIG_FB_CON_DECOR=y
957%endif
a5585a68 958
351f379b
JR
959%if %{with nfsroot}
960 CONFIG_NFS_FS=y
961 CONFIG_ROOT_NFS=y
962%endif
a5585a68 963
351f379b 964# Temporary disabled RELOCATABLE. Needed only on x86??
15a064bf 965%if %{with pax} || %{with grsecurity}
351f379b
JR
966 CONFIG_RELOCATABLE=n
967%endif
968EOCONFIG
a5585a68 969
351f379b
JR
970%if %{with rescuecd}
971 RescueConfig rescue.config
972%endif
17da405a 973%if %{with pax}
351f379b
JR
974 PaXconfig pax.config
975%endif
a5585a68 976
351f379b
JR
977 # prepare kernel-style config file from multiple config files
978 %{__awk} -v arch="all %{target_arch_dir} %{_target_base_arch} %{_target_cpu}" -f %{SOURCE6} \
101ae904 979%if %{with myown}
980 $RPM_SOURCE_DIR/kernel-%{alt_kernel}.config \
981%endif
351f379b
JR
982 important.config \
983%if %{with rescuecd}
984 %{SOURCE58} \
985 %{SOURCE59} \
986 rescue.config \
987%endif
988 \
17da405a 989%if %{with pax}
351f379b
JR
990 %{SOURCE45} \
991 %{SOURCE49} \
992 pax.config \
993%else
15a064bf 994 %if %{with grsecurity}
351f379b
JR
995 %{SOURCE45} \
996 %{SOURCE50} \
351f379b 997 %endif
351f379b
JR
998%endif
999 \
1000%if %{with reiser4}
1001 %{SOURCE56} \
1002%endif
1003%if %{with wrr}
1004 %{SOURCE57} \
1005%endif
1006%if %{with imq}
1007 %{SOURCE55} \
1008%endif
1009%if %{with vserver}
1010 %{SOURCE43} \
1011%endif
1012%if %{with tuxonice}
1013%ifarch %{ix86} %{x8664} ia64 ppc ppc64
1014 %{SOURCE42} \
1015%endif
351f379b
JR
1016%endif
1017 %{SOURCE40} %{?0:netfilter} \
1018 %{SOURCE41} %{?0:patches} \
1019 %{SOURCE20} \
1020 $RPM_SOURCE_DIR/$Config
1021}
a5585a68 1022
351f379b
JR
1023cd %{objdir}
1024install -d arch/%{target_arch_dir}
351f379b 1025BuildConfig > %{defconfig}
351f379b
JR
1026ln -sf %{defconfig} .config
1027cd -
a5585a68 1028
7856c5e8
AM
1029%{__make} \
1030 TARGETOBJ=%{targetobj} \
1031 %{?with_verbose:V=1} \
1032 oldconfig
a5585a68 1033
351f379b 1034%{__awk} %{?debug:-v dieOnError=1} -v infile=%{objdir}/%{defconfig} -f %{SOURCE8} %{objdir}/.config
a5585a68 1035
351f379b 1036# build kernel
7856c5e8
AM
1037%{__make} \
1038 TARGETOBJ=%{targetobj} \
1039 %{?with_verbose:V=1} \
1040 all
a5585a68 1041
351f379b
JR
1042%install
1043rm -rf $RPM_BUILD_ROOT
4505b6c5 1044%{__make} %{MakeOpts} -j1 %{!?with_verbose:-s} modules_install firmware_install \
351f379b
JR
1045 -C %{objdir} \
1046 %{?with_verbose:V=1} \
1047 DEPMOD=%{DepMod} \
1048 INSTALL_MOD_PATH=$RPM_BUILD_ROOT \
1049 INSTALL_FW_PATH=$RPM_BUILD_ROOT/lib/firmware/%{kernel_release} \
1050 KERNELRELEASE=%{kernel_release}
1051
1052install -d $RPM_BUILD_ROOT/lib/modules/%{kernel_release}/misc
1053
101ae904 1054# create directories which may be missing, to simplyfy %files
64d14572 1055install -d $RPM_BUILD_ROOT/lib/modules/%{kernel_release}/kernel/{arch,sound,mm}
101ae904 1056
351f379b
JR
1057# rpm obeys filelinkto checks for ghosted symlinks, convert to files
1058rm -f $RPM_BUILD_ROOT/lib/modules/%{kernel_release}/{build,source}
1059touch $RPM_BUILD_ROOT/lib/modules/%{kernel_release}/{build,source}
1060
6d54bd67
ER
1061# no point embed content for %ghost files. empty them
1062for a in \
1063 dep{,.bin} \
1064 alias{,.bin} \
1065 symbols{,.bin} \
1066 {pci,usb,ccw,isapnp,input,ieee1394,serio,of}map \
1067; do
09e63f4a 1068 test -f $RPM_BUILD_ROOT/lib/modules/%{kernel_release}/modules.$a
6d54bd67
ER
1069 > $RPM_BUILD_ROOT/lib/modules/%{kernel_release}/modules.$a
1070done
1071
351f379b
JR
1072# /boot
1073install -d $RPM_BUILD_ROOT/boot
1074cp -a %{objdir}/System.map $RPM_BUILD_ROOT/boot/System.map-%{kernel_release}
1075%ifarch %{ix86} %{x8664}
1db9a2c1
ER
1076 cp -a %{objdir}/arch/%{target_arch_dir}/boot/bzImage $RPM_BUILD_ROOT/boot/vmlinuz-%{kernel_release}
1077 install -p %{objdir}/vmlinux $RPM_BUILD_ROOT/boot/vmlinux-%{kernel_release}
351f379b
JR
1078%endif
1079%ifarch ppc ppc64
1db9a2c1
ER
1080 install -p %{objdir}/vmlinux $RPM_BUILD_ROOT/boot/vmlinuz-%{kernel_release}
1081 install -p %{objdir}/vmlinux $RPM_BUILD_ROOT/boot/vmlinux-%{kernel_release}
a5585a68 1082%endif
a5585a68 1083%ifarch ia64
1db9a2c1
ER
1084 %{__gzip} -cfv %{objdir}/vmlinux > %{objdir}/vmlinuz
1085 cp -a %{objdir}/vmlinuz $RPM_BUILD_ROOT/boot/efi/vmlinuz-%{kernel_release}
1086 ln -sf efi/vmlinuz-%{kernel_release} $RPM_BUILD_ROOT/boot/vmlinuz-%{kernel_release}
351f379b
JR
1087%endif
1088%ifarch alpha sparc sparc64
1089 %{__gzip} -cfv %{objdir}/vmlinux > %{objdir}/vmlinuz
1090 cp -a %{objdir}/vmlinuz $RPM_BUILD_ROOT/boot/vmlinuz-%{kernel_release}
1db9a2c1
ER
1091 install -p %{objdir}/vmlinux $RPM_BUILD_ROOT/boot/vmlinuz-%{kernel_release}
1092 %ifarch sparc
1093 elftoaout %{objdir}/arch/sparc/boot/image -o %{objdir}/vmlinux.aout
1094 install -p %{objdir}/vmlinux.aout $RPM_BUILD_ROOT/boot/vmlinux.aout-%{kernel_release}
1095 %endif
1096 %ifarch sparc64
1097 elftoaout %{objdir}/arch/sparc64/boot/image -o %{objdir}/vmlinux.aout
1098 install -p %{objdir}/vmlinux.aout $RPM_BUILD_ROOT/boot/vmlinux.aout-%{kernel_release}
1099 %endif
351f379b
JR
1100%endif
1101%ifarch arm
1db9a2c1 1102 install -p %{objdir}/arch/arm/boot/zImage $RPM_BUILD_ROOT/boot/vmlinuz-%{kernel_release}
a5585a68 1103%endif
a5585a68 1104
351f379b
JR
1105# ghosted initrd
1106touch $RPM_BUILD_ROOT%{initrd_dir}/initrd-%{kernel_release}.gz
a5585a68 1107
351f379b
JR
1108%if "%{_target_base_arch}" != "%{_arch}"
1109touch $RPM_BUILD_ROOT/lib/modules/%{kernel_release}/modules.dep
1110%endif
a5585a68 1111
351f379b
JR
1112# /etc/modrobe.d
1113install -d $RPM_BUILD_ROOT%{_sysconfdir}/modprobe.d/%{kernel_release}
a5585a68 1114
351f379b 1115# /usr/src/linux
11b2646e 1116install -d $RPM_BUILD_ROOT%{_kernelsrcdir}/include/generated
351f379b
JR
1117# test if we can hardlink -- %{_builddir} and $RPM_BUILD_ROOT on same partition
1118if cp -al %{srcdir}/COPYING $RPM_BUILD_ROOT/COPYING 2>/dev/null; then
1119 l=l
1120 rm -f $RPM_BUILD_ROOT/COPYING
a5585a68 1121fi
a5585a68 1122
351f379b
JR
1123cp -a$l %{srcdir}/* $RPM_BUILD_ROOT%{_kernelsrcdir}
1124cp -a %{objdir}/Module.symvers $RPM_BUILD_ROOT%{_kernelsrcdir}/Module.symvers-dist
1125cp -aL %{objdir}/.config $RPM_BUILD_ROOT%{_kernelsrcdir}/config-dist
11b2646e
AM
1126cp -a %{objdir}/include/generated/autoconf.h $RPM_BUILD_ROOT%{_kernelsrcdir}/include/generated/autoconf-dist.h
1127cp -a %{objdir}/include/generated/utsrelease.h $RPM_BUILD_ROOT%{_kernelsrcdir}/include/generated
1128cp -a %{objdir}/include/linux/version.h $RPM_BUILD_ROOT%{_kernelsrcdir}/include/linux
1129cp -a %{SOURCE3} $RPM_BUILD_ROOT%{_kernelsrcdir}/include/generated/autoconf.h
351f379b
JR
1130cp -a %{SOURCE4} $RPM_BUILD_ROOT%{_kernelsrcdir}/include/linux/config.h
1131
1132# collect module-build files and directories
1133# Usage: kernel-module-build.pl $rpmdir $fileoutdir
1134fileoutdir=$(pwd)
1135cd $RPM_BUILD_ROOT%{_kernelsrcdir}
1136%{__perl} %{topdir}/kernel-module-build.pl %{_kernelsrcdir} $fileoutdir
1137cd -
1138
30f08736
ER
1139# move to %{_docdir} so we wouldn't depend on any kernel package for dirs
1140install -d $RPM_BUILD_ROOT%{_docdir}
1141mv $RPM_BUILD_ROOT{%{_kernelsrcdir}/Documentation,%{_docdir}/%{name}-%{version}}
1142
d3a69071
ER
1143rm -f $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/dontdiff
1144rm -f $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/Makefile
1145rm -f $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/*/Makefile
1146rm -f $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/*/*/Makefile
1147
351f379b
JR
1148%clean
1149rm -rf $RPM_BUILD_ROOT
1150
1151%preun
1152if [ -x /sbin/new-kernel-pkg ]; then
1153 /sbin/new-kernel-pkg --remove %{kernel_release}
a5585a68 1154fi
351f379b
JR
1155
1156%post
1157%ifarch ia64
1158mv -f /boot/efi/vmlinuz{,.old} 2> /dev/null
1159%{?alt_kernel:mv -f /boot/efi/vmlinuz%{_alt_kernel}{,.old} 2> /dev/null}
1160ln -sf vmlinuz-%{kernel_release} /boot/efi/vmlinuz
1161%{?alt_kernel:ln -sf vmlinuz-%{kernel_release} /boot/efi/vmlinuz%{_alt_kernel}}
1162%endif
1163mv -f /boot/vmlinuz{,.old} 2> /dev/null
1164%{?alt_kernel:mv -f /boot/vmlinuz%{_alt_kernel}{,.old} 2> /dev/null}
1165mv -f /boot/System.map{,.old} 2> /dev/null
1166%{?alt_kernel:mv -f /boot/System%{_alt_kernel}.map{,.old} 2> /dev/null}
1167ln -sf vmlinuz-%{kernel_release} /boot/vmlinuz
1168%{?alt_kernel:ln -sf vmlinuz-%{kernel_release} /boot/vmlinuz%{_alt_kernel}}
1169ln -sf System.map-%{kernel_release} /boot/System.map
1170%{?alt_kernel:ln -sf System.map-%{kernel_release} /boot/System.map%{_alt_kernel}}
1171
1172%depmod %{kernel_release}
1173
4dabe329
ER
1174%posttrans
1175# generate initrd after all dependant modules are installed
351f379b
JR
1176/sbin/geninitrd -f --initrdfs=rom %{initrd_dir}/initrd-%{kernel_release}.gz %{kernel_release}
1177mv -f %{initrd_dir}/initrd{,.old} 2> /dev/null
1178%{?alt_kernel:mv -f %{initrd_dir}/initrd%{_alt_kernel}{,.old} 2> /dev/null}
1179ln -sf initrd-%{kernel_release}.gz %{initrd_dir}/initrd
1180%{?alt_kernel:ln -sf initrd-%{kernel_release}.gz %{initrd_dir}/initrd%{_alt_kernel}}
1181
4dabe329 1182# update boot loaders when old package files are gone from filesystem
c5de1ad5 1183if [ -x /sbin/update-grub -a -f /etc/sysconfig/grub ]; then
4dabe329
ER
1184 if [ "$(. /etc/sysconfig/grub; echo ${UPDATE_GRUB:-no})" = "yes" ]; then
1185 /sbin/update-grub >/dev/null
c5de1ad5
ER
1186 fi
1187fi
351f379b
JR
1188if [ -x /sbin/new-kernel-pkg ]; then
1189 /sbin/new-kernel-pkg --initrdfile=%{initrd_dir}/initrd-%{kernel_release}.gz --install %{kernel_release} --banner "PLD Linux (%{pld_release})%{?alt_kernel: / %{alt_kernel}}"
0bb27755
ER
1190fi
1191if [ -x /sbin/rc-boot ]; then
351f379b 1192 /sbin/rc-boot 1>&2 || :
a5585a68 1193fi
a5585a68 1194
351f379b
JR
1195%post vmlinux
1196mv -f /boot/vmlinux{,.old} 2> /dev/null
1197%{?alt_kernel:mv -f /boot/vmlinux-%{alt_kernel}{,.old} 2> /dev/null}
1198ln -sf vmlinux-%{kernel_release} /boot/vmlinux
1199%{?alt_kernel:ln -sf vmlinux-%{kernel_release} /boot/vmlinux-%{alt_kernel}}
1200
351f379b
JR
1201%post drm
1202%depmod %{kernel_release}
a5585a68 1203
351f379b
JR
1204%postun drm
1205%depmod %{kernel_release}
a5585a68 1206
351f379b
JR
1207%post pcmcia
1208%depmod %{kernel_release}
a5585a68 1209
351f379b
JR
1210%postun pcmcia
1211%depmod %{kernel_release}
a5585a68 1212
351f379b
JR
1213%post sound-alsa
1214%depmod %{kernel_release}
a5585a68 1215
351f379b
JR
1216%postun sound-alsa
1217%depmod %{kernel_release}
a5585a68 1218
351f379b
JR
1219%post sound-oss
1220%depmod %{kernel_release}
a5585a68 1221
351f379b
JR
1222%postun sound-oss
1223%depmod %{kernel_release}
a5585a68
AM
1224
1225%post headers
351f379b 1226ln -snf %{basename:%{_kernelsrcdir}} %{_prefix}/src/linux%{_alt_kernel}
a5585a68
AM
1227
1228%postun headers
351f379b
JR
1229if [ "$1" = "0" ]; then
1230 if [ -L %{_prefix}/src/linux%{_alt_kernel} ]; then
1231 if [ "$(readlink %{_prefix}/src/linux%{_alt_kernel})" = "linux%{_alt_kernel}-%{version}" ]; then
1232 rm -f %{_prefix}/src/linux%{_alt_kernel}
a5585a68
AM
1233 fi
1234 fi
1235fi
1236
351f379b
JR
1237%triggerin module-build -- %{name} = %{epoch}:%{version}-%{release}
1238ln -sfn %{_kernelsrcdir} /lib/modules/%{kernel_release}/build
1239ln -sfn %{_kernelsrcdir} /lib/modules/%{kernel_release}/source
1240
1241%triggerun module-build -- %{name} = %{epoch}:%{version}-%{release}
1242if [ "$1" = 0 ]; then
1243 rm -f /lib/modules/%{kernel_release}/{build,source}
1244fi
1245
a5585a68
AM
1246%files
1247%defattr(644,root,root,755)
a5585a68 1248%ifarch sparc sparc64
351f379b 1249/boot/vmlinux.aout-%{kernel_release}
a5585a68
AM
1250%endif
1251%ifarch ia64
351f379b
JR
1252/boot/efi/vmlinuz-%{kernel_release}
1253%endif
1254/boot/vmlinuz-%{kernel_release}
1255/boot/System.map-%{kernel_release}
1256%ghost %{initrd_dir}/initrd-%{kernel_release}.gz
ae1c66e5 1257/lib/firmware/%{kernel_release}
351f379b
JR
1258
1259%dir /lib/modules/%{kernel_release}
1260%dir /lib/modules/%{kernel_release}/kernel
351f379b 1261/lib/modules/%{kernel_release}/kernel/arch
351f379b
JR
1262/lib/modules/%{kernel_release}/kernel/crypto
1263/lib/modules/%{kernel_release}/kernel/drivers
101ae904 1264%if %{have_drm}
351f379b
JR
1265%exclude /lib/modules/%{kernel_release}/kernel/drivers/gpu
1266%endif
1267/lib/modules/%{kernel_release}/kernel/fs
351f379b 1268/lib/modules/%{kernel_release}/kernel/kernel
351f379b
JR
1269/lib/modules/%{kernel_release}/kernel/lib
1270/lib/modules/%{kernel_release}/kernel/net
fecce547 1271/lib/modules/%{kernel_release}/kernel/mm
101ae904 1272%if %{have_sound}
351f379b
JR
1273%dir /lib/modules/%{kernel_release}/kernel/sound
1274/lib/modules/%{kernel_release}/kernel/sound/ac97_bus.ko*
1275/lib/modules/%{kernel_release}/kernel/sound/sound*.ko*
1276%ifnarch sparc
1277%exclude /lib/modules/%{kernel_release}/kernel/drivers/media/video/cx88/cx88-alsa.ko*
1278%exclude /lib/modules/%{kernel_release}/kernel/drivers/media/video/em28xx/em28xx-alsa.ko*
1279%exclude /lib/modules/%{kernel_release}/kernel/drivers/media/video/saa7134/saa7134-alsa.ko*
1280%endif
1281%endif
1282%dir /lib/modules/%{kernel_release}/misc
101ae904 1283%if %{have_pcmcia}
351f379b
JR
1284%exclude /lib/modules/%{kernel_release}/kernel/drivers/pcmcia/[!p]*
1285%exclude /lib/modules/%{kernel_release}/kernel/drivers/pcmcia/pd6729.ko*
1286%exclude /lib/modules/%{kernel_release}/kernel/drivers/*/pcmcia
1287%if %{without rescuecd}
1288%exclude /lib/modules/%{kernel_release}/kernel/drivers/ata/pata_pcmcia.ko*
1289%exclude /lib/modules/%{kernel_release}/kernel/drivers/bluetooth/*_cs.ko*
1290%exclude /lib/modules/%{kernel_release}/kernel/drivers/isdn/hardware/avm/avm_cs.ko*
1291%exclude /lib/modules/%{kernel_release}/kernel/drivers/isdn/hardware/avm/b1pcmcia.ko*
1292%exclude /lib/modules/%{kernel_release}/kernel/drivers/telephony/ixj_pcmcia.ko*
1293%exclude /lib/modules/%{kernel_release}/kernel/drivers/usb/gadget/g_midi.ko*
1294%endif
1295%exclude /lib/modules/%{kernel_release}/kernel/drivers/ide/ide-cs.ko*
1296%exclude /lib/modules/%{kernel_release}/kernel/drivers/net/wireless/*_cs.ko*
1297%exclude /lib/modules/%{kernel_release}/kernel/drivers/net/wireless/b43
1298%exclude /lib/modules/%{kernel_release}/kernel/drivers/net/wireless/hostap/hostap_cs.ko*
1299%exclude /lib/modules/%{kernel_release}/kernel/drivers/net/wireless/libertas/*_cs.ko*
1300%exclude /lib/modules/%{kernel_release}/kernel/drivers/parport/parport_cs.ko*
1301%exclude /lib/modules/%{kernel_release}/kernel/drivers/serial/serial_cs.ko*
1302%exclude /lib/modules/%{kernel_release}/kernel/drivers/usb/host/sl811_cs.ko*
1303%endif
101ae904 1304%if %{with myown}
1305/lib/modules/%{kernel_release}/kernel/sound
1306%endif
6d54bd67
ER
1307
1308%dir %{_sysconfdir}/modprobe.d/%{kernel_release}
1309
1310# provided by build
1311/lib/modules/%{kernel_release}/modules.order
5ebe7534 1312/lib/modules/%{kernel_release}/modules.builtin
6d54bd67
ER
1313
1314# rest modules.* are ghost (regenerated by post depmod -a invocation)
1315%ghost /lib/modules/%{kernel_release}/modules.alias
1316%ghost /lib/modules/%{kernel_release}/modules.alias.bin
1317%ghost /lib/modules/%{kernel_release}/modules.ccwmap
1318%ghost /lib/modules/%{kernel_release}/modules.dep
1319%ghost /lib/modules/%{kernel_release}/modules.dep.bin
1320%ghost /lib/modules/%{kernel_release}/modules.ieee1394map
1321%ghost /lib/modules/%{kernel_release}/modules.inputmap
1322%ghost /lib/modules/%{kernel_release}/modules.isapnpmap
1323%ghost /lib/modules/%{kernel_release}/modules.ofmap
1324%ghost /lib/modules/%{kernel_release}/modules.pcimap
1325%ghost /lib/modules/%{kernel_release}/modules.seriomap
1326%ghost /lib/modules/%{kernel_release}/modules.symbols
1327%ghost /lib/modules/%{kernel_release}/modules.symbols.bin
1328%ghost /lib/modules/%{kernel_release}/modules.usbmap
1329
351f379b
JR
1330# symlinks pointing to kernelsrcdir
1331%ghost /lib/modules/%{kernel_release}/build
1332%ghost /lib/modules/%{kernel_release}/source
351f379b 1333
351f379b
JR
1334%ifarch alpha %{ix86} %{x8664} ppc ppc64 sparc sparc64
1335%files vmlinux
a5585a68 1336%defattr(644,root,root,755)
351f379b 1337/boot/vmlinux-%{kernel_release}
a5585a68
AM
1338%endif
1339
101ae904 1340%if %{have_drm}
351f379b 1341%files drm
a5585a68 1342%defattr(644,root,root,755)
351f379b 1343/lib/modules/%{kernel_release}/kernel/drivers/gpu
a5585a68
AM
1344%endif
1345
101ae904 1346%if %{have_pcmcia}
351f379b 1347%files pcmcia
a5585a68 1348%defattr(644,root,root,755)
351f379b
JR
1349/lib/modules/%{kernel_release}/kernel/drivers/pcmcia/*ko*
1350/lib/modules/%{kernel_release}/kernel/drivers/*/pcmcia
1351%exclude /lib/modules/%{kernel_release}/kernel/drivers/pcmcia/pcmcia*ko*
1352%if %{without rescuecd}
1353/lib/modules/%{kernel_release}/kernel/drivers/bluetooth/*_cs.ko*
1354/lib/modules/%{kernel_release}/kernel/drivers/isdn/hardware/avm/avm_cs.ko*
1355/lib/modules/%{kernel_release}/kernel/drivers/isdn/hardware/avm/b1pcmcia.ko*
1356/lib/modules/%{kernel_release}/kernel/drivers/telephony/ixj_pcmcia.ko*
1357%endif
1358/lib/modules/%{kernel_release}/kernel/drivers/ata/pata_pcmcia.ko*
1359/lib/modules/%{kernel_release}/kernel/drivers/ide/ide-cs.ko*
1360/lib/modules/%{kernel_release}/kernel/drivers/net/wireless/*_cs.ko*
1361/lib/modules/%{kernel_release}/kernel/drivers/net/wireless/b43
1362/lib/modules/%{kernel_release}/kernel/drivers/net/wireless/hostap/hostap_cs.ko*
1363/lib/modules/%{kernel_release}/kernel/drivers/net/wireless/libertas/*_cs.ko*
1364/lib/modules/%{kernel_release}/kernel/drivers/parport/parport_cs.ko*
1365/lib/modules/%{kernel_release}/kernel/drivers/serial/serial_cs.ko*
1366/lib/modules/%{kernel_release}/kernel/drivers/usb/host/sl811_cs.ko*
1367%endif
1368
101ae904 1369%if %{have_sound}
351f379b 1370%files sound-alsa
a5585a68 1371%defattr(644,root,root,755)
351f379b
JR
1372/lib/modules/%{kernel_release}/kernel/sound
1373%exclude %dir /lib/modules/%{kernel_release}/kernel/sound
1374%exclude /lib/modules/%{kernel_release}/kernel/sound/ac97_bus.ko*
1375%exclude /lib/modules/%{kernel_release}/kernel/sound/sound*.ko*
1376%if %{have_oss}
1377%exclude /lib/modules/%{kernel_release}/kernel/sound/oss
a5585a68 1378%endif
351f379b
JR
1379%ifnarch sparc
1380/lib/modules/%{kernel_release}/kernel/drivers/usb/gadget/g_midi.ko*
1381/lib/modules/%{kernel_release}/kernel/drivers/media/video/cx88/cx88-alsa.ko*
1382/lib/modules/%{kernel_release}/kernel/drivers/media/video/em28xx/em28xx-alsa.ko*
1383/lib/modules/%{kernel_release}/kernel/drivers/media/video/saa7134/saa7134-alsa.ko*
a5585a68
AM
1384%endif
1385
101ae904 1386%if %{have_oss}
351f379b 1387%files sound-oss
a5585a68 1388%defattr(644,root,root,755)
351f379b 1389/lib/modules/%{kernel_release}/kernel/sound/oss
a5585a68 1390%endif
a5585a68
AM
1391%endif
1392
fecce547 1393%files headers -f files.headers_exclude_kbuild
a5585a68 1394%defattr(644,root,root,755)
30f08736 1395%dir %{_kernelsrcdir}
351f379b
JR
1396%{_kernelsrcdir}/include
1397%dir %{_kernelsrcdir}/arch
1398%dir %{_kernelsrcdir}/arch/[!K]*
1399%{_kernelsrcdir}/arch/*/include
1400%dir %{_kernelsrcdir}/security
1401%dir %{_kernelsrcdir}/security/selinux
1402%{_kernelsrcdir}/security/selinux/include
1403%{_kernelsrcdir}/config-dist
1404%{_kernelsrcdir}/Module.symvers-dist
1405
fecce547 1406%files module-build -f files.mb_include_modulebuild_and_dirs
a5585a68 1407%defattr(644,root,root,755)
351f379b
JR
1408%ifarch ppc ppc64
1409%{_kernelsrcdir}/arch/powerpc/lib/crtsavres.*
1410%endif
fecce547 1411%exclude %dir %{_kernelsrcdir}/arch/m68knommu
1412%exclude %dir %{_kernelsrcdir}/arch/um
351f379b
JR
1413%{_kernelsrcdir}/arch/*/kernel/asm-offsets*
1414%{_kernelsrcdir}/arch/*/kernel/sigframe*.h
1415%{_kernelsrcdir}/drivers/lguest/lg.h
1416%{_kernelsrcdir}/kernel/bounds.c
1417%dir %{_kernelsrcdir}/scripts
351f379b
JR
1418%{_kernelsrcdir}/scripts/Kbuild.include
1419%{_kernelsrcdir}/scripts/Makefile*
1420%{_kernelsrcdir}/scripts/basic
960d2e94 1421%{_kernelsrcdir}/scripts/kconfig
1422%{_kernelsrcdir}/scripts/mkcompile_h
351f379b
JR
1423%{_kernelsrcdir}/scripts/mkmakefile
1424%{_kernelsrcdir}/scripts/mod
960d2e94 1425%{_kernelsrcdir}/scripts/module-common.lds
351f379b
JR
1426%{_kernelsrcdir}/scripts/setlocalversion
1427%{_kernelsrcdir}/scripts/*.c
1428%{_kernelsrcdir}/scripts/*.sh
351f379b
JR
1429%dir %{_kernelsrcdir}/scripts/selinux
1430%{_kernelsrcdir}/scripts/selinux/Makefile
9d6d5869
AM
1431%dir %{_kernelsrcdir}/scripts/selinux/genheaders
1432%{_kernelsrcdir}/scripts/selinux/genheaders/Makefile
1433%{_kernelsrcdir}/scripts/selinux/genheaders/*.c
c78e408d
PZ
1434%dir %{_kernelsrcdir}/scripts/selinux/mdp
1435%{_kernelsrcdir}/scripts/selinux/mdp/Makefile
1436%{_kernelsrcdir}/scripts/selinux/mdp/*.c
fecce547 1437%exclude %dir %{_kernelsrcdir}/security
1438%exclude %dir %{_kernelsrcdir}/security/selinux
a5585a68 1439
1848fd38 1440%if %{with doc}
a5585a68
AM
1441%files doc
1442%defattr(644,root,root,755)
d3a69071
ER
1443%dir %{_docdir}/%{name}-%{version}
1444
1445%{_docdir}/%{name}-%{version}/[!jkz]*
1446%{_docdir}/%{name}-%{version}/[jkz]*.txt
1447%{_docdir}/%{name}-%{version}/kbuild
1448%{_docdir}/%{name}-%{version}/kdump
2ddc4ac9 1449%{_docdir}/%{name}-%{version}/kvm
d3a69071
ER
1450%lang(ja) %{_docdir}/%{name}-%{version}/ja_JP
1451%lang(ko) %{_docdir}/%{name}-%{version}/ko_KR
1452%lang(zh_CN) %{_docdir}/%{name}-%{version}/zh_CN
1848fd38 1453%endif
a5585a68
AM
1454
1455%if %{with source}
fecce547 1456%files source -f files.source_exclude_modulebuild_and_dirs
a5585a68 1457%defattr(644,root,root,755)
351f379b
JR
1458%{_kernelsrcdir}/arch/*/[!Mik]*
1459%{_kernelsrcdir}/arch/*/kernel/[!M]*
351f379b
JR
1460%{_kernelsrcdir}/arch/ia64/install.sh
1461%{_kernelsrcdir}/arch/m68k/ifpsp060/[!M]*
1462%{_kernelsrcdir}/arch/m68k/ifpsp060/MISC
fecce547 1463%{_kernelsrcdir}/arch/m68k/install.sh
351f379b
JR
1464%{_kernelsrcdir}/arch/parisc/install.sh
1465%{_kernelsrcdir}/arch/x86/ia32/[!M]*
1466%{_kernelsrcdir}/arch/ia64/kvm
1467%{_kernelsrcdir}/arch/powerpc/kvm
1468%ifarch ppc ppc64
1469%exclude %{_kernelsrcdir}/arch/powerpc/lib/crtsavres.*
1470%endif
1471%{_kernelsrcdir}/arch/s390/kvm
1472%{_kernelsrcdir}/arch/x86/kvm
1473%exclude %{_kernelsrcdir}/arch/*/kernel/asm-offsets*
1474%exclude %{_kernelsrcdir}/arch/*/kernel/sigframe*.h
1475%exclude %{_kernelsrcdir}/drivers/lguest/lg.h
1476%{_kernelsrcdir}/block
1477%{_kernelsrcdir}/crypto
1478%{_kernelsrcdir}/drivers
1479%{_kernelsrcdir}/firmware
1480%{_kernelsrcdir}/fs
1481%if %{with grsecurity} && %{without rescuecd}
1482%{_kernelsrcdir}/grsecurity
1483%endif
1484%{_kernelsrcdir}/init
1485%{_kernelsrcdir}/ipc
1486%{_kernelsrcdir}/kernel
1487%exclude %{_kernelsrcdir}/kernel/bounds.c
1488%{_kernelsrcdir}/lib
1489%{_kernelsrcdir}/mm
1490%{_kernelsrcdir}/net
1491%{_kernelsrcdir}/virt
1492%{_kernelsrcdir}/samples
1493%{_kernelsrcdir}/scripts/*
1494%exclude %{_kernelsrcdir}/scripts/Kbuild.include
1495%exclude %{_kernelsrcdir}/scripts/Makefile*
1496%exclude %{_kernelsrcdir}/scripts/basic
1497%exclude %{_kernelsrcdir}/scripts/kconfig
960d2e94 1498%exclude %{_kernelsrcdir}/scripts/mkcompile_h
351f379b
JR
1499%exclude %{_kernelsrcdir}/scripts/mkmakefile
1500%exclude %{_kernelsrcdir}/scripts/mod
960d2e94 1501%exclude %{_kernelsrcdir}/scripts/module-common.lds
351f379b
JR
1502%exclude %{_kernelsrcdir}/scripts/setlocalversion
1503%exclude %{_kernelsrcdir}/scripts/*.c
1504%exclude %{_kernelsrcdir}/scripts/*.sh
960d2e94 1505%exclude %dir %{_kernelsrcdir}/scripts/selinux
1506%exclude %{_kernelsrcdir}/scripts/selinux/Makefile
c78e408d
PZ
1507%exclude %dir %{_kernelsrcdir}/scripts/selinux/genheaders
1508%exclude %{_kernelsrcdir}/scripts/selinux/genheaders/Makefile
1509%exclude %{_kernelsrcdir}/scripts/selinux/genheaders/*.c
960d2e94 1510%exclude %dir %{_kernelsrcdir}/scripts/selinux/mdp
1511%exclude %{_kernelsrcdir}/scripts/selinux/mdp/Makefile
1512%exclude %{_kernelsrcdir}/scripts/selinux/mdp/*.c
351f379b
JR
1513%{_kernelsrcdir}/sound
1514%{_kernelsrcdir}/security
1515%exclude %{_kernelsrcdir}/security/selinux/include
fecce547 1516%{_kernelsrcdir}/tools
351f379b
JR
1517%{_kernelsrcdir}/usr
1518%{_kernelsrcdir}/COPYING
1519%{_kernelsrcdir}/CREDITS
1520%{_kernelsrcdir}/MAINTAINERS
1521%{_kernelsrcdir}/README
1522%{_kernelsrcdir}/REPORTING-BUGS
a5585a68 1523%endif
This page took 0.535656 seconds and 4 git commands to generate.