up
This commit is contained in:
+9
-9
@@ -6,20 +6,20 @@
|
||||
|
||||
#--------------- Building Linux Kernel ---------------------
|
||||
kernel() {
|
||||
printf "$UGREEN** Building Linux Kernel\n$RESET"
|
||||
print_info "** Building Linux Kernel"
|
||||
[ -d $build/kernel ] && return 0
|
||||
mkdir -p $build/kernel
|
||||
cd $build/kernel
|
||||
printf "$UGREEN** Extracting Linux Kernel\n$RESET"
|
||||
print_info "** Extracting Linux Kernel"
|
||||
tar -xf $root/downloads/linux-$KERNEL_VERSION.tar.xz
|
||||
check $? "Extract Linux Kernel"
|
||||
cd linux-$KERNEL_VERSION
|
||||
printf "$UGREEN** Configuring Linux Kernel\n$RESET"
|
||||
print_info "** Configuring Linux Kernel"
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- mrproper
|
||||
cp $root/board/${BOARD_NAME}/linux-$KERNEL_VERSION.config .config
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- oldconfig
|
||||
check $? "Configure Linux Kernel"
|
||||
printf "$UGREEN** Building Linux Kernel\n$RESET"
|
||||
print_info "** Building Linux Kernel"
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- $makeflags
|
||||
check $? "Build Linux Kernel"
|
||||
KIMAGE=zImage
|
||||
@@ -30,12 +30,12 @@ kernel() {
|
||||
|
||||
#----------- Build and Install kernel modules --------------
|
||||
kernel_modules() {
|
||||
printf "$UGREEN** Building Linux Kernel modules\n$RESET"
|
||||
print_info "** Building Linux Kernel modules"
|
||||
[ -d $rootfspath/usr/lib/modules ] && return 0
|
||||
cd $build/kernel/linux-$KERNEL_VERSION
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- modules
|
||||
check $? "Build Linux Kernel modules"
|
||||
printf "$UGREEN** Installing Linux Kernel modules into rootfs path\n$RESET"
|
||||
print_info "** Installing Linux Kernel modules into rootfs path"
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- INSTALL_MOD_PATH=$rootfspath modules_install
|
||||
for i in $(find $rootfspath | grep .ko); do
|
||||
gzip -9 $i;
|
||||
@@ -46,14 +46,14 @@ kernel_modules() {
|
||||
|
||||
#--------------- Building Linux Kernel with rootfs ---------
|
||||
kernel_with_rootfs() {
|
||||
printf "$UGREEN** Building Linux Kernel with rootfs\n$RESET"
|
||||
print_info "** Building Linux Kernel with rootfs"
|
||||
if [ ! -d $out ]; then
|
||||
mkdir -pv $out
|
||||
fi
|
||||
cd $build/kernel/linux-$KERNEL_VERSION
|
||||
make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE- CONFIG_INITRAMFS_SOURCE=$rootfspath $makeflags # &>> fulllogfile
|
||||
check $? "Build Linux Kernel with rootfs"
|
||||
printf "$UGREEN** Installing Linux Kernel into images path\n$RESET"
|
||||
print_info "** Installing Linux Kernel into images path"
|
||||
# make ARCH=$ARCH CROSS_COMPILE=$CROSS_COMPILE INSTALL_MOD_PATH=$rootfspath modules_install # &>> $fulllogfile
|
||||
# rm -v $rootfspath/usr/lib/modules/6.1.91/{source,build}
|
||||
KIMAGE=zImage
|
||||
@@ -64,7 +64,7 @@ kernel_with_rootfs() {
|
||||
#-----------------------------------------------------------
|
||||
|
||||
kernel_headers() {
|
||||
printf "$UGREEN** Building Linux Kernel headers\n$RESET"
|
||||
print_info "** Building Linux Kernel headers"
|
||||
[ -d $build/kernel-headers ] && return 0
|
||||
[ ! -d $build/kernel-headers ] && mkdir $build/kernel-headers
|
||||
cd $build/kernel-headers
|
||||
|
||||
Reference in New Issue
Block a user