wok-6.x annotate linux-module-headers/receipt @ rev 6710

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