[OS-BUILD PATCH 1/7] redhat/configs/generate_all_configs.sh: Use Makefile variables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Prarit Bhargava <prarit@xxxxxxxxxx>

redhat/configs/generate_all_configs.sh: Use Makefile variables

Use FLAVOR and change the behavior of the DEBUGBUILDSENABLED so that
adding any parameter to the generate_all_configs.sh script results in
no debug build config generation.

Use Makefile variables in generate_all_configs.sh.

Signed-off-by: Prarit Bhargava <prarit@xxxxxxxxxx>

diff --git a/redhat/Makefile b/redhat/Makefile
index blahblah..blahblah 100644
--- a/redhat/Makefile
+++ b/redhat/Makefile
@@ -336,11 +336,11 @@ dist-kabi-dw-check: dist-kabi
 	@rm -rf $(KABIDW)/base/$(CURARCH).tmp
 
 dist-configs-commit: dist-configs-prep
-	+@cd $(REDHAT)/configs; VERSION=$(KVERSION) ./generate_all_configs.sh "$(FLAVOR)" 1; \
+	+@cd $(REDHAT)/configs; ./generate_all_configs.sh; \
 	./process_configs.sh -z "$(PACKAGE_NAME)" "$(KVERSION)" "" "$(FLAVOR)" "$(RHJOBS)"
 
 dist-configs: dist-configs-prep
-	+@cd $(REDHAT)/configs; VERSION=$(KVERSION) ./generate_all_configs.sh "$(FLAVOR)" 1; \
+	+@cd $(REDHAT)/configs; ./generate_all_configs.sh; \
 	./process_configs.sh $(PROCESS_CONFIGS_OPTS) "$(PACKAGE_NAME)" "$(KVERSION)" "" "" "$(RHJOBS)"
 
 dist-fedora-configs: FLAVOR = fedora
diff --git a/redhat/configs/generate_all_configs.sh b/redhat/configs/generate_all_configs.sh
index blahblah..blahblah 100755
--- a/redhat/configs/generate_all_configs.sh
+++ b/redhat/configs/generate_all_configs.sh
@@ -1,30 +1,24 @@
 #!/bin/sh
 
 # Adjusts the configuration options to build the variants correctly
-#
-# arg1: configuration to go in the primary variant
-# arg2: are we only generating debug configs
 
-
-PRIMARY=$1
-DEBUGBUILDSENABLED=$2
-
-if [ -z "$2" ]; then
-	exit 1
+DEBUGBUILDSENABLED=1
+if [ -n "$1" ]; then
+	DEBUGBUILDSENABLED=0
 fi
 
-if [ -z "$PRIMARY" ]; then
-	PRIMARY=rhel
+if [ -z "$FLAVOR" ]; then
+	FLAVOR=rhel
 fi
 
-if [ "$PRIMARY" = "fedora" ]; then
+if [ "$FLAVOR" = "fedora" ]; then
 	SECONDARY=rhel
 else
 	SECONDARY=fedora
 fi
 
-for i in kernel-*-"$PRIMARY".config; do
-	NEW=kernel-"$VERSION"-$(echo "$i" | cut -d - -f2- | sed s/-"$PRIMARY"//)
+for i in kernel-*-"$FLAVOR".config; do
+	NEW=kernel-"$KVERSION"-$(echo "$i" | cut -d - -f2- | sed s/-"$FLAVOR"//)
 	#echo $NEW
 	mv "$i" "$NEW"
 done

--
https://gitlab.com/cki-project/kernel-ark/-/merge_requests/1647
_______________________________________________
kernel mailing list -- kernel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to kernel-leave@xxxxxxxxxxxxxxxxxxxxxxx
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@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure




[Index of Archives]     [Fedora General Discussion]     [Older Fedora Users Archive]     [Fedora Advisory Board]     [Fedora Security]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Mentors]     [Fedora Package Announce]     [Fedora Package Review]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Coolkey]     [Yum Users]     [Tux]     [Yosemite News]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [USB]     [Asterisk PBX]

  Powered by Linux