|
|
@ -13,12 +13,18 @@ gen_minkernpackage() {
|
|
|
|
/bin/tar -xj -C ${TEMP}/minkernpackage -f ${KERNCACHE} kernelz-${ARCH}-${KV}
|
|
|
|
/bin/tar -xj -C ${TEMP}/minkernpackage -f ${KERNCACHE} kernelz-${ARCH}-${KV}
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
else
|
|
|
|
else
|
|
|
|
|
|
|
|
local tmp_kernel_binary=$(find_kernel_binary ${KERNEL_BINARY})
|
|
|
|
|
|
|
|
local tmp_kernel_binary2=$(find_kernel_binary ${KERNEL_BINARY_2})
|
|
|
|
|
|
|
|
if [ -z "${tmp_kernel_binary}" ]
|
|
|
|
|
|
|
|
then
|
|
|
|
|
|
|
|
gen_die "Cannot locate kernel binary"
|
|
|
|
|
|
|
|
fi
|
|
|
|
cd "${KERNEL_DIR}"
|
|
|
|
cd "${KERNEL_DIR}"
|
|
|
|
cp "${KERNEL_BINARY}" "${TEMP}/minkernpackage/kernel-${KV}" || gen_die 'Could not the copy kernel for the min kernel package!'
|
|
|
|
cp "${tmp_kernel_binary}" "${TEMP}/minkernpackage/kernel-${KV}" || gen_die 'Could not the copy kernel for the min kernel package!'
|
|
|
|
cp ".config" "${TEMP}/minkernpackage/config-${ARCH}-${KV}" || gen_die 'Could not the copy kernel config for the min kernel package!'
|
|
|
|
cp ".config" "${TEMP}/minkernpackage/config-${ARCH}-${KV}" || gen_die 'Could not the copy kernel config for the min kernel package!'
|
|
|
|
if isTrue "${GENZIMAGE}"
|
|
|
|
if isTrue "${GENZIMAGE}"
|
|
|
|
then
|
|
|
|
then
|
|
|
|
cp "${KERNEL_BINARY_2}" "${TEMP}/minkernpackage/kernelz-${KV}" || gen_die "Could not copy the kernelz for the min kernel package"
|
|
|
|
cp "${tmp_kernel_binary2}" "${TEMP}/minkernpackage/kernelz-${KV}" || gen_die "Could not copy the kernelz for the min kernel package"
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
@ -60,14 +66,22 @@ gen_kerncache()
|
|
|
|
print_info 1 'Creating kernel cache'
|
|
|
|
print_info 1 'Creating kernel cache'
|
|
|
|
rm -rf "${TEMP}/kerncache" > /dev/null 2>&1
|
|
|
|
rm -rf "${TEMP}/kerncache" > /dev/null 2>&1
|
|
|
|
mkdir "${TEMP}/kerncache" || gen_die 'Could not make a directory for the kernel cache!'
|
|
|
|
mkdir "${TEMP}/kerncache" || gen_die 'Could not make a directory for the kernel cache!'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
local tmp_kernel_binary=$(find_kernel_binary ${KERNEL_BINARY})
|
|
|
|
|
|
|
|
local tmp_kernel_binary2=$(find_kernel_binary ${KERNEL_BINARY_2})
|
|
|
|
|
|
|
|
if [ -z "${tmp_kernel_binary}" ]
|
|
|
|
|
|
|
|
then
|
|
|
|
|
|
|
|
gen_die "Cannot locate kernel binary"
|
|
|
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
cd "${KERNEL_DIR}"
|
|
|
|
cd "${KERNEL_DIR}"
|
|
|
|
cp "${KERNEL_BINARY}" "${TEMP}/kerncache/kernel-${ARCH}-${KV}" || gen_die 'Could not the copy kernel for the kernel package!'
|
|
|
|
cp "${tmp_kernel_binary}" "${TEMP}/kerncache/kernel-${ARCH}-${KV}" || gen_die 'Could not the copy kernel for the kernel package!'
|
|
|
|
cp "${KERNEL_DIR}/.config" "${TEMP}/kerncache/config-${ARCH}-${KV}"
|
|
|
|
cp "${KERNEL_DIR}/.config" "${TEMP}/kerncache/config-${ARCH}-${KV}"
|
|
|
|
cp "${KERNEL_CONFIG}" "${TEMP}/kerncache/config-${ARCH}-${KV}.orig"
|
|
|
|
cp "${KERNEL_CONFIG}" "${TEMP}/kerncache/config-${ARCH}-${KV}.orig"
|
|
|
|
cp "${KERNEL_DIR}/System.map" "${TEMP}/kerncache/System.map-${ARCH}-${KV}"
|
|
|
|
cp "${KERNEL_DIR}/System.map" "${TEMP}/kerncache/System.map-${ARCH}-${KV}"
|
|
|
|
if isTrue "${GENZIMAGE}"
|
|
|
|
if isTrue "${GENZIMAGE}"
|
|
|
|
then
|
|
|
|
then
|
|
|
|
cp "${KERNEL_BINARY_2}" "${TEMP}/kerncache/kernelz-${ARCH}-${KV}" || gen_die "Could not copy the kernelz for the kernel package"
|
|
|
|
cp "${tmp_kernel_binary2}" "${TEMP}/kerncache/kernelz-${ARCH}-${KV}" || gen_die "Could not copy the kernelz for the kernel package"
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
echo "VERSION = ${VER}" > "${TEMP}/kerncache/kerncache.config"
|
|
|
|
echo "VERSION = ${VER}" > "${TEMP}/kerncache/kerncache.config"
|
|
|
|