summaryrefslogtreecommitdiffstats
path: root/core/modules/kernel-vanilla
diff options
context:
space:
mode:
authorSimon Rettberg2017-03-01 10:02:21 +0100
committerSimon Rettberg2017-03-01 10:02:21 +0100
commit713bde49a578fd4f29bdcf34ea049d60f9823763 (patch)
tree5f57ad0cbba90a1afe408e4d5b78ed14e3bae906 /core/modules/kernel-vanilla
parentAdd bash shebangs to all our includes: (diff)
downloadmltk-713bde49a578fd4f29bdcf34ea049d60f9823763.tar.gz
mltk-713bde49a578fd4f29bdcf34ea049d60f9823763.tar.xz
mltk-713bde49a578fd4f29bdcf34ea049d60f9823763.zip
[kernel-vanilla] Clone and copy proprietary firmware from official repo on kernel.org
Diffstat (limited to 'core/modules/kernel-vanilla')
-rw-r--r--core/modules/kernel-vanilla/module.build9
1 files changed, 9 insertions, 0 deletions
diff --git a/core/modules/kernel-vanilla/module.build b/core/modules/kernel-vanilla/module.build
index 63c64e7c..19615309 100644
--- a/core/modules/kernel-vanilla/module.build
+++ b/core/modules/kernel-vanilla/module.build
@@ -44,6 +44,12 @@ fetch_source() {
fi
# remember the current kernel version
echo "${SYSTEM_KERNEL_LONG}" > ksrc/KVERSION
+ # Fetch all the firmware
+ if ! [ -s "./fw/Makefile" ]; then
+ rm -rf -- "./fw"
+ git clone "git://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git" "./fw" || perror "Could not clone linux-firmware repo."
+ rm -rf -- ./fw/LICENSE.* ./fw/*.txt
+ fi
}
build() {
@@ -76,6 +82,9 @@ build() {
make INSTALL_MOD_PATH="${MODULE_BUILD_DIR}" INSTALL_MOD_STRIP=1 modules_install || perror "make modules_install failed in ${MODULE_BUILD_DIR}."
cd - 2> /dev/null
+ # copy most recent firmware
+ cp -r ./fw/* "${MODULE_BUILD_DIR}/lib/firmware/" || perror "Could not copy linux-firmware to '${MODULE_BUILD_DIR}/lib/firmware/'"
+
# copy kernel to build
cp ksrc/arch/x86/boot/bzImage "${MODULE_BUILD_DIR}/kernel"
pinfo "Kernel was successfully built at ${MODULE_BUILD_DIR}/kernel"