--- admin/PlamoBuild-template-20180815 2018-08-15 16:18:50.000000000 +0900 +++ plamo/01_minimum/devel.txz/old/kernel_headers-20181201/PlamoBuild.kernel_headers-4.12.14_plamo@LV@ 2018-12-01 09:44:00.000000000 +0900 @@ -1,19 +1,28 @@ -#!/bin/sh +#!/bin/sh -x ###################################################################### -url="" +url="https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.12.14.tar.xz + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/UNICON/vd_unicon-kernel-20170708-4.12.patch + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/UNICON/vd_unicon-kernel-fonts-20140614.patch.bz2 + https://github.com/sfjro/aufs4-standalone.git + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/mcp/4.12-panic_beep.patch + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/mcp/4.12-morse_code_panics.patch + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/toi/tuxonice-for-linux-4.12.14-2017-09-20.patch.bz2 + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/ovlfs/overlayfs-allow_unprivileged_mounts.patch + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/rpi/rpi-4.12.14-20170906-6fe4193.patch.xz + ftp://plamo.linet.gr.jp/pub/Plamo-test/kernelsrc_patches/config-4.12.14-plamo@LV@" verify= digest= -branch= -commitid= -pkgbase= -vers= +branch[3]=aufs4.12 +commitid[3]=31266c0 +pkgbase=kernel_headers +vers=4.12.14_plamo@LV@ arch=`uname -m` build=P1 -src=$pkgbase-$vers +src=linux-4.12.14 patchfiles="" OPT_CONFIG="" -DOCS="README" +DOCS="" template=20180815 tmplurl=ftp://plamo.linet.gr.jp/pub/Plamo-src/admin ###################################################################### @@ -28,6 +37,9 @@ fi fscheck +case `uname -m` in i686) lv=SMP ;; x86_64) lv=64 ;; armv7l) lv=RPi2 ;; esac +url=${url/@LV@/$lv} ; vers=${vers/@LV@/$lv} +case `uname -m` in i686|x86_64) arch=i386 ;; armv7l) arch=arm ;; esac prepare "$@" if [ $opt_download -eq 1 ] ; then download_sources @@ -37,6 +49,27 @@ if [ -d ${B[$i]} ] ; then rm -rf ${B[$i]} ; fi ; cp -a ${S[$i]} ${B[$i]} done apply_patches + cd $B + patch -Np1 -i $W/vd_unicon-kernel-20170708-4.12.patch + bunzip2 -c $W/vd_unicon-kernel-fonts-20140614.patch.bz2 | patch -Np1 -i - + patch -Np1 -i $W/aufs4-standalone/aufs4-kbuild.patch + patch -Np1 -i $W/aufs4-standalone/aufs4-base.patch + patch -Np1 -i $W/aufs4-standalone/aufs4-mmap.patch + patch -Np1 -i $W/aufs4-standalone/aufs4-standalone.patch + cp -av $W/aufs4-standalone/Documentation . + cp -av $W/aufs4-standalone/fs . + cp -pv $W/aufs4-standalone/include/uapi/linux/aufs_type.h include/uapi/linux + patch -Np1 -i $W/4.12-panic_beep.patch + patch -Np1 -i $W/4.12-morse_code_panics.patch + bunzip2 -c $W/tuxonice-for-linux-4.12.14-2017-09-20.patch.bz2 | patch -Np1 -i - + chmod 755 scripts/tuxonice_output_to_csv.sh + patch -Np1 -i $W/overlayfs-allow_unprivileged_mounts.patch + if [ `uname -m` == armv7l ] ; then + unxz -c $W/rpi-4.12.14-20170906-6fe4193.patch.xz | patch -Np1 -i - + chmod 755 drivers/net/wireless/realtek/rtl8192cu/{clean,runwpa,wlan0dhcp} + chmod 755 scripts/{knlinfo,mkknlimg} + fi + cp -p $W/config-4.12.14-plamo$lv .config for i in `seq 0 $((${#B[@]} - 1))` ; do cd ${B[$i]} if [ -x configure ] ; then @@ -49,7 +82,7 @@ if [ $opt_build -eq 1 ] ; then for i in `seq 0 $((${#B[@]} - 1))` ; do cd ${B[$i]} - if [ -f Makefile ] ; then + false && if [ -f Makefile ] ; then make fi done @@ -62,18 +95,20 @@ for i in `seq 0 $((${#B[@]} - 1))` ; do cd ${B[$i]} if [ -f Makefile ] ; then - make install DESTDIR=$P + make headers_install INSTALL_HDR_PATH=$P/usr fi done + find $P/usr/include \( -name ".install" -o -name "..install.cmd" \) \ + -exec rm {} \; touch $W/i.et cd $W TZ=UTC find $P ! -type l -newer i.st ! -newer i.et \ -exec touch -t `date -u '+%m%d0000'` {} \; compress + install -d $docdir/$src setup_docdir convert_links - tar cvpf $pkg.tar -C $P `cd $P ; find usr/bin | tail -n+2` - tar rvpf $pkg.tar -C $P `cd $P ; find usr/share/man/man1 | tail -n+2` + tar cvpf $pkg.tar -C $P `cd $P ; find usr/include -maxdepth 1 | tail -n+2` tar rvpf $pkg.tar -C $P usr/share/doc/$src TZ=UTC touch -t `date -u '+%m%d0000'` $pkg.tar xz $pkg.tar ; touch $pkg.tar.xz ; mv $pkg.tar.xz $pkg.txz