Explorar el Código

package/gcc: refactor nios2 obsolete handling into common gcc code

Commit 69cb6259479c548a09aac1140261c17f1cbb86b3 ("package/gcc: enable
obsolete nios2 target") added some handling of nios2 with gcc 14.x,
duplicated between gcc-initial and gcc-final. Let's deduplicate this
logic into the common package/gcc/gcc.mk code.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Thomas Petazzoni hace 1 año
padre
commit
1c8bdef542

+ 0 - 5
package/gcc/gcc-final/gcc-final.mk

@@ -117,11 +117,6 @@ else
 HOST_GCC_FINAL_CONF_OPTS += --disable-libgomp
 HOST_GCC_FINAL_CONF_OPTS += --disable-libgomp
 endif
 endif
 
 
-# allow to build gcc 14.x
-ifeq ($(BR2_nios2),y)
-HOST_GCC_FINAL_CONF_OPTS += --enable-obsolete
-endif
-
 # End with user-provided options, so that they can override previously
 # End with user-provided options, so that they can override previously
 # defined options.
 # defined options.
 HOST_GCC_FINAL_CONF_OPTS += \
 HOST_GCC_FINAL_CONF_OPTS += \

+ 0 - 5
package/gcc/gcc-initial/gcc-initial.mk

@@ -42,11 +42,6 @@ HOST_GCC_INITIAL_CONF_OPTS = \
 	--disable-largefile \
 	--disable-largefile \
 	$(call qstrip,$(BR2_EXTRA_GCC_CONFIG_OPTIONS))
 	$(call qstrip,$(BR2_EXTRA_GCC_CONFIG_OPTIONS))
 
 
-# allow to build gcc 14.x
-ifeq ($(BR2_nios2),y)
-HOST_GCC_INITIAL_CONF_OPTS += --enable-obsolete
-endif
-
 HOST_GCC_INITIAL_CONF_ENV = \
 HOST_GCC_INITIAL_CONF_ENV = \
 	$(HOST_GCC_COMMON_CONF_ENV)
 	$(HOST_GCC_COMMON_CONF_ENV)
 
 

+ 5 - 0
package/gcc/gcc.mk

@@ -293,6 +293,11 @@ HOST_GCC_COMMON_CONF_OPTS += \
 	--with-long-double-128
 	--with-long-double-128
 endif
 endif
 
 
+# allow to build gcc 14.x
+ifeq ($(BR2_nios2),y)
+HOST_GCC_COMMON_CONF_OPTS += --enable-obsolete
+endif
+
 HOST_GCC_COMMON_TOOLCHAIN_WRAPPER_ARGS += -DBR_CROSS_PATH_SUFFIX='".br_real"'
 HOST_GCC_COMMON_TOOLCHAIN_WRAPPER_ARGS += -DBR_CROSS_PATH_SUFFIX='".br_real"'
 
 
 # For gcc-initial, we need to tell gcc that the C library will be
 # For gcc-initial, we need to tell gcc that the C library will be