summaryrefslogtreecommitdiff
path: root/repo/linux/linux.xibuild
diff options
context:
space:
mode:
authordavidovski <david@davidovski.xyz>2022-04-14 22:28:41 +0100
committerdavidovski <david@davidovski.xyz>2022-04-14 22:28:41 +0100
commit7cc715c1249422ddf91987be64a35eef43e3e62d (patch)
treefd706e77c0eaec256acf3dc24e781b5fc9f59d09 /repo/linux/linux.xibuild
parent734e13526a2ec3ced7f085e444fc9525dfad348b (diff)
added auto create file
Diffstat (limited to 'repo/linux/linux.xibuild')
-rw-r--r--repo/linux/linux.xibuild31
1 files changed, 23 insertions, 8 deletions
diff --git a/repo/linux/linux.xibuild b/repo/linux/linux.xibuild
index 72bd22d..1abf645 100644
--- a/repo/linux/linux.xibuild
+++ b/repo/linux/linux.xibuild
@@ -27,17 +27,17 @@ build () {
package () {
local kernver="$(cat version)"
- local modulesdir="$PKG_DEST/usr/lib/modules/$PKG_VER"
+ local modulesdir="$PKG_DEST/usr/lib/modules/$kernver"
echo "Installing boot image..."
mkdir -p $PKG_DEST/boot
- cp arch/x86/boot/bzImage $PKG_DEST/boot/vmlinuz-$PKG_VER
- cp System.map $PKG_DEST/boot/System.map-$PKG_VER
- cp .config $PKG_DEST/boot/config-$PKG_VER
+ cp arch/x86/boot/bzImage $PKG_DEST/boot/vmlinuz-$kernver
+ cp System.map $PKG_DEST/boot/System.map-$kernver
+ cp .config $PKG_DEST/boot/config-$kernver
- install -d $PKG_DEST/usr/share/doc/linux-$PKG_VER
- cp -r Documentation/* $PKG_DEST/usr/share/doc/linux-$PKG_VER
+ install -d $PKG_DEST/usr/share/doc/linux-$kernver
+ cp -r Documentation/* $PKG_DEST/usr/share/doc/linux-$kernver
install -m755 -d $PKG_DEST/etc/modprobe.d
cat > $PKG_DEST/etc/modprobe.d/usb.conf << "EOF"
@@ -51,7 +51,22 @@ EOF
echo "Installing modules..."
make INSTALL_MOD_PATH="$PKG_DEST/usr" INSTALL_MOD_STRIP=1 modules_install
- #rm "$modulesdir"/source
- #rm "$modulesdir"/build
+ builddir=$modulesdir/build
+ rm $modulesdir/source
+ rm $builddir
+ mkdir $builddir
+ echo "Installing build files..."
+ install -D -m644 .config "$builddir"
+ install -D -m644 Makefile "$builddir"
+ install -D -m644 Module.symvers "$builddir"
+ install -D -m644 System.map "$builddir"
+ install -D -m644 version "$builddir"
+ install -D -m644 vmlinux "$builddir"
+ install -D -m644 kernel/Makefile "$builddir/kernel/Makefile"
+ install -D -m644 arch/x86/Makefile "$builddir/arch/x86/Makefile"
+ cp -r scripts "$builddir"
+
+ install -D tools/objtool/objtool "$builddir/tools/objtool"
+ install -D tools/bpf/resolve_btfids/resolve_btfids "$builddir/tools/bpf/resolve_btfids"
}