Skip to content

Commit

Permalink
Fixed packaging of kernel modules
Browse files Browse the repository at this point in the history
  • Loading branch information
dimkr committed Apr 25, 2019
1 parent 85a03a5 commit 14eddea
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions ci/build_kernel.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@

KVER=4.9

here=`pwd`

minor=`wget -q -O- http://linux-libre.fsfla.org/pub/linux-libre/releases/LATEST-$KVER.N/ | grep -F patch-$KVER-gnu | head -n 1 | cut -f 9 -d . | cut -f 1 -d -`
[ ! -f kernel-cache/linux-libre-$KVER-gnu.tar.xz ] && wget -O kernel-cache/linux-libre-$KVER-gnu.tar.xz http://linux-libre.fsfla.org/pub/linux-libre/releases/LATEST-$KVER.0/linux-libre-$KVER-gnu.tar.xz
[ ! -f kernel-cache/patch-$KVER-gnu-$KVER.$minor-gnu ] && wget -O- https://www.linux-libre.fsfla.org/pub/linux-libre/releases/LATEST-$KVER.N/patch-$KVER-gnu-$KVER.$minor-gnu.xz | xz -d > kernel-cache/patch-$KVER-gnu-$KVER.$minor-gnu
Expand All @@ -39,7 +41,7 @@ patch -R -p 1 < ../kernel-cache/ath9k_htc_do_not_use_bulk_on_ep3_and_ep4.patch
sed s/'SUBLEVEL = .*'/'SUBLEVEL = 0'/ -i Makefile
cp -f ../kernel/config .config

export PATH=`pwd`/ci:$PATH
export PATH=$here/ci:$PATH
kmake="make -j `nproc` CROSS_COMPILE=arm-none-eabi- ARCH=arm"

$kmake olddefconfig
Expand All @@ -66,6 +68,6 @@ vbutil_kernel --pack ../devsus-kernel/boot/vmlinux.kpart \
cd ..

# put kernel modules in /lib/modules
$kmake -C linux-$KVER INSTALL_MOD_PATH=devsus-kernel modules_install
$kmake -C linux-$KVER INSTALL_MOD_PATH=$here/devsus-kernel modules_install
rm -f devsus-kernel/lib/modules/$KVER.0-gnu/{build,source}
tar -c devsus-kernel | gzip -1 > devsus-kernel.tar.gz

0 comments on commit 14eddea

Please sign in to comment.