* [Buildroot] [PATCH v2 01/12] arc: Add ARC and ARC BE architecture
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 02/12] arc: Add option for ARC-specific download site Mischa Jonker
` (11 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
Synopsys' DesignWare ARC Processor Cores are a family of 32-bit CPUs that
can be used from deeply embedded to high performance host applications.
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
arch/Config.in | 18 ++++++++++++++++++
arch/Config.in.arc | 14 ++++++++++++++
2 files changed, 32 insertions(+), 0 deletions(-)
create mode 100644 arch/Config.in.arc
diff --git a/arch/Config.in b/arch/Config.in
index 795f24f..2006f1e 100644
--- a/arch/Config.in
+++ b/arch/Config.in
@@ -7,6 +7,20 @@ choice
help
Select the target architecture family to build for.
+config BR2_arcle
+ bool "ARC (little endian)"
+ help
+ Synopsys' DesignWare ARC Processor Cores are a family of 32-bit CPUs
+ that can be used from deeply embedded to high performance host
+ applications. Little endian.
+
+config BR2_arceb
+ bool "ARC (big endian)"
+ help
+ Synopsys' DesignWare ARC Processor Cores are a family of 32-bit CPUs
+ that can be used from deeply embedded to high performance host
+ applications. Big endian.
+
config BR2_arm
bool "ARM (little endian)"
help
@@ -175,6 +189,10 @@ config BR2_GCC_TARGET_ABI
config BR2_GCC_TARGET_CPU
string
+if BR2_arcle || BR2_arceb
+source "arch/Config.in.arc"
+endif
+
if BR2_arm || BR2_armeb
source "arch/Config.in.arm"
endif
diff --git a/arch/Config.in.arc b/arch/Config.in.arc
new file mode 100644
index 0000000..60b59f0
--- /dev/null
+++ b/arch/Config.in.arc
@@ -0,0 +1,14 @@
+config BR2_ARCH
+ default "arc" if BR2_arcle
+ default "arceb" if BR2_arceb
+
+config BR2_arc
+ bool
+ default y if BR2_arcle || BR2_arceb
+
+config BR2_ENDIAN
+ default "LITTLE" if BR2_arcle
+ default "BIG" if BR2_arceb
+
+config BR2_GCC_TARGET_CPU
+ default "arc700"
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 02/12] arc: Add option for ARC-specific download site
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 01/12] arc: Add ARC and ARC BE architecture Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 03/12] arc: Add support for ARC-specific binutils Mischa Jonker
` (10 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
As ARC support is not yet in all upstream packages, a different location is
required to download the packages from. This adds an option to specify a
site for ARC-specific versions of packages such as binutils, gcc.
When ARC support has been upstreamed for all packages, this option can be
removed again.
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
arch/Config.in.arc | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/arch/Config.in.arc b/arch/Config.in.arc
index 60b59f0..9f68b46 100644
--- a/arch/Config.in.arc
+++ b/arch/Config.in.arc
@@ -12,3 +12,7 @@ config BR2_ENDIAN
config BR2_GCC_TARGET_CPU
default "arc700"
+
+config BR2_ARC_SITE
+ string
+ default "http://www.synopsys.com/apps/arc-developer/"
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 03/12] arc: Add support for ARC-specific binutils
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 01/12] arc: Add ARC and ARC BE architecture Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 02/12] arc: Add option for ARC-specific download site Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 04/12] arc: Add arc, arcbe to gnuconfig Mischa Jonker
` (9 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
ARC support is not upstream yet...
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
.../binutils/2.19-arc/add-empty-info-files.patch | 72 ++++++++++++++++++++
package/binutils/Config.in.host | 2 +
package/binutils/binutils.mk | 3 +
3 files changed, 77 insertions(+), 0 deletions(-)
create mode 100644 package/binutils/2.19-arc/add-empty-info-files.patch
diff --git a/package/binutils/2.19-arc/add-empty-info-files.patch b/package/binutils/2.19-arc/add-empty-info-files.patch
new file mode 100644
index 0000000..90de429
--- /dev/null
+++ b/package/binutils/2.19-arc/add-empty-info-files.patch
@@ -0,0 +1,72 @@
+binutils: add empty info files to remove makeinfo dependency
+
+Signed-off-by: Mischa jonker <mjonker@synopsys.com>
+---
+ bfd/doc/bfd.info | 1 +
+ binutils/doc/binutils.info | 1 +
+ etc/configure.info | 1 +
+ etc/standards.info | 1 +
+ gas/doc/as.info | 1 +
+ gprof/gprof.info | 1 +
+ ld/ld.info | 1 +
+ 7 files changed, 7 insertions(+), 0 deletions(-)
+ create mode 100644 bfd/doc/bfd.info
+ create mode 100644 binutils/doc/binutils.info
+ create mode 100644 etc/configure.info
+ create mode 100644 etc/standards.info
+ create mode 100644 gas/doc/as.info
+ create mode 100644 gprof/gprof.info
+ create mode 100644 ld/ld.info
+
+diff --git a/bfd/doc/bfd.info b/bfd/doc/bfd.info
+new file mode 100644
+index 0000000..8b13789
+--- /dev/null
++++ b/bfd/doc/bfd.info
+@@ -0,0 +1 @@
++
+diff --git a/binutils/doc/binutils.info b/binutils/doc/binutils.info
+new file mode 100644
+index 0000000..8b13789
+--- /dev/null
++++ b/binutils/doc/binutils.info
+@@ -0,0 +1 @@
++
+diff --git a/etc/configure.info b/etc/configure.info
+new file mode 100644
+index 0000000..8b13789
+--- /dev/null
++++ b/etc/configure.info
+@@ -0,0 +1 @@
++
+diff --git a/etc/standards.info b/etc/standards.info
+new file mode 100644
+index 0000000..8b13789
+--- /dev/null
++++ b/etc/standards.info
+@@ -0,0 +1 @@
++
+diff --git a/gas/doc/as.info b/gas/doc/as.info
+new file mode 100644
+index 0000000..8b13789
+--- /dev/null
++++ b/gas/doc/as.info
+@@ -0,0 +1 @@
++
+diff --git a/gprof/gprof.info b/gprof/gprof.info
+new file mode 100644
+index 0000000..8b13789
+--- /dev/null
++++ b/gprof/gprof.info
+@@ -0,0 +1 @@
++
+diff --git a/ld/ld.info b/ld/ld.info
+new file mode 100644
+index 0000000..8b13789
+--- /dev/null
++++ b/ld/ld.info
+@@ -0,0 +1 @@
++
+--
+1.7.0.4
+
diff --git a/package/binutils/Config.in.host b/package/binutils/Config.in.host
index a61a503..d9bab44 100644
--- a/package/binutils/Config.in.host
+++ b/package/binutils/Config.in.host
@@ -2,6 +2,7 @@ comment "Binutils Options"
choice
prompt "Binutils Version"
+ depends on !BR2_arc
default BR2_BINUTILS_VERSION_2_21 if (BR2_mips || BR2_mipsel || BR2_sh)
default BR2_BINUTILS_VERSION_2_21_1 if (!BR2_UCLIBC_VERSION_0_9_31)
default BR2_BINUTILS_VERSION_2_21
@@ -41,6 +42,7 @@ endchoice
config BR2_BINUTILS_VERSION
string
default "2.18-avr32-1.0.1" if BR2_BINUTILS_VERSION_2_18_AVR32_1_0_1
+ default "2.19-arc" if BR2_arc
default "2.20.1" if BR2_BINUTILS_VERSION_2_20_1
default "2.21" if BR2_BINUTILS_VERSION_2_21
default "2.21.1" if BR2_BINUTILS_VERSION_2_21_1
diff --git a/package/binutils/binutils.mk b/package/binutils/binutils.mk
index 92e0a74..4aaa08b 100644
--- a/package/binutils/binutils.mk
+++ b/package/binutils/binutils.mk
@@ -26,6 +26,9 @@ BINUTILS_SITE = $(BR2_GNU_MIRROR)/binutils
ifeq ($(ARCH),avr32)
BINUTILS_SITE = ftp://www.at91.com/pub/buildroot
endif
+ifeq ($(BR2_arc),y)
+BINUTILS_SITE = $(BR2_ARC_SITE)
+endif
BINUTILS_EXTRA_CONFIG_OPTIONS = $(call qstrip,$(BR2_BINUTILS_EXTRA_CONFIG_OPTIONS))
BINUTILS_INSTALL_STAGING = YES
BINUTILS_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 04/12] arc: Add arc, arcbe to gnuconfig
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (2 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 03/12] arc: Add support for ARC-specific binutils Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 05/12] arc: disable Crosstool-NG for ARC Mischa Jonker
` (8 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
support/gnuconfig/config.sub | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/support/gnuconfig/config.sub b/support/gnuconfig/config.sub
index 8509813..b2958ad 100755
--- a/support/gnuconfig/config.sub
+++ b/support/gnuconfig/config.sub
@@ -259,7 +259,7 @@ case $basic_machine in
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
| am33_2.0 \
- | arc \
+ | arc | arceb \
| arm | arm[bl]e | arme[lb] | armv[2-8] | armv[3-8][lb] | armv7[arm] \
| avr | avr32 \
| be32 | be64 \
@@ -372,7 +372,7 @@ case $basic_machine in
| aarch64-* | aarch64_be-* \
| alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
- | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
+ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \
| arm-* | armbe-* | armle-* | armeb-* | armv*-* \
| avr-* | avr32-* \
| be32-* | be64-* \
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 05/12] arc: disable Crosstool-NG for ARC
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (3 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 04/12] arc: Add arc, arcbe to gnuconfig Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 06/12] arc: add gcc " Mischa Jonker
` (7 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
toolchain/Config.in | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/toolchain/Config.in b/toolchain/Config.in
index fa78cf4..e6a3b25 100644
--- a/toolchain/Config.in
+++ b/toolchain/Config.in
@@ -22,7 +22,7 @@ config BR2_TOOLCHAIN_EXTERNAL
config BR2_TOOLCHAIN_CTNG
bool "Crosstool-NG toolchain"
- depends on !BR2_microblaze && !BR2_aarch64 && !BR2_xtensa
+ depends on !BR2_microblaze && !BR2_aarch64 && !BR2_xtensa && !BR2_arc
select BR2_TOOLCHAIN_HAS_SHADOW_PASSWORDS
help
Say 'y' if you want to generate the toolchain with crosstool-NG
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 06/12] arc: add gcc for ARC
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (4 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 05/12] arc: disable Crosstool-NG for ARC Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 07/12] arc: Add support for ARC-specific uClibc Mischa Jonker
` (6 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
ARC needs a specific GCC for now, while we wait for ARC support to get
upstreamed.
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
.../gcc/4.4.7-arc/fix_branch_out_of_range.patch | 30 ++++++++++++++++++++
toolchain/gcc/Config.in | 22 +++++++++-----
toolchain/gcc/gcc-uclibc-4.x.mk | 2 +
3 files changed, 46 insertions(+), 8 deletions(-)
create mode 100644 toolchain/gcc/4.4.7-arc/fix_branch_out_of_range.patch
diff --git a/toolchain/gcc/4.4.7-arc/fix_branch_out_of_range.patch b/toolchain/gcc/4.4.7-arc/fix_branch_out_of_range.patch
new file mode 100644
index 0000000..e39b1cc
--- /dev/null
+++ b/toolchain/gcc/4.4.7-arc/fix_branch_out_of_range.patch
@@ -0,0 +1,30 @@
+arc: Fix operand-out-of-range errors
+
+brcc_s instructions can generate operand-out-of-range errors. While a
+better solution is being discussed by the compiler team, this workaround
+ensures that the chances of running into this issue are low.
+
+Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
+
+diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
+index ff602c0..b3ca4c4 100644
+--- a/gcc/config/arc/arc.c
++++ b/gcc/config/arc/arc.c
+@@ -6565,7 +6565,7 @@ estimate required size increase).
+ rtx *ccp = &XEXP (XVECEXP (pat, 0, 1), 0);
+
+ offset = branch_dest (insn) - INSN_ADDRESSES (INSN_UID (insn));
+- if ((offset >= -140 && offset < 140)
++ if ((offset >= -120 && offset < 120)
+ && rtx_equal_p (XEXP (op, 1), const0_rtx)
+ && compact_register_operand (XEXP (op, 0), VOIDmode)
+ && equality_comparison_operator (op, VOIDmode))
+@@ -6687,7 +6687,7 @@ estimate required size increase).
+
+ if (op0 != cmp0)
+ cc_clob_rtx = gen_rtx_REG (CC_ZNmode, CC_REG);
+- else if ((offset >= -140 && offset < 140)
++ else if ((offset >= -120 && offset < 120)
+ && rtx_equal_p (op1, const0_rtx)
+ && compact_register_operand (op0, VOIDmode)
+ && (GET_CODE (op) == EQ
diff --git a/toolchain/gcc/Config.in b/toolchain/gcc/Config.in
index d7e8715..851afa7 100644
--- a/toolchain/gcc/Config.in
+++ b/toolchain/gcc/Config.in
@@ -9,44 +9,49 @@ choice
prompt "GCC compiler Version"
default BR2_GCC_VERSION_4_4_X if BR2_sparc_sparchfleon || BR2_sparc_sparchfleonv8 || BR2_sparc_sparcsfleon || BR2_sparc_sparcsfleonv8
default BR2_GCC_VERSION_4_2_2_AVR32_2_1_5 if BR2_avr32
+ default BR2_GCC_VERSION_4_4_7_ARC if BR2_arc
default BR2_GCC_VERSION_4_7_X
help
Select the version of gcc you wish to use.
+ config BR2_GCC_VERSION_4_4_7_ARC
+ depends on BR2_arc
+ bool "gcc 4.4.7-arc"
+
config BR2_GCC_VERSION_4_2_2_AVR32_2_1_5
depends on BR2_avr32
bool "gcc 4.2.2-avr32-2.1.5"
config BR2_GCC_VERSION_4_3_X
- depends on !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8 && !BR2_cortex_a5 && !BR2_cortex_a8 && !BR2_cortex_a9 && !BR2_cortex_a15 && !BR2_x86_atom && !BR2_powerpc_e300c2 && !BR2_powerpc_e300c3 && !BR2_powerpc_e500mc && !BR2_powerpc_464 && !BR2_powerpc_464fp && !BR2_powerpc_476 && !BR2_powerpc_476fp && !BR2_fa526
+ depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8 && !BR2_cortex_a5 && !BR2_cortex_a8 && !BR2_cortex_a9 && !BR2_cortex_a15 && !BR2_x86_atom && !BR2_powerpc_e300c2 && !BR2_powerpc_e300c3 && !BR2_powerpc_e500mc && !BR2_powerpc_464 && !BR2_powerpc_464fp && !BR2_powerpc_476 && !BR2_powerpc_476fp && !BR2_fa526
bool "gcc 4.3.x"
config BR2_GCC_VERSION_4_4_X
- depends on !BR2_avr32 && !BR2_cortex_a5 && !BR2_cortex_a15 && !BR2_x86_atom && !BR2_powerpc_476 && !BR2_powerpc_476fp && !BR2_fa526
+ depends on !BR2_arc && !BR2_avr32 && !BR2_cortex_a5 && !BR2_cortex_a15 && !BR2_x86_atom && !BR2_powerpc_476 && !BR2_powerpc_476fp && !BR2_fa526
bool "gcc 4.4.x"
config BR2_GCC_VERSION_4_5_X
- depends on !BR2_avr32 && !BR2_cortex_a15 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8 && !BR2_fa526
+ depends on !BR2_arc && !BR2_avr32 && !BR2_cortex_a15 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8 && !BR2_fa526
select BR2_GCC_NEEDS_MPC
bool "gcc 4.5.x"
config BR2_GCC_VERSION_4_6_X
- depends on !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
select BR2_GCC_NEEDS_MPC
bool "gcc 4.6.x"
config BR2_GCC_VERSION_4_7_X
- depends on !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
select BR2_GCC_NEEDS_MPC
bool "gcc 4.7.x"
config BR2_GCC_VERSION_4_8_X
- depends on !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
select BR2_GCC_NEEDS_MPC
bool "gcc 4.8.x"
config BR2_GCC_VERSION_SNAP
- depends on !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
select BR2_GCC_NEEDS_MPC
bool "gcc snapshot"
endchoice
@@ -74,6 +79,7 @@ config BR2_GCC_VERSION
default "4.2.2-avr32-2.1.5" if BR2_GCC_VERSION_4_2_2_AVR32_2_1_5
default "4.3.6" if BR2_GCC_VERSION_4_3_X
default "4.4.7" if BR2_GCC_VERSION_4_4_X
+ default "4.4.7-arc" if BR2_GCC_VERSION_4_4_7_ARC
default "4.5.4" if BR2_GCC_VERSION_4_5_X
default "4.6.4" if BR2_GCC_VERSION_4_6_X
default "4.7.3" if BR2_GCC_VERSION_4_7_X
@@ -119,6 +125,6 @@ config BR2_GCC_ENABLE_TLS
config BR2_GCC_ENABLE_OPENMP
bool "Enable compiler OpenMP support"
- depends on !BR2_PTHREADS_NONE && !BR2_avr32
+ depends on !BR2_PTHREADS_NONE && !BR2_avr32 && !BR2_arc
help
Enable OpenMP support for the compiler
diff --git a/toolchain/gcc/gcc-uclibc-4.x.mk b/toolchain/gcc/gcc-uclibc-4.x.mk
index fc11ad4..4c77c5c 100644
--- a/toolchain/gcc/gcc-uclibc-4.x.mk
+++ b/toolchain/gcc/gcc-uclibc-4.x.mk
@@ -29,6 +29,8 @@ ifneq ($(GCC_SNAP_DATE),)
GCC_SITE:=ftp://gcc.gnu.org/pub/gcc/snapshots/$(GCC_SNAP_DATE)/
else ifeq ($(findstring avr32,$(GCC_VERSION)),avr32)
GCC_SITE:=ftp://www.at91.com/pub/buildroot/
+else ifeq ($(findstring arc,$(GCC_VERSION)),arc)
+ GCC_SITE:=$(BR2_ARC_SITE)
else
GCC_SITE:=$(BR2_GNU_MIRROR:/=)/gcc/gcc-$(GCC_VERSION)
endif
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 07/12] arc: Add support for ARC-specific uClibc
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (5 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 06/12] arc: add gcc " Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 08/12] arc: Make sure that libgcc doesn't get included when it doesn't exist yet Mischa Jonker
` (5 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
toolchain/uClibc/Config.in | 10 ++++++++--
toolchain/uClibc/uClibc-snapshot.config | 2 ++
toolchain/uClibc/uclibc.mk | 4 ++++
3 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/toolchain/uClibc/Config.in b/toolchain/uClibc/Config.in
index b98e2e8..316d006 100644
--- a/toolchain/uClibc/Config.in
+++ b/toolchain/uClibc/Config.in
@@ -16,12 +16,16 @@ choice
config BR2_UCLIBC_VERSION_0_9_32
bool "uClibc 0.9.32.x"
- depends on !(BR2_avr32 || BR2_sh || BR2_xtensa)
+ depends on !(BR2_arc || BR2_avr32 || BR2_sh || BR2_xtensa)
config BR2_UCLIBC_VERSION_0_9_33
bool "uClibc 0.9.33.x"
- depends on !BR2_xtensa
+ depends on !(BR2_arc || BR2_xtensa)
+ config BR2_UCLIBC_VERSION_0_9_33_ARC
+ bool "uClibc 0.9.33.x-arc"
+ depends on BR2_arc
+
config BR2_UCLIBC_VERSION_SNAPSHOT
bool "daily snapshot"
@@ -39,6 +43,7 @@ config BR2_UCLIBC_VERSION_STRING
default 0.9.31.1 if BR2_UCLIBC_VERSION_0_9_31
default 0.9.32.1 if BR2_UCLIBC_VERSION_0_9_32
default 0.9.33.2 if BR2_UCLIBC_VERSION_0_9_33
+ default 0.9.33-arc if BR2_UCLIBC_VERSION_0_9_33_ARC
default $BR2_USE_UCLIBC_SNAPSHOT if BR2_UCLIBC_VERSION_SNAPSHOT
config BR2_UCLIBC_CONFIG
@@ -46,6 +51,7 @@ config BR2_UCLIBC_CONFIG
default "toolchain/uClibc/uClibc-0.9.31.config" if BR2_UCLIBC_VERSION_0_9_31
default "toolchain/uClibc/uClibc-0.9.32.config" if BR2_UCLIBC_VERSION_0_9_32
default "toolchain/uClibc/uClibc-0.9.33.config" if BR2_UCLIBC_VERSION_0_9_33
+ default "toolchain/uClibc/uClibc-snapshot.config" if BR2_UCLIBC_VERSION_0_9_33_ARC
default "toolchain/uClibc/uClibc-snapshot.config" if BR2_UCLIBC_VERSION_SNAPSHOT
help
Some people may wish to use their own modified uClibc configuration
diff --git a/toolchain/uClibc/uClibc-snapshot.config b/toolchain/uClibc/uClibc-snapshot.config
index 71fa472..cb6258d 100644
--- a/toolchain/uClibc/uClibc-snapshot.config
+++ b/toolchain/uClibc/uClibc-snapshot.config
@@ -4,6 +4,7 @@
# Fri Jul 9 22:31:59 2010
#
# TARGET_alpha is not set
+# TARGET_arc is not set
# TARGET_arm is not set
# TARGET_avr32 is not set
# TARGET_bfin is not set
@@ -16,6 +17,7 @@
# TARGET_i960 is not set
# TARGET_ia64 is not set
# TARGET_m68k is not set
+# TARGET_metag is not set
# TARGET_microblaze is not set
# TARGET_mips is not set
# TARGET_nios is not set
diff --git a/toolchain/uClibc/uclibc.mk b/toolchain/uClibc/uclibc.mk
index 2249651..1629e76 100644
--- a/toolchain/uClibc/uclibc.mk
+++ b/toolchain/uClibc/uclibc.mk
@@ -17,6 +17,9 @@ UCLIBC_VERSION:=$(call qstrip,$(BR2_UCLIBC_VERSION_STRING))
ifeq ($(BR2_UCLIBC_VERSION_SNAPSHOT),y)
UCLIBC_SITE:=http://www.uclibc.org/downloads/snapshots
UCLIBC_DIR:=$(TOOLCHAIN_DIR)/uClibc
+else ifeq ($(findstring arc,$(UCLIBC_VERSION)),arc)
+UCLIBC_SITE:=$(BR2_ARC_SITE)
+UCLIBC_DIR:=$(TOOLCHAIN_DIR)/uClibc-$(UCLIBC_VERSION)
else
UCLIBC_SITE:=http://www.uclibc.org/downloads
UCLIBC_DIR:=$(TOOLCHAIN_DIR)/uClibc-$(UCLIBC_VERSION)
@@ -31,6 +34,7 @@ UCLIBC_TARGET_ARCH:=$(shell $(SHELL) -c "echo $(ARCH) | sed \
-e 's/-.*//' \
-e 's/i.86/i386/' \
-e 's/sparc.*/sparc/' \
+ -e 's/arc.*/arc/g' \
-e 's/arm.*/arm/g' \
-e 's/m68k.*/m68k/' \
-e 's/ppc/powerpc/g' \
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 08/12] arc: Make sure that libgcc doesn't get included when it doesn't exist yet
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (6 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 07/12] arc: Add support for ARC-specific uClibc Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 09/12] kernel-headers: Use ../testing URL for kernel release candidates Mischa Jonker
` (4 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
For ARC, libgcc is always included, even when -nostdlib is given. This is
related to some small pieces of code that are not always generated by the
compiler; a call to libgcc is used in those cases instead.
During the initial stages of building the toolchain, this is a problem, as
libgcc does not exist yet. The ARC compiler supports -really-nostdlib to
override the default behavior.
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
toolchain/uClibc/uclibc.mk | 15 +++++++++++++--
1 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/toolchain/uClibc/uclibc.mk b/toolchain/uClibc/uclibc.mk
index 1629e76..d4f1d4c 100644
--- a/toolchain/uClibc/uclibc.mk
+++ b/toolchain/uClibc/uclibc.mk
@@ -404,6 +404,17 @@ ifeq ($(BR2_CCACHE),y)
$(UCLIBC_DIR)/.config: | host-ccache
endif
+# For ARC, libgcc is always included, even when -nostdlib is given. This
+# is related to some small pieces of code that are not always generated
+# by the compiler; a call to libgcc is used in those cases instead.
+#
+# During the initial stages of building the toolchain, this is a problem,
+# as libgcc does not exist yet. The ARC compiler supports -really-nostdlib
+# to override the default behavior.
+ifeq ($(BR2_arc),y)
+REALLY_NOSTDLIB=-really-nostdlib
+endif
+
$(UCLIBC_DIR)/.configured: $(LINUX_HEADERS_DIR)/.configured $(UCLIBC_DIR)/.config
$(Q)$(call MESSAGE,"Installing uClibc headers")
$(MAKE1) -C $(UCLIBC_DIR) \
@@ -422,8 +433,8 @@ $(UCLIBC_DIR)/.configured: $(LINUX_HEADERS_DIR)/.configured $(UCLIBC_DIR)/.confi
cp -pLR $(LINUX_HEADERS_DIR)/include/* \
$(TOOLCHAIN_DIR)/uClibc_dev/usr/include/; \
fi
- $(TARGET_CROSS)gcc -nostdlib -nostartfiles -shared -x c /dev/null -o $(TOOLCHAIN_DIR)/uClibc_dev/usr/lib/libc.so
- $(TARGET_CROSS)gcc -nostdlib -nostartfiles -shared -x c /dev/null -o $(TOOLCHAIN_DIR)/uClibc_dev/usr/lib/libm.so
+ $(TARGET_CROSS)gcc -nostdlib $(REALLY_NOSTDLIB) -nostartfiles -shared -x c /dev/null -o $(TOOLCHAIN_DIR)/uClibc_dev/usr/lib/libc.so
+ $(TARGET_CROSS)gcc -nostdlib $(REALLY_NOSTDLIB) -nostartfiles -shared -x c /dev/null -o $(TOOLCHAIN_DIR)/uClibc_dev/usr/lib/libm.so
cp -pLR $(UCLIBC_DIR)/lib/crt[1in].o $(TOOLCHAIN_DIR)/uClibc_dev/usr/lib/
touch $@
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 09/12] kernel-headers: Use ../testing URL for kernel release candidates
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (7 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 08/12] arc: Make sure that libgcc doesn't get included when it doesn't exist yet Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 10/12] kernel-headers: Add 3.9-rc8 headers to make ARC work Mischa Jonker
` (3 subsequent siblings)
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
| 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
--git a/toolchain/kernel-headers/kernel-headers.mk b/toolchain/kernel-headers/kernel-headers.mk
index adf7bc4..5462d5b 100644
--- a/toolchain/kernel-headers/kernel-headers.mk
+++ b/toolchain/kernel-headers/kernel-headers.mk
@@ -31,6 +31,9 @@ LINUX_HEADERS_SITE:=$(BR2_KERNEL_MIRROR:/=)/linux/kernel/v2.6/
else
LINUX_HEADERS_SITE:=$(BR2_KERNEL_MIRROR:/=)/linux/kernel/v3.x/
endif
+ifeq ($(findstring rc,$(DEFAULT_KERNEL_HEADERS)),rc)
+LINUX_HEADERS_SITE:=$(LINUX_HEADERS_SITE)testing/
+endif
LINUX_HEADERS_SOURCE:=linux-$(LINUX_HEADERS_VERSION).tar.bz2
LINUX_HEADERS_CAT:=$(BZCAT)
LINUX_HEADERS_UNPACK_DIR:=$(TOOLCHAIN_DIR)/linux-$(LINUX_HEADERS_VERSION)
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 10/12] kernel-headers: Add 3.9-rc8 headers to make ARC work
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (8 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 09/12] kernel-headers: Use ../testing URL for kernel release candidates Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 19:41 ` Peter Korsgaard
2013-04-24 10:13 ` [Buildroot] [PATCH v2 11/12] toolchain/gcc: Only enable --with-float when it makes sense Mischa Jonker
` (2 subsequent siblings)
12 siblings, 1 reply; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
Add 3.9 release candidate kernel, so that the ARC architecture builds.
Also make sure that older kernels are not selected for ARC.
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
Makefile | 1 +
| 18 +++++++++++++-----
2 files changed, 14 insertions(+), 5 deletions(-)
diff --git a/Makefile b/Makefile
index 0a91658..8fef492 100644
--- a/Makefile
+++ b/Makefile
@@ -238,6 +238,7 @@ ARCH:=$(call qstrip,$(BR2_ARCH))
KERNEL_ARCH:=$(shell echo "$(ARCH)" | sed -e "s/-.*//" \
-e s/i.86/i386/ -e s/sun4u/sparc64/ \
+ -e s/arc.*/arc/ \
-e s/arm.*/arm/ -e s/sa110/arm/ \
-e s/aarch64/arm64/ \
-e s/bfin/blackfin/ \
--git a/toolchain/kernel-headers/Config.in b/toolchain/kernel-headers/Config.in
index ec75c34..1c972f3 100644
--- a/toolchain/kernel-headers/Config.in
+++ b/toolchain/kernel-headers/Config.in
@@ -17,35 +17,42 @@ choice
config BR2_KERNEL_HEADERS_3_0
bool "Linux 3.0.x kernel headers"
+ depends on !BR2_arc
config BR2_KERNEL_HEADERS_3_1
bool "Linux 3.1.x kernel headers"
- depends on BR2_DEPRECATED
+ depends on BR2_DEPRECATED && !BR2_arc
config BR2_KERNEL_HEADERS_3_2
bool "Linux 3.2.x kernel headers"
+ depends on !BR2_arc
config BR2_KERNEL_HEADERS_3_3
bool "Linux 3.3.x kernel headers"
- depends on BR2_DEPRECATED
+ depends on BR2_DEPRECATED && !BR2_arc
config BR2_KERNEL_HEADERS_3_4
bool "Linux 3.4.x kernel headers"
+ depends on !BR2_arc
config BR2_KERNEL_HEADERS_3_5
bool "Linux 3.5.x kernel headers"
- depends on BR2_DEPRECATED
+ depends on BR2_DEPRECATED && !BR2_arc
config BR2_KERNEL_HEADERS_3_6
bool "Linux 3.6.x kernel headers"
- depends on BR2_DEPRECATED
+ depends on BR2_DEPRECATED && !BR2_arc
config BR2_KERNEL_HEADERS_3_7
bool "Linux 3.7.x kernel headers"
- depends on BR2_DEPRECATED
+ depends on BR2_DEPRECATED && !BR2_arc
config BR2_KERNEL_HEADERS_3_8
bool "Linux 3.8.x kernel headers"
+ depends on !BR2_arc
+
+ config BR2_KERNEL_HEADERS_3_9
+ bool "Linux 3.9.x kernel headers"
config BR2_KERNEL_HEADERS_VERSION
bool "Manually specified Linux version"
@@ -72,5 +79,6 @@ config BR2_DEFAULT_KERNEL_HEADERS
default "3.6.11" if BR2_KERNEL_HEADERS_3_6
default "3.7.10" if BR2_KERNEL_HEADERS_3_7
default "3.8.8" if BR2_KERNEL_HEADERS_3_8
+ default "3.9-rc8" if BR2_KERNEL_HEADERS_3_9
default "2.6" if BR2_KERNEL_HEADERS_SNAP
default $BR2_DEFAULT_KERNEL_VERSION if BR2_KERNEL_HEADERS_VERSION
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 10/12] kernel-headers: Add 3.9-rc8 headers to make ARC work
2013-04-24 10:13 ` [Buildroot] [PATCH v2 10/12] kernel-headers: Add 3.9-rc8 headers to make ARC work Mischa Jonker
@ 2013-04-24 19:41 ` Peter Korsgaard
0 siblings, 0 replies; 24+ messages in thread
From: Peter Korsgaard @ 2013-04-24 19:41 UTC (permalink / raw)
To: buildroot
>>>>> "Mischa" == Mischa Jonker <Mischa.Jonker@synopsys.com> writes:
Mischa> Add 3.9 release candidate kernel, so that the ARC architecture builds.
Mischa> Also make sure that older kernels are not selected for ARC.
The final 3.9 is supposed to be released by the end of the week, so I
would prefer to not add -rc8.
Mischa> Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
Mischa> ---
Mischa> Makefile | 1 +
Mischa> toolchain/kernel-headers/Config.in | 18 +++++++++++++-----
Mischa> 2 files changed, 14 insertions(+), 5 deletions(-)
Mischa> diff --git a/Makefile b/Makefile
Mischa> index 0a91658..8fef492 100644
Mischa> --- a/Makefile
Mischa> +++ b/Makefile
Mischa> @@ -238,6 +238,7 @@ ARCH:=$(call qstrip,$(BR2_ARCH))
Mischa> KERNEL_ARCH:=$(shell echo "$(ARCH)" | sed -e "s/-.*//" \
Mischa> -e s/i.86/i386/ -e s/sun4u/sparc64/ \
Mischa> + -e s/arc.*/arc/ \
Mischa> -e s/arm.*/arm/ -e s/sa110/arm/ \
Mischa> -e s/aarch64/arm64/ \
Mischa> -e s/bfin/blackfin/ \
Mischa> diff --git a/toolchain/kernel-headers/Config.in b/toolchain/kernel-headers/Config.in
Mischa> index ec75c34..1c972f3 100644
Mischa> --- a/toolchain/kernel-headers/Config.in
Mischa> +++ b/toolchain/kernel-headers/Config.in
Mischa> @@ -17,35 +17,42 @@ choice
Mischa> config BR2_KERNEL_HEADERS_3_0
Mischa> bool "Linux 3.0.x kernel headers"
Mischa> + depends on !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_1
Mischa> bool "Linux 3.1.x kernel headers"
Mischa> - depends on BR2_DEPRECATED
Mischa> + depends on BR2_DEPRECATED && !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_2
Mischa> bool "Linux 3.2.x kernel headers"
Mischa> + depends on !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_3
Mischa> bool "Linux 3.3.x kernel headers"
Mischa> - depends on BR2_DEPRECATED
Mischa> + depends on BR2_DEPRECATED && !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_4
Mischa> bool "Linux 3.4.x kernel headers"
Mischa> + depends on !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_5
Mischa> bool "Linux 3.5.x kernel headers"
Mischa> - depends on BR2_DEPRECATED
Mischa> + depends on BR2_DEPRECATED && !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_6
Mischa> bool "Linux 3.6.x kernel headers"
Mischa> - depends on BR2_DEPRECATED
Mischa> + depends on BR2_DEPRECATED && !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_7
Mischa> bool "Linux 3.7.x kernel headers"
Mischa> - depends on BR2_DEPRECATED
Mischa> + depends on BR2_DEPRECATED && !BR2_arc
Mischa> config BR2_KERNEL_HEADERS_3_8
Mischa> bool "Linux 3.8.x kernel headers"
Mischa> + depends on !BR2_arc
Mischa> +
Mischa> + config BR2_KERNEL_HEADERS_3_9
Mischa> + bool "Linux 3.9.x kernel headers"
Mischa> config BR2_KERNEL_HEADERS_VERSION
Mischa> bool "Manually specified Linux version"
Mischa> @@ -72,5 +79,6 @@ config BR2_DEFAULT_KERNEL_HEADERS
Mischa> default "3.6.11" if BR2_KERNEL_HEADERS_3_6
Mischa> default "3.7.10" if BR2_KERNEL_HEADERS_3_7
Mischa> default "3.8.8" if BR2_KERNEL_HEADERS_3_8
Mischa> + default "3.9-rc8" if BR2_KERNEL_HEADERS_3_9
Mischa> default "2.6" if BR2_KERNEL_HEADERS_SNAP
Mischa> default $BR2_DEFAULT_KERNEL_VERSION if BR2_KERNEL_HEADERS_VERSION
Mischa> --
Mischa> 1.7.0.4
Mischa> _______________________________________________
Mischa> buildroot mailing list
Mischa> buildroot at busybox.net
Mischa> http://lists.busybox.net/mailman/listinfo/buildroot
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 11/12] toolchain/gcc: Only enable --with-float when it makes sense
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (9 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 10/12] kernel-headers: Add 3.9-rc8 headers to make ARC work Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-24 10:13 ` [Buildroot] [PATCH v2 12/12] toolchain/gcc: Introduce BR2_ARCH_HAS_NO_GCC_x_y Mischa Jonker
2013-04-25 3:02 ` [Buildroot] [PATCH v2 00/12] RFC: ARC port Thomas Petazzoni
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
According to gcc/config.gcc, only ARM, MIPS and SPARC have the
"--with-float" option when configuring gcc.
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
toolchain/gcc/gcc-uclibc-4.x.mk | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/toolchain/gcc/gcc-uclibc-4.x.mk b/toolchain/gcc/gcc-uclibc-4.x.mk
index 4c77c5c..f4dbcae 100644
--- a/toolchain/gcc/gcc-uclibc-4.x.mk
+++ b/toolchain/gcc/gcc-uclibc-4.x.mk
@@ -65,7 +65,10 @@ endif
# Determine soft-float options
ifeq ($(BR2_SOFT_FLOAT),y)
+# only mips*-*-*, arm*-*-* and sparc*-*-* accept --with-float
+ifeq ($(BR2_arm)$(BR2_armeb)$(BR2_mips)$(BR2_mipsel)$(BR2_sparc)$(BR2_mips64)$(BR2_mips64el),y)
SOFT_FLOAT_CONFIG_OPTION:=--with-float=soft
+endif
ifeq ($(BR2_arm)$(BR2_armeb),y) # only set float-abi for arm
TARGET_SOFT_FLOAT:=-mfloat-abi=soft
else
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 12/12] toolchain/gcc: Introduce BR2_ARCH_HAS_NO_GCC_x_y
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (10 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 11/12] toolchain/gcc: Only enable --with-float when it makes sense Mischa Jonker
@ 2013-04-24 10:13 ` Mischa Jonker
2013-04-25 3:02 ` [Buildroot] [PATCH v2 00/12] RFC: ARC port Thomas Petazzoni
12 siblings, 0 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-04-24 10:13 UTC (permalink / raw)
To: buildroot
This patch eliminates the long "depends on" lines in
toolchain/gcc/Config.in by letting architectures specify
which GCC versions they do not support.
Signed-off-by: Mischa Jonker <mjonker@synopsys.com>
---
arch/Config.in | 11 +++++++++++
arch/Config.in.arc | 7 +++++++
arch/Config.in.arm | 10 ++++++++++
arch/Config.in.powerpc | 9 +++++++++
arch/Config.in.sparc | 24 ++++++++++++++++++++++++
arch/Config.in.x86 | 2 ++
toolchain/gcc/Config.in | 42 +++++++++++++++++++++++++++++++++++-------
7 files changed, 98 insertions(+), 7 deletions(-)
diff --git a/arch/Config.in b/arch/Config.in
index 2006f1e..c73dded 100644
--- a/arch/Config.in
+++ b/arch/Config.in
@@ -40,6 +40,10 @@ config BR2_armeb
config BR2_aarch64
bool "AArch64"
select BR2_ARCH_IS_64
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
+ select BR2_ARCH_HAS_NO_GCC_4_5
+ select BR2_ARCH_HAS_NO_GCC_4_6
help
Aarch64 is a 64-bit architecture developed by ARM Holdings.
http://www.arm.com/products/processors/instruction-set-architectures/armv8-architecture.php
@@ -48,6 +52,13 @@ config BR2_aarch64
config BR2_avr32
bool "AVR32"
select BR2_SOFT_FLOAT
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
+ select BR2_ARCH_HAS_NO_GCC_4_5
+ select BR2_ARCH_HAS_NO_GCC_4_6
+ select BR2_ARCH_HAS_NO_GCC_4_7
+ select BR2_ARCH_HAS_NO_GCC_4_8
+ select BR2_ARCH_HAS_NO_GCC_SNAP
help
The AVR32 is a 32-bit RISC microprocessor architecture designed by
Atmel.
diff --git a/arch/Config.in.arc b/arch/Config.in.arc
index 9f68b46..2bde0bf 100644
--- a/arch/Config.in.arc
+++ b/arch/Config.in.arc
@@ -5,6 +5,13 @@ config BR2_ARCH
config BR2_arc
bool
default y if BR2_arcle || BR2_arceb
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
+ select BR2_ARCH_HAS_NO_GCC_4_5
+ select BR2_ARCH_HAS_NO_GCC_4_6
+ select BR2_ARCH_HAS_NO_GCC_4_7
+ select BR2_ARCH_HAS_NO_GCC_4_8
+ select BR2_ARCH_HAS_NO_GCC_SNAP
config BR2_ENDIAN
default "LITTLE" if BR2_arcle
diff --git a/arch/Config.in.arm b/arch/Config.in.arm
index f706dcc..d9a2cef 100644
--- a/arch/Config.in.arm
+++ b/arch/Config.in.arm
@@ -36,17 +36,27 @@ config BR2_arm1176jzf_s
config BR2_cortex_a5
bool "cortex-A5"
select BR2_ARM_CPU_MAYBE_HAS_NEON
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
config BR2_cortex_a8
bool "cortex-A8"
select BR2_ARM_CPU_HAS_NEON
+ select BR2_ARCH_HAS_NO_GCC_4_3
config BR2_cortex_a9
bool "cortex-A9"
select BR2_ARM_CPU_MAYBE_HAS_NEON
+ select BR2_ARCH_HAS_NO_GCC_4_3
config BR2_cortex_a15
bool "cortex-A15"
select BR2_ARM_CPU_HAS_NEON
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
+ select BR2_ARCH_HAS_NO_GCC_4_5
config BR2_fa526
bool "fa526/626"
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
+ select BR2_ARCH_HAS_NO_GCC_4_5
config BR2_strongarm
bool "strongarm sa110/sa1100"
config BR2_xscale
diff --git a/arch/Config.in.powerpc b/arch/Config.in.powerpc
index 8643efc..6cd6f17 100644
--- a/arch/Config.in.powerpc
+++ b/arch/Config.in.powerpc
@@ -20,12 +20,18 @@ config BR2_powerpc_440fp
bool "440 with FPU"
config BR2_powerpc_464
bool "464"
+ select BR2_ARCH_HAS_NO_GCC_4_3
config BR2_powerpc_464fp
bool "464 with FPU"
+ select BR2_ARCH_HAS_NO_GCC_4_3
config BR2_powerpc_476
bool "476"
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
config BR2_powerpc_476fp
bool "476 with FPU"
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
config BR2_powerpc_505
bool "505"
config BR2_powerpc_601
@@ -66,10 +72,13 @@ config BR2_powerpc_8548
bool "8548 / e500v2"
config BR2_powerpc_e300c2
bool "e300c2"
+ select BR2_ARCH_HAS_NO_GCC_4_3
config BR2_powerpc_e300c3
bool "e300c3"
+ select BR2_ARCH_HAS_NO_GCC_4_3
config BR2_powerpc_e500mc
bool "e500mc"
+ select BR2_ARCH_HAS_NO_GCC_4_3
endchoice
choice
diff --git a/arch/Config.in.sparc b/arch/Config.in.sparc
index 33204a2..c2e6077 100644
--- a/arch/Config.in.sparc
+++ b/arch/Config.in.sparc
@@ -9,12 +9,36 @@ config BR2_sparc_v8
bool "v8"
config BR2_sparc_sparchfleon
bool "hfleon"
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_5
+ select BR2_ARCH_HAS_NO_GCC_4_6
+ select BR2_ARCH_HAS_NO_GCC_4_7
+ select BR2_ARCH_HAS_NO_GCC_4_8
+ select BR2_ARCH_HAS_NO_GCC_SNAP
config BR2_sparc_sparchfleonv8
bool "hfleonv8"
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_5
+ select BR2_ARCH_HAS_NO_GCC_4_6
+ select BR2_ARCH_HAS_NO_GCC_4_7
+ select BR2_ARCH_HAS_NO_GCC_4_8
+ select BR2_ARCH_HAS_NO_GCC_SNAP
config BR2_sparc_sparcsfleon
bool "sfleon"
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_5
+ select BR2_ARCH_HAS_NO_GCC_4_6
+ select BR2_ARCH_HAS_NO_GCC_4_7
+ select BR2_ARCH_HAS_NO_GCC_4_8
+ select BR2_ARCH_HAS_NO_GCC_SNAP
config BR2_sparc_sparcsfleonv8
bool "sfleonv8"
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_5
+ select BR2_ARCH_HAS_NO_GCC_4_6
+ select BR2_ARCH_HAS_NO_GCC_4_7
+ select BR2_ARCH_HAS_NO_GCC_4_8
+ select BR2_ARCH_HAS_NO_GCC_SNAP
endchoice
config BR2_ARCH
diff --git a/arch/Config.in.x86 b/arch/Config.in.x86
index ce30605..ce4fd11 100644
--- a/arch/Config.in.x86
+++ b/arch/Config.in.x86
@@ -86,6 +86,8 @@ config BR2_x86_atom
select BR2_X86_CPU_HAS_SSE2
select BR2_X86_CPU_HAS_SSE3
select BR2_X86_CPU_HAS_SSSE3
+ select BR2_ARCH_HAS_NO_GCC_4_3
+ select BR2_ARCH_HAS_NO_GCC_4_4
config BR2_x86_k6
bool "k6"
select BR2_X86_CPU_HAS_MMX
diff --git a/toolchain/gcc/Config.in b/toolchain/gcc/Config.in
index 851afa7..ae8aab4 100644
--- a/toolchain/gcc/Config.in
+++ b/toolchain/gcc/Config.in
@@ -1,5 +1,33 @@
# Choose gcc version.
+config BR2_ARCH_HAS_NO_GCC_4_3
+ bool
+ default n
+
+config BR2_ARCH_HAS_NO_GCC_4_4
+ bool
+ default n
+
+config BR2_ARCH_HAS_NO_GCC_4_5
+ bool
+ default n
+
+config BR2_ARCH_HAS_NO_GCC_4_6
+ bool
+ default n
+
+config BR2_ARCH_HAS_NO_GCC_4_7
+ bool
+ default n
+
+config BR2_ARCH_HAS_NO_GCC_4_8
+ bool
+ default n
+
+config BR2_ARCH_HAS_NO_GCC_SNAP
+ bool
+ default n
+
comment "GCC Options"
config BR2_GCC_NEEDS_MPC
@@ -23,35 +51,35 @@ choice
bool "gcc 4.2.2-avr32-2.1.5"
config BR2_GCC_VERSION_4_3_X
- depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8 && !BR2_cortex_a5 && !BR2_cortex_a8 && !BR2_cortex_a9 && !BR2_cortex_a15 && !BR2_x86_atom && !BR2_powerpc_e300c2 && !BR2_powerpc_e300c3 && !BR2_powerpc_e500mc && !BR2_powerpc_464 && !BR2_powerpc_464fp && !BR2_powerpc_476 && !BR2_powerpc_476fp && !BR2_fa526
+ depends on !BR2_ARCH_HAS_NO_GCC_4_3
bool "gcc 4.3.x"
config BR2_GCC_VERSION_4_4_X
- depends on !BR2_arc && !BR2_avr32 && !BR2_cortex_a5 && !BR2_cortex_a15 && !BR2_x86_atom && !BR2_powerpc_476 && !BR2_powerpc_476fp && !BR2_fa526
+ depends on !BR2_ARCH_HAS_NO_GCC_4_4
bool "gcc 4.4.x"
config BR2_GCC_VERSION_4_5_X
- depends on !BR2_arc && !BR2_avr32 && !BR2_cortex_a15 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8 && !BR2_fa526
+ depends on !BR2_ARCH_HAS_NO_GCC_4_5
select BR2_GCC_NEEDS_MPC
bool "gcc 4.5.x"
config BR2_GCC_VERSION_4_6_X
- depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_ARCH_HAS_NO_GCC_4_6
select BR2_GCC_NEEDS_MPC
bool "gcc 4.6.x"
config BR2_GCC_VERSION_4_7_X
- depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_ARCH_HAS_NO_GCC_4_7
select BR2_GCC_NEEDS_MPC
bool "gcc 4.7.x"
config BR2_GCC_VERSION_4_8_X
- depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_ARCH_HAS_NO_GCC_4_8
select BR2_GCC_NEEDS_MPC
bool "gcc 4.8.x"
config BR2_GCC_VERSION_SNAP
- depends on !BR2_arc && !BR2_avr32 && !BR2_sparc_sparchfleon && !BR2_sparc_sparchfleonv8 && !BR2_sparc_sparcsfleon && !BR2_sparc_sparcsfleonv8
+ depends on !BR2_ARCH_HAS_NO_GCC_SNAP
select BR2_GCC_NEEDS_MPC
bool "gcc snapshot"
endchoice
--
1.7.0.4
^ permalink raw reply related [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-04-24 10:13 [Buildroot] [PATCH v2 00/12] RFC: ARC port Mischa Jonker
` (11 preceding siblings ...)
2013-04-24 10:13 ` [Buildroot] [PATCH v2 12/12] toolchain/gcc: Introduce BR2_ARCH_HAS_NO_GCC_x_y Mischa Jonker
@ 2013-04-25 3:02 ` Thomas Petazzoni
2013-04-25 11:01 ` Mischa Jonker
12 siblings, 1 reply; 24+ messages in thread
From: Thomas Petazzoni @ 2013-04-25 3:02 UTC (permalink / raw)
To: buildroot
Dear Mischa Jonker,
On Wed, 24 Apr 2013 12:13:11 +0200, Mischa Jonker wrote:
> Thanks for the prompt feedback that I have received on the patches.
> Here's a new revision of the patchset to introduce ARC support in
> BuildRoot; I think I have addressed all the comments received from
> Thomas and Arnout.
Thanks for the quick turnaround! This time, I actually applied and
tested your patches in the autobuilders environment, and I had some
issues.
The first issue is that your version of binutils require flex and bison
installed on the host, so we have to add these as dependencies of
binutils. The binutils.patch attached does that, but it does that
unconditionally, regardless of the binutils version being chosen. Since
the recent binutils versions do not require building flex and bison,
I'd prefer to make this dependency conditional on which version of
binutils is being built.
The second issue is that gcc 4.4.x also require flex (and maybe bison,
but I haven't checked). So I've added host-flex and host-bison as gcc
dependencies. Unfortunately, gcc doesn't use the package
infrastructure, so it doesn't add host/usr/bin to the PATH, so I had to
change the gcc makefile to use $(HOST_MAKE_ENV) and $(TARGET_MAKE_ENV)
where appropriate. This is the second 'gcc.patch' attached does. Here
as well, it makes the host-flex and host-bison dependency
unconditional, even though the latest versions of gcc do not require
this. A proper patch would have to make this dependency conditional on
the version of gcc being used.
(Note: both patches are quick and dirty, they don't have any
description or signed-off-by. Feel free to re-use them and apply your
signed-off-by on them, I don't care about authorship on those patches.)
Note that those flex and bison issues are visible in the autobuilder
environment because the build runs in a minimal chroot that has only
the strict, minimal dependencies required by Buildroot. That probably
explains why you haven't seen those problems until now.
Then, once this was fixed, the build went on, but failed at the gcc
intermediate step, with some pthread related issue:
In file included from /home/test/outputs/arc/toolchain/uClibc_dev//usr/include/stdio.h:71,
from /home/test/outputs/arc/toolchain/gcc-4.4.7-arc/libgcc/../gcc/tsystem.h:87,
from /home/test/outputs/arc/toolchain/gcc-4.4.7-arc/libgcc/../gcc/libgcc2.c:29:
/home/test/outputs/arc/toolchain/uClibc_dev//usr/include/bits/uClibc_stdio.h:207: error: expected specifier-qualifier-list before 'pthread_mutex_t'
make[3]: *** [_negdi2.o] Error 1
make[3]: *** Waiting for unfinished jobs....
The defconfig I was trying to build is very simple:
$ cat defconfig
BR2_arcle=y
Do you have an idea for this pthread_mutex_t issue? Maybe ARC doesn't
support NPTL or something?
Also, do you have a public repo to push your changes to? Since your
patch series has become quite long, it would make it easier for us to
test it as a whole.
Thanks!
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: binutils.patch
Type: text/x-patch
Size: 567 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20130425/ab026573/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc.patch
Type: text/x-patch
Size: 3705 bytes
Desc: not available
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20130425/ab026573/attachment-0001.bin>
^ permalink raw reply [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-04-25 3:02 ` [Buildroot] [PATCH v2 00/12] RFC: ARC port Thomas Petazzoni
@ 2013-04-25 11:01 ` Mischa Jonker
2013-04-29 20:45 ` Thomas Petazzoni
0 siblings, 1 reply; 24+ messages in thread
From: Mischa Jonker @ 2013-04-25 11:01 UTC (permalink / raw)
To: buildroot
Hi Thomas,
> (host-flex/host-bison)
Thanks for the patches! I have integrated them and added version checks. I'm not 100% certain from which version onwards the dependency has been removed, but my colleague says that he didn't encounter these dependencies with GCC 4.5, so I made it depend on 4.2,4.3,4.4.
> Do you have an idea for this pthread_mutex_t issue? Maybe ARC doesn't support NPTL or something?
Correct, we don't have NPTL support yet. It was the initial planning to have this finished before we went out with the BuildRoot patches, but priorities shifted, and I hadn't disabled it yet. Added a patch for that.
> Also, do you have a public repo to push your changes to? Since your patch series has become quite long, it would make it easier for us to test it as a whole.
Our github site has a BuildRoot repository:
https://github.com/foss-for-synopsys-dwc-arc-processors/buildroot
I'm regularly rebasing & updating patches, and pushing them to this repo. Right now, there are two branches/tags that are relevant:
* master_arc_20130425
* master_3.9_arc_20130425
The only difference between the two is that the first relies on 3.9-rc8, and the second on 3.9. So the second branch doesn't build right now, but should build after this weekend.
BTW: would you like to repost the new set of patches on the mailing list, or would you rather have a look at it on github?
BTW2: I noticed that GNU config went from GPLv2 to GPLv3, I'm not sure what the impact would be for BuildRoot, as it is really part of BuildRoot (not downloaded).
Mischa
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-04-25 11:01 ` Mischa Jonker
@ 2013-04-29 20:45 ` Thomas Petazzoni
2013-04-30 16:06 ` Arnout Vandecappelle
0 siblings, 1 reply; 24+ messages in thread
From: Thomas Petazzoni @ 2013-04-29 20:45 UTC (permalink / raw)
To: buildroot
Dear Mischa Jonker,
On Thu, 25 Apr 2013 11:01:15 +0000, Mischa Jonker wrote:
> > (host-flex/host-bison)
> Thanks for the patches! I have integrated them and added version
> checks. I'm not 100% certain from which version onwards the
> dependency has been removed, but my colleague says that he didn't
> encounter these dependencies with GCC 4.5, so I made it depend on
> 4.2,4.3,4.4.
Ok.
> > Do you have an idea for this pthread_mutex_t issue? Maybe ARC
> > doesn't support NPTL or something?
> Correct, we don't have NPTL support yet. It was the initial planning
> to have this finished before we went out with the BuildRoot patches,
> but priorities shifted, and I hadn't disabled it yet. Added a patch
> for that.
Good.
> > Also, do you have a public repo to push your changes to? Since your
> > patch series has become quite long, it would make it easier for us
> > to test it as a whole.
> Our github site has a BuildRoot repository:
> https://github.com/foss-for-synopsys-dwc-arc-processors/buildroot
>
> I'm regularly rebasing & updating patches, and pushing them to this
> repo. Right now, there are two branches/tags that are relevant:
> * master_arc_20130425
> * master_3.9_arc_20130425
>
> The only difference between the two is that the first relies on
> 3.9-rc8, and the second on 3.9. So the second branch doesn't build
> right now, but should build after this weekend.
3.9 has been released now, so that should solve your problem. Could you
rebase your patch series on top of master, Peter has added 3.9 as a
supported kernel.
I tested your branch, and it built fine for me on the autobuilders, so
in terms of basic buildability, we're good.
> BTW: would you like to repost the new set of patches on the mailing
> list, or would you rather have a look at it on github? BTW2: I
> noticed that GNU config went from GPLv2 to GPLv3, I'm not sure what
> the impact would be for BuildRoot, as it is really part of BuildRoot
> (not downloaded).
Yes, they should be reposted, but I have a number of comments on them:
* 'toolchain/gcc: Add host-{flex,bison} dependencies for GCC
4.2,4.3,4.4' should be earlier in the series, i.e before 'arc: add
gcc for ARC'.
* 'package/binutils: add host-{flex,bison} dependencies for 2.19-arc'
should probably be squashed into 'arc: Add support for ARC-specific
binutils'.
* I am not entirely happy with 'toolchain/gcc: Introduce
BR2_ARCH_HAS_NO_GCC_x_y' using a reverted logic. I haven't thought
too much about it, but wouldn't it be possible to instead do
something like BR2_ARCH_NEEDS_GCC_4_6_PLUS, and then do something
like depends !BR2_ARCH_NEEDS_GCC_4_6_PLUS on all gcc versions <
4.6 ? Hum, the problem is that it works with architecture that are
supported starting from a given upstream gcc version, but not
architecture that are supported only in 4.2-avr, or in 4.4-arc, etc.
Maybe others will have a suggestion on this point?
Other than that, it looks good to me.
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 24+ messages in thread* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-04-29 20:45 ` Thomas Petazzoni
@ 2013-04-30 16:06 ` Arnout Vandecappelle
2013-04-30 22:09 ` Thomas Petazzoni
0 siblings, 1 reply; 24+ messages in thread
From: Arnout Vandecappelle @ 2013-04-30 16:06 UTC (permalink / raw)
To: buildroot
On 29/04/13 22:45, Thomas Petazzoni wrote:
> * I am not entirely happy with 'toolchain/gcc: Introduce
> BR2_ARCH_HAS_NO_GCC_x_y' using a reverted logic. I haven't thought
> too much about it, but wouldn't it be possible to instead do
> something like BR2_ARCH_NEEDS_GCC_4_6_PLUS, and then do something
> like depends !BR2_ARCH_NEEDS_GCC_4_6_PLUS on all gcc versions <
> 4.6 ? Hum, the problem is that it works with architecture that are
> supported starting from a given upstream gcc version, but not
> architecture that are supported only in 4.2-avr, or in 4.4-arc, etc.
>
> Maybe others will have a suggestion on this point?
Not entirely clean either, but what about the following:
[toolchain/gcc/Config.in]
config BR2_ARCH_HAS_ALL_GCC
bool
config BR2_ARCH_HAS_GCC_4_4
bool
default y if BR2_ARCH_HAS_ALL_GCC
[arch/Config.in]
config BR2_mips
select BR2_ARCH_HAS_ALL_GCC
...
[arch/Config.in.arm]
config BR2_arm1176jzf_s
select BR2_ARCH_HAS_ALL_GCC
...
config BR2_cortex_a8
select BR2_ARCH_HAS_GCC_4_4
...
Regards,
Arnout
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-04-30 16:06 ` Arnout Vandecappelle
@ 2013-04-30 22:09 ` Thomas Petazzoni
2013-05-02 14:03 ` Mischa Jonker
0 siblings, 1 reply; 24+ messages in thread
From: Thomas Petazzoni @ 2013-04-30 22:09 UTC (permalink / raw)
To: buildroot
Dear Arnout Vandecappelle,
On Tue, 30 Apr 2013 18:06:27 +0200, Arnout Vandecappelle wrote:
> On 29/04/13 22:45, Thomas Petazzoni wrote:
> > * I am not entirely happy with 'toolchain/gcc: Introduce
> > BR2_ARCH_HAS_NO_GCC_x_y' using a reverted logic. I haven't thought
> > too much about it, but wouldn't it be possible to instead do
> > something like BR2_ARCH_NEEDS_GCC_4_6_PLUS, and then do something
> > like depends !BR2_ARCH_NEEDS_GCC_4_6_PLUS on all gcc versions <
> > 4.6 ? Hum, the problem is that it works with architecture that are
> > supported starting from a given upstream gcc version, but not
> > architecture that are supported only in 4.2-avr, or in 4.4-arc, etc.
> >
> > Maybe others will have a suggestion on this point?
>
> Not entirely clean either, but what about the following:
>
> [toolchain/gcc/Config.in]
> config BR2_ARCH_HAS_ALL_GCC
> bool
>
> config BR2_ARCH_HAS_GCC_4_4
> bool
> default y if BR2_ARCH_HAS_ALL_GCC
>
> [arch/Config.in]
> config BR2_mips
> select BR2_ARCH_HAS_ALL_GCC
> ...
>
> [arch/Config.in.arm]
> config BR2_arm1176jzf_s
> select BR2_ARCH_HAS_ALL_GCC
> ...
> config BR2_cortex_a8
> select BR2_ARCH_HAS_GCC_4_4
> ...
Could be good. That said, this problem is quite different from doing
the ARC port. So maybe we could instead tell Mischa to revert back to
its original solution (adding yet another set of !BR2_arc everywhere),
and we can work on a solution to improve this as a follow-up patch. Of
course, if Mischa is willing to work on this, that'd be great, but I
don't think it's really mandatory to make this cleanup a strict
requirement to get the ARC code merged. The existing set of 'depends
on' for gcc versions is already ugly, it's not specifically the ARC
stuff that makes it ugly.
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-04-30 22:09 ` Thomas Petazzoni
@ 2013-05-02 14:03 ` Mischa Jonker
2013-05-02 15:12 ` Thomas Petazzoni
2013-05-02 16:32 ` Arnout Vandecappelle
0 siblings, 2 replies; 24+ messages in thread
From: Mischa Jonker @ 2013-05-02 14:03 UTC (permalink / raw)
To: buildroot
> > Maybe others will have a suggestion on this point?
>
> Not entirely clean either, but what about the following:
>
> [toolchain/gcc/Config.in]
> config BR2_ARCH_HAS_ALL_GCC
> bool
>
> config BR2_ARCH_HAS_GCC_4_4
> bool
> default y if BR2_ARCH_HAS_ALL_GCC
>
> [arch/Config.in]
> config BR2_mips
> select BR2_ARCH_HAS_ALL_GCC
> ...
>
> [arch/Config.in.arm]
> config BR2_arm1176jzf_s
> select BR2_ARCH_HAS_ALL_GCC
> ...
> config BR2_cortex_a8
> select BR2_ARCH_HAS_GCC_4_4
> ...
The problem with this is that you end up in Config.in.arm with a lot of "select BR2_ARCH_HAS_ALL_GCC" lines. It is more logical, but it adds a lot of clutter IMHO.
Unfortunately, we cannot make "BR2_ARCH_HAS_ALL_GCC" default y, because we don't have the 'deselect' keyword, so we need to add it everywhere. For ARM and x86, the architectures that aren't supported by all GCC versions are the exception, so instead of adding additional lines for just the exceptions, we end up with extra code everywhere.
I also tried to let default values depend on earlier versions:
config BR2_ARCH_HAS_GCC_4_5
bool
default y if BR2_ARCH_HAS_GCC_4_4
But this doesn't work for several architectures, such as BR2_sparc_sparcsfleon, that do have GCC 4.4, but no 4.5 for instance.
The reverse logic helps in the sense that the BR2_HAS_NO_GCC_x_y lines will go away over time when old GCC versions get deprecated.
I will send both variants later today.
Mischa
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-05-02 14:03 ` Mischa Jonker
@ 2013-05-02 15:12 ` Thomas Petazzoni
2013-05-02 15:18 ` Mischa Jonker
2013-05-02 16:32 ` Arnout Vandecappelle
1 sibling, 1 reply; 24+ messages in thread
From: Thomas Petazzoni @ 2013-05-02 15:12 UTC (permalink / raw)
To: buildroot
Dear Mischa Jonker,
On Thu, 2 May 2013 14:03:53 +0000, Mischa Jonker wrote:
[...]
> But this doesn't work for several architectures, such as
> BR2_sparc_sparcsfleon, that do have GCC 4.4, but no 4.5 for instance.
>
> The reverse logic helps in the sense that the BR2_HAS_NO_GCC_x_y
> lines will go away over time when old GCC versions get deprecated.
>
> I will send both variants later today.
As I suggested in an earlier e-mail, I think you should just not care
about this problem for now, and add the multiple 'depends on !BR2_arc'
as you were doing in your first version of the patch set. Your patch
set already has a good number of patches, so let's merge it, and
improve on top of that.
Thanks!
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-05-02 15:12 ` Thomas Petazzoni
@ 2013-05-02 15:18 ` Mischa Jonker
2013-05-02 16:30 ` Thomas Petazzoni
0 siblings, 1 reply; 24+ messages in thread
From: Mischa Jonker @ 2013-05-02 15:18 UTC (permalink / raw)
To: buildroot
Hi Thomas,
>> I will send both variants later today.
> As I suggested in an earlier e-mail, I think you should just not care about
> this problem for now, and add the multiple 'depends on !BR2_arc'
> as you were doing in your first version of the patch set. Your patch set
> already has a good number of patches, so let's merge it, and improve on
> top of that.
The v3 patch set does exactly that if I'm not mistaken. This is supposed to be
the improvement part already:-)
Mischa
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-05-02 15:18 ` Mischa Jonker
@ 2013-05-02 16:30 ` Thomas Petazzoni
0 siblings, 0 replies; 24+ messages in thread
From: Thomas Petazzoni @ 2013-05-02 16:30 UTC (permalink / raw)
To: buildroot
Dear Mischa Jonker,
On Thu, 2 May 2013 15:18:50 +0000, Mischa Jonker wrote:
> > As I suggested in an earlier e-mail, I think you should just not care about
> > this problem for now, and add the multiple 'depends on !BR2_arc'
> > as you were doing in your first version of the patch set. Your patch set
> > already has a good number of patches, so let's merge it, and improve on
> > top of that.
>
> The v3 patch set does exactly that if I'm not mistaken. This is supposed to be
> the improvement part already:-)
Yeah, seen that. I replied before I saw your v3, and the gcc patches
that come after that. I'll focus on the ARC stuff for now.
Thanks!
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 24+ messages in thread
* [Buildroot] [PATCH v2 00/12] RFC: ARC port
2013-05-02 14:03 ` Mischa Jonker
2013-05-02 15:12 ` Thomas Petazzoni
@ 2013-05-02 16:32 ` Arnout Vandecappelle
1 sibling, 0 replies; 24+ messages in thread
From: Arnout Vandecappelle @ 2013-05-02 16:32 UTC (permalink / raw)
To: buildroot
On 02/05/13 16:03, Mischa Jonker wrote:
>>> Maybe others will have a suggestion on this point?
>>
>> Not entirely clean either, but what about the following:
>>
>> [toolchain/gcc/Config.in]
>> config BR2_ARCH_HAS_ALL_GCC
>> bool
>>
>> config BR2_ARCH_HAS_GCC_4_4
>> bool
>> default y if BR2_ARCH_HAS_ALL_GCC
>>
>> [arch/Config.in]
>> config BR2_mips
>> select BR2_ARCH_HAS_ALL_GCC
>> ...
>>
>> [arch/Config.in.arm]
>> config BR2_arm1176jzf_s
>> select BR2_ARCH_HAS_ALL_GCC
>> ...
>> config BR2_cortex_a8
>> select BR2_ARCH_HAS_GCC_4_4
>> ...
>
> The problem with this is that you end up in Config.in.arm with a lot of "select BR2_ARCH_HAS_ALL_GCC" lines. It is more logical, but it adds a lot of clutter IMHO.
Okay, yet another idea. I don't know if this will actually work.
[toolchain/gcc/Config.in]
config BR2_ARCH_HAS_ALL_GCC
bool
default y if !(BR2_ARCH_HAS_GCC_4_4 || BR2_ARCH_HAS_GCC_4_5 ...)
config BR2_ARCH_HAS_GCC_4_4
bool
config BR2_GCC_VERSION_4_4_X
depends on BR2_ARCH_HAS_ALL_GCC || BR2_ARCH_HAS_GCC_4_4
> Unfortunately, we cannot make "BR2_ARCH_HAS_ALL_GCC" default y, because we don't have the 'deselect' keyword, so we need to add it everywhere. For ARM and x86, the architectures that aren't supported by all GCC versions are the exception, so instead of adding additional lines for just the exceptions, we end up with extra code everywhere.
>
> I also tried to let default values depend on earlier versions:
> config BR2_ARCH_HAS_GCC_4_5
> bool
> default y if BR2_ARCH_HAS_GCC_4_4
>
> But this doesn't work for several architectures, such as BR2_sparc_sparcsfleon, that do have GCC 4.4, but no 4.5 for instance.
>
> The reverse logic helps in the sense that the BR2_HAS_NO_GCC_x_y lines will go away over time when old GCC versions get deprecated.
Yes, looking at the alternatives, the negative logic isn't that bad...
However, the advantage of the positive logic is that it is slightly
more future-safe. When adding a new gcc version, you have to remember to
also add all the negative cases. Of course, you also have to remember to
add a new positive case, but it is less bad if you forget that.
>
> I will send both variants later today.
As Thomas said, don't feel obliged to continue working on this refactoring.
Regards,
Arnout
> Mischa
>
>
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
^ permalink raw reply [flat|nested] 24+ messages in thread