wok-current view linux-module-headers/receipt @ rev 7572

Up: whois to 5.0.10.
author Christopher Rogers <slaxemulator@gmail.com>
date Thu Dec 09 11:22:50 2010 +0000 (2010-12-09)
parents a242ab6705d6
children 645cf2faf482
line source
1 # SliTaz package receipt.
3 PACKAGE="linux-module-headers"
4 VERSION="2.6.36"
5 CATEGORY="development"
6 SHORT_DESC="Header files and scripts for building modules for linux kernel."
7 MAINTAINER="slaxemulator@gmail.com"
8 DEPENDS="slitaz-toolchain"
9 WANTED="linux"
10 WEB_SITE="http://kernel.org/"
11 KVERSION=$VERSION-slitaz
13 # Rules to gen a SliTaz package suitable for Tazpkg.
14 genpkg_rules()
15 {
16 local path
17 path=usr/src/linux-$KVERSION
18 mkdir -p $fs/lib/modules/$KVERSION
19 ln -sf /$path $fs/lib/modules/$KVERSION/build
20 install -D -m644 $src/Makefile \
21 $fs/$path/Makefile
22 install -D -m644 $src/kernel/Makefile \
23 $fs/$path/kernel/Makefile
24 install -D -m644 $src/.config \
25 $fs/$path/.config
26 mkdir -p $fs/$path/include
28 # Added soft link to make it easier to point to kernel folder
29 ln -s linux-$KVERSION $fs/usr/src/linux
31 for i in acpi asm-generic config generated linux math-emu media net pcmcia scsi sound trace video; do
32 cp -a $src/include/$i $fs/$path/include/
33 done
35 # copy arch includes for external modules
36 mkdir -p $fs/$path/arch/x86
37 cp -a $src/arch/x86/include $fs/$path/arch/x86/
39 # copy files necessary for later builds, like nvidia and vmware
40 cp -a $src/Module.symvers $fs/$path
41 cp -a $src/scripts $fs/$path
42 # fix permissions on scripts dir
43 chmod og-w -R $fs/$path/scripts
44 mkdir -p $fs/$path/.tmp_versions
46 mkdir -p $fs/$path/arch/x86/kernel
47 cp -a $src/arch/x86/Makefile $fs/$path/arch/x86/
48 cp -a $src/arch/x86/Makefile_32.cpu $fs/$path/arch/x86/
49 cp -a $src/arch/x86/kernel/asm-offsets.s $fs/$path/arch/x86/kernel/
51 # add headers for lirc package
52 mkdir -p $fs/$path/drivers/media/video
53 cp -a $src/drivers/media/video/*.h $fs/$path/drivers/media/video/
55 for i in bt8xx cpia2 cx25840 cx88 em28xx et61x251 pwc saa7134 sn9c102 usbvideo zc0301; do
56 mkdir -p $fs/$path/drivers/media/video/$i
57 cp -a $src/drivers/media/video/$i/*.h $fs/$path/drivers/media/video/$i
58 done
60 # add docbook makefile
61 install -D -m644 $src/Documentation/DocBook/Makefile \
62 $fs/$path/Documentation/DocBook/Makefile
64 # add dm headers
65 mkdir -p $fs/$path/drivers/md
66 cp -a $src/drivers/md/*.h $fs/$path/drivers/md
68 # add inotify.h
69 mkdir -p $fs/$path/include/linux
70 cp -a $src/include/linux/inotify.h $fs/$path/include/linux/
72 # add wireless headers
73 mkdir -p $fs/$path/net/mac80211/
74 cp -a $src/net/mac80211/*.h $fs/$path/net/mac80211/
76 # add dvb headers for external modules
77 # in reference to:
78 # http://bugs.archlinux.org/task/9912
79 mkdir -p $fs/$path/drivers/media/dvb/dvb-core
80 cp -a $src/drivers/media/dvb/dvb-core/*.h $fs/$path/drivers/media/dvb/dvb-core/
82 # add dvb headers for external modules
83 # in reference to:
84 # http://bugs.archlinux.org/task/11194
85 if [ -d $src/include/config/dvb/ ]; then
86 mkdir -p $fs/$path/include/config/dvb/
87 cp $src/include/config/dvb/*.h $fs/$path/include/config/dvb/
88 fi
90 # add dvb headers for http://mcentral.de/hg/~mrec/em28xx-new
91 # in reference to:
92 # http://bugs.archlinux.org/task/13146
93 mkdir -p $fs/$path/drivers/media/dvb/frontends/
94 cp -a $src/drivers/media/dvb/frontends/lgdt330x.h $fs/$path/drivers/media/dvb/frontends/
95 cp -a $src/drivers/media/video/msp3400-driver.h $fs/$path/drivers/media/dvb/frontends/
97 # add dvb headers
98 # in reference to:
99 # http://bugs.archlinux.org/task/20402
100 mkdir -p $fs/$path/drivers/media/dvb/dvb-usb
101 cp -a $src/drivers/media/dvb/dvb-usb/*.h $fs/$path/drivers/media/dvb/dvb-usb/
102 mkdir -p $fs/$path/drivers/media/dvb/frontends
103 cp -a $src/drivers/media/dvb/frontends/*.h $fs/$path/drivers/media/dvb/frontends/
104 mkdir -p $fs/$path/drivers/media/common/tuners
105 cp -a $src/drivers/media/common/tuners/*.h $fs/$path/drivers/media/common/tuners/
107 # add xfs and shmem for aufs building
108 mkdir -p $fs/$path/fs/xfs
109 mkdir -p $fs/$path/mm
110 cp -a $src/fs/xfs/xfs_sb.h $fs/$path/fs/xfs/xfs_sb.h
112 # add headers vor virtualbox
113 # in reference to:
114 # http://bugs.archlinux.org/task/14568
115 cp -a $src/include/drm $fs/$path/include/
117 # add headers for broadcom wl
118 # in reference to:
119 # http://bugs.archlinux.org/task/14568
120 cp -a $src/include/trace $fs/$path/include/
122 # copy in Kconfig files
123 for i in $(find . -name "Kconfig*"); do
124 mkdir -p $fs/$path/$(echo $i | sed 's|/Kconfig.*||')
125 cp -a $src/$i $fs/$path/$i
126 done
128 chown -R root.root $fs/$path
129 find $fs/$path -type d -exec chmod 755 {} \;
130 # remove unneeded architectures
131 rm -rf $fs/$path/arch/{alpha,arm,arm26,avr32,blackfin,cris,frv,h8300,ia64,m32r,m68k,m68knommu,mips,microblaze,mn10300,parisc,powerpc,ppc,s390,sh,sh64,sparc,sparc64,um,v850,xtensa}
133 }