1
0
mirror of https://github.com/kata-containers/kata-containers.git synced 2025-05-09 17:07:33 +00:00

packaging/kernel: add option -s option

Add -s option to skip .config checks

Signed-off-by: Julio Montes <julio.montes@intel.com>
This commit is contained in:
Julio Montes 2022-02-11 15:27:12 -06:00
parent 88b3e9e848
commit bc8464e04f
2 changed files with 9 additions and 1 deletions
tools/packaging/kernel
build-kernel.sh
patches/tdx-guest-v5.15-4.x

View File

@ -53,6 +53,8 @@ hypervisor_target=""
arch_target=""
#
kernel_config_path=""
#
skip_config_checks="false"
# destdir
DESTDIR="${DESTDIR:-/}"
#PREFIX=
@ -92,6 +94,7 @@ Options:
-h : Display this help.
-k <path> : Path to kernel to build.
-p <path> : Path to a directory with patches to apply to kernel.
-s : Skip .config checks
-t <hypervisor> : Hypervisor_target.
-v <version> : Kernel version to use if kernel path not provided.
-x <type> : Confidential guest protection type, such as sev
@ -233,6 +236,8 @@ get_kernel_frag_path() {
# Do not care about options that are in whitelist
results=$(grep -v -f ${default_config_whitelist} <<< "$results")
[[ "${skip_config_checks}" == "true" ]] && echo "${config_path}" && return
# Did we request any entries that did not make it?
local missing=$(echo $results | grep -v -q "${not_in_string}"; echo $?)
if [ ${missing} -ne 0 ]; then
@ -438,7 +443,7 @@ install_kata() {
}
main() {
while getopts "a:b:c:defg:hk:p:t:v:x:" opt; do
while getopts "a:b:c:defg:hk:p:st:v:x:" opt; do
case "$opt" in
a)
arch_target="${OPTARG}"
@ -472,6 +477,9 @@ main() {
p)
patches_path="${OPTARG}"
;;
s)
skip_config_checks="true"
;;
t)
hypervisor_target="${OPTARG}"
;;