wok-6.x view linux-libre-module-headers/receipt @ rev 21182

get-xnviewmp: rm XnView (not XnViewMP)
author Hans-G?nter Theisgen
date Tue Apr 02 16:53:10 2019 +0100 (2019-04-02)
parents 9e8d7fd12ee2
children
line source
1 # SliTaz package receipt.
3 PACKAGE="linux-libre-module-headers"
4 VERSION="3.18.129-gnu"
5 CATEGORY="development"
6 SHORT_DESC="Header files and scripts for building modules for Linux Libre kernel."
7 MAINTAINER="gokhlayeh@slitaz.org"
8 LICENSE="GPL2"
9 PROVIDE="linux-module-headers"
10 DEPENDS="slitaz-toolchain"
11 WANTED="linux-libre"
12 WEB_SITE="http://www.fsfla.org/svnwiki/selibre/linux-libre/"
13 KVERSION=$VERSION-slitaz
15 # Rules to gen a SliTaz package suitable for Tazpkg.
16 genpkg_rules()
17 {
18 local path
19 path=usr/src/linux-$KVERSION
20 mkdir -p $fs/lib/modules/$KVERSION
21 ln -sf /$path $fs/lib/modules/$KVERSION/build
22 install -D -m644 $src/Makefile \
23 $fs/$path/Makefile
24 install -D -m644 $src/kernel/Makefile \
25 $fs/$path/kernel/Makefile
26 install -D -m644 $src/.config \
27 $fs/$path/.config
28 mkdir -p $fs/$path/include
30 for i in acpi asm-generic config generated linux math-emu media net pcmcia scsi sound trace video xen; do
31 cp -a $src/include/$i $fs/$path/include/
32 done
34 # copy arch includes for external modules
35 mkdir -p $fs/$path/arch/x86
36 cp -a $src/arch/x86/include $fs/$path/arch/x86/
38 # copy files necessary for later builds, like nvidia and vmware
39 cp -a $src/Module.symvers-modules $fs/$path/Module.symvers
40 cp -a $src/scripts $fs/$path
41 # fix permissions on scripts dir
42 chmod og-w -R $fs/$path/scripts
43 mkdir -p $fs/$path/.tmp_versions
45 mkdir -p $fs/$path/arch/x86/kernel
46 cp -a $src/arch/x86/Makefile $fs/$path/arch/x86/
47 cp -a $src/arch/x86/Makefile_32.cpu $fs/$path/arch/x86/
48 cp -a $src/arch/x86/kernel/asm-offsets.s $fs/$path/arch/x86/kernel/
50 # add headers for lirc package
51 mkdir -p $fs/$path/drivers/media/video
53 # add docbook makefile
54 install -D -m644 $src/Documentation/DocBook/Makefile \
55 $fs/$path/Documentation/DocBook/Makefile
57 # add dm headers
58 mkdir -p $fs/$path/drivers/md
59 cp -a $src/drivers/md/*.h $fs/$path/drivers/md
61 # add inotify.h
62 mkdir -p $fs/$path/include/linux
63 cp -a $src/include/linux/inotify.h $fs/$path/include/linux/
65 # add wireless headers
66 mkdir -p $fs/$path/net/mac80211/
67 cp -a $src/net/mac80211/*.h $fs/$path/net/mac80211/
69 # add dvb headers for external modules
70 # in reference to:
71 # http://bugs.archlinux.org/task/9912
72 mkdir -p $fs/$path/drivers/media/dvb/dvb-core
74 # add dvb headers for external modules
75 # in reference to:
76 # http://bugs.archlinux.org/task/11194
77 if [ -d $src/include/config/dvb/ ]; then
78 mkdir -p $fs/$path/include/config/dvb/
79 cp $src/include/config/dvb/*.h $fs/$path/include/config/dvb/
80 fi
82 # add dvb headers for http://mcentral.de/hg/~mrec/em28xx-new
83 # in reference to:
84 # http://bugs.archlinux.org/task/13146
85 mkdir -p $fs/$path/drivers/media/dvb/frontends/
87 # add dvb headers
88 # in reference to:
89 # http://bugs.archlinux.org/task/20402
90 mkdir -p $fs/$path/drivers/media/dvb/dvb-usb
91 mkdir -p $fs/$path/drivers/media/dvb/frontends
92 mkdir -p $fs/$path/drivers/media/common/tuners
94 # add xfs and shmem for aufs building
95 mkdir -p $fs/$path/fs/xfs
96 mkdir -p $fs/$path/mm
98 # add headers vor virtualbox
99 # in reference to:
100 # http://bugs.archlinux.org/task/14568
101 cp -a $src/include/drm $fs/$path/include/
103 # add headers for broadcom wl
104 # in reference to:
105 # http://bugs.archlinux.org/task/14568
106 cp -a $src/include/trace $fs/$path/include/
107 # add headers for crypto modules
108 # in reference to:
109 # http://bugs.archlinux.org/task/22081
110 cp -a $src/include/crypto $fs/$path/include/
111 # copy in Kconfig files
112 for i in $(find . -name "Kconfig*"); do
113 mkdir -p $fs/$path/$(echo $i | sed 's|/Kconfig.*||')
114 cp -a $src/$i $fs/$path/$i
115 done
117 chown -R root.root $fs/$path
118 find $fs/$path -type d -exec chmod 755 {} \;
119 # remove unneeded architectures
120 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}
122 }
124 pre_remove() {
125 if [ -e "$1/usr/src/linux" ]; then
126 rm -rf "$1/usr/src/linux"
127 fi
128 }
130 post_install() {
131 # Added soft link to make it easier to point to kernel folder
132 [ -L "$1/usr/src/linux" ] && rm -f "$1/usr/src/linux"
133 ln -sf /usr/src/linux-$KVERSION "$1/usr/src/linux"
134 }