This is the mail archive of the
binutils-cvs@sourceware.org
mailing list for the binutils project.
[binutils-gdb] Fixes a bug building the ARM Linux kernel with a toolchain compiled with CPU_DEFAULT set.
- From: Nick Clifton <nickc at sourceware dot org>
- To: bfd-cvs at sourceware dot org
- Date: 10 Mar 2015 10:02:59 -0000
- Subject: [binutils-gdb] Fixes a bug building the ARM Linux kernel with a toolchain compiled with CPU_DEFAULT set.
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=73f43896e3bfcb090552f359422857a0bedd77f6
commit 73f43896e3bfcb090552f359422857a0bedd77f6
Author: Nick Clifton <nickc@redhat.com>
Date: Tue Mar 10 10:01:45 2015 +0000
Fixes a bug building the ARM Linux kernel with a toolchain compiled with CPU_DEFAULT set.
PR gas/17852
* config/tc-arm.c (md_begin): Ensure that selected_cpu is
initialised when CPU_DEFAULT is defined.
Diff:
---
gas/ChangeLog | 6 ++++++
gas/config/tc-arm.c | 2 ++
2 files changed, 8 insertions(+)
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 3044668..6738d51 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,9 @@
+2015-03-10 Nick Clifton <nickc@redhat.com>
+
+ PR gas/17852
+ * config/tc-arm.c (md_begin): Ensure that selected_cpu is
+ initialised when CPU_DEFAULT is defined.
+
2015-03-05 Nick Clifton <nickc@redhat.com>
* config/tc-v850.c (md_parse_option): Fix code to set or clear
diff --git a/gas/config/tc-arm.c b/gas/config/tc-arm.c
index 08155ac..c5e627c 100644
--- a/gas/config/tc-arm.c
+++ b/gas/config/tc-arm.c
@@ -23951,6 +23951,8 @@ md_begin (void)
mcpu_cpu_opt = &cpu_default;
selected_cpu = cpu_default;
}
+ else if (no_cpu_selected ())
+ selected_cpu = cpu_default;
#else
if (mcpu_cpu_opt)
selected_cpu = *mcpu_cpu_opt;