From: Prarit Bhargava <pra...@redhat.com>

redhat/configs/build_configs.sh: Use Makefile variables

Use Makefile variables in build_configs.sh.

Signed-off-by: Prarit Bhargava <pra...@redhat.com>

diff --git a/redhat/Makefile b/redhat/Makefile
index blahblah..blahblah 100644
--- a/redhat/Makefile
+++ b/redhat/Makefile
@@ -363,8 +363,8 @@ dist-configs-check: dist-configs-prep
        +cd $(REDHAT)/configs; ./process_configs.sh 
$(PROCESS_CONFIGS_CHECK_OPTS) "" ""
 
 dist-configs-prep: dist-clean-configs dist-buildreq-check
-       +cd $(REDHAT)/configs; ./build_configs.sh "partial" "$(ARCH_MACH)" 
"snip" "$(RHJOBS)"
-       +cd $(REDHAT)/configs; ./build_configs.sh "$(PACKAGE_NAME)" 
"$(ARCH_MACH)" "$(FLAVOR)" "$(RHJOBS)"
+       +cd $(REDHAT)/configs; ./build_configs.sh "partial" "snip"
+       +cd $(REDHAT)/configs; ./build_configs.sh "$(PACKAGE_NAME)" "$(FLAVOR)"
 
 dist-configs-arch: ARCH_MACH = $(MACH)
 dist-configs-arch: dist-configs
diff --git a/redhat/configs/build_configs.sh b/redhat/configs/build_configs.sh
index blahblah..blahblah 100755
--- a/redhat/configs/build_configs.sh
+++ b/redhat/configs/build_configs.sh
@@ -5,19 +5,15 @@
 # files for building RHEL kernels, based on the contents of a control file
 
 PACKAGE_NAME="${1:-kernel}" # defines the package name used
-SUBARCH="${2:-}" # defines a specific arch
-SCRIPT=$(readlink -f "$0")
-OUTPUT_DIR="$PWD"
-SCRIPT_DIR=$(dirname "$SCRIPT")
-
-if [ -z "$3" ]; then
+if [ -z "$2" ]; then
        cat flavors > .flavors
 else
-       echo "$3" > .flavors
+       echo "$2" > .flavors
 fi
 
-# shellcheck disable=SC2015
-RHJOBS="$(test -n "$4" && echo "$4" || nproc --all)"
+SCRIPT=$(readlink -f "$0")
+OUTPUT_DIR="$PWD"
+SCRIPT_DIR=$(dirname "$SCRIPT")
 
 LANG=en_US.UTF-8
 
@@ -146,9 +142,9 @@ function build_flavor()
                        arch=$(echo "$line" | cut -f1 -d"=")
                        configs=$(echo "$line" | cut -f2 -d"=")
 
-                       if [ -n "$SUBARCH" ]; then
+                       if [ -n "$ARCH_MACH" ]; then
                                case $arch in
-                                       $SUBARCH*)
+                                       $ARCH_MACH*)
                                                ;;
                                        *)
                                                continue

--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/1647
_______________________________________________
kernel mailing list -- kernel@lists.fedoraproject.org
To unsubscribe send an email to kernel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/kernel@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure

Reply via email to