diff mbox series

[next,19/25] package/gcc: properly handle legacy for renamed ARC option

Message ID 20221127130739.1862398-20-ricardo.martincoski@gmail.com
State Accepted
Headers show
Series check-symbols v2 | expand

Commit Message

Ricardo Martincoski Nov. 27, 2022, 1:07 p.m. UTC
Commit "50332a530b gcc: rename option for ARC gcc" tried to add legacy
handling but the new symbol is part of a choice, and Kconfig does not
enforce the select of a option from a choice.

Update the legacy entry for 2016.11, following the example described in
the beginning of the file.

Cc: Giulio Benetti <giulio.benetti@benettiengineering.com>
Cc: Romain Naour <romain.naour@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com>
---
test config 1:
BR2_GCC_VERSION_4_8_ARC=y
BR2_arcle=y
NOTE that in order to test this other line must be commented out:
default BR2_GCC_VERSION_ARC if BR2_GCC_VERSION_ARC
---
 Config.in.legacy           | 3 ++-
 package/gcc/Config.in.host | 1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

Comments

Peter Korsgaard Feb. 6, 2023, 11:48 a.m. UTC | #1
>>>>> "Ricardo" == Ricardo Martincoski <ricardo.martincoski@gmail.com> writes:

 > Commit "50332a530b gcc: rename option for ARC gcc" tried to add legacy
 > handling but the new symbol is part of a choice, and Kconfig does not
 > enforce the select of a option from a choice.

 > Update the legacy entry for 2016.11, following the example described in
 > the beginning of the file.

 > Cc: Giulio Benetti <giulio.benetti@benettiengineering.com>
 > Cc: Romain Naour <romain.naour@gmail.com>
 > Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
 > Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com>

Committed, thanks.
Peter Korsgaard Feb. 22, 2023, 4:47 p.m. UTC | #2
>>>>> "Ricardo" == Ricardo Martincoski <ricardo.martincoski@gmail.com> writes:

 > Commit "50332a530b gcc: rename option for ARC gcc" tried to add legacy
 > handling but the new symbol is part of a choice, and Kconfig does not
 > enforce the select of a option from a choice.

 > Update the legacy entry for 2016.11, following the example described in
 > the beginning of the file.

 > Cc: Giulio Benetti <giulio.benetti@benettiengineering.com>
 > Cc: Romain Naour <romain.naour@gmail.com>
 > Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
 > Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com>

Committed to 2022.11.x and 2022.02.x, thanks.
diff mbox series

Patch

diff --git a/Config.in.legacy b/Config.in.legacy
index e489458270..8861b0d704 100644
--- a/Config.in.legacy
+++ b/Config.in.legacy
@@ -3970,10 +3970,11 @@  config BR2_LINUX_KERNEL_TOOL_SELFTESTS
 config BR2_GCC_VERSION_4_8_ARC
 	bool "gcc arc option renamed"
 	select BR2_LEGACY
-	select BR2_GCC_VERSION_ARC
 	help
 	  The option that selects the gcc version for the ARC
 	  architecture has been renamed to BR2_GCC_VERSION_ARC.
+# Note: BR2_GCC_VERSION_4_8_ARC is still referenced from
+# package/gcc/Config.in.host
 
 config BR2_KERNEL_HEADERS_4_0
 	bool "kernel headers version 4.0.x are no longer supported"
diff --git a/package/gcc/Config.in.host b/package/gcc/Config.in.host
index d7fedc9591..cd1b9fa46d 100644
--- a/package/gcc/Config.in.host
+++ b/package/gcc/Config.in.host
@@ -2,6 +2,7 @@  comment "GCC Options"
 
 choice
 	prompt "GCC compiler Version"
+	default BR2_GCC_VERSION_ARC if BR2_GCC_VERSION_4_8_ARC # legacy
 	default BR2_GCC_VERSION_ARC if BR2_arc
 	default BR2_GCC_VERSION_POWERPC_SPE if BR2_powerpc_SPE
 	default BR2_GCC_VERSION_11_X