summaryrefslogtreecommitdiffstats
path: root/gcc/config/avr/avr.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/config/avr/avr.c')
-rw-r--r--gcc/config/avr/avr.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/gcc/config/avr/avr.c b/gcc/config/avr/avr.c
index b254c6ba027..5167ee65ada 100644
--- a/gcc/config/avr/avr.c
+++ b/gcc/config/avr/avr.c
@@ -114,6 +114,9 @@ int avr_mega_p = 0;
/* Enhanced core: use "movw", "mul", ... */
int avr_enhanced_p = 0;
+/* Assembler only. */
+static int avr_asm_only_p = 0;
+
enum avr_arch {
AVR1 = 1,
AVR2,
@@ -227,7 +230,7 @@ avr_override_options ()
{
case AVR1:
default:
- error ("MCU `%s' not supported", avr_mcu_name);
+ avr_asm_only_p = 1;
/* ... fall through ... */
case AVR2: avr_enhanced_p = 0; avr_mega_p = 0; break;
case AVR3: avr_enhanced_p = 0; avr_mega_p = 1; break;
@@ -4792,6 +4795,9 @@ void
asm_file_start (file)
FILE *file;
{
+ if (avr_asm_only_p)
+ error ("MCU `%s' supported for assembler only", avr_mcu_name);
+
output_file_directive (file, main_input_filename);
fprintf (file, "\t.arch %s\n", avr_mcu_name);
fputs ("__SREG__ = 0x3f\n"
OpenPOWER on IntegriCloud