| 1 |
/* Specs definitions for AVR 8-bit microcontrollers. |
| 2 |
|
| 3 |
Copyright (C) 2012-2025 Free Software Foundation, Inc. |
| 4 |
Contributed by Georg-Johann Lay ([email protected]) |
| 5 |
|
| 6 |
This file is part of GCC. |
| 7 |
|
| 8 |
GCC is free software; you can redistribute it and/or modify |
| 9 |
it under the terms of the GNU General Public License as published by |
| 10 |
the Free Software Foundation; either version 3, or (at your option) |
| 11 |
any later version. |
| 12 |
|
| 13 |
GCC is distributed in the hope that it will be useful, |
| 14 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 16 |
GNU General Public License for more details. |
| 17 |
|
| 18 |
You should have received a copy of the GNU General Public License |
| 19 |
along with GCC; see the file COPYING3. If not see |
| 20 |
<http://www.gnu.org/licenses/>. */ |
| 21 |
|
| 22 |
|
| 23 |
/* Default specs layout. The actual definitions might be superseeded |
| 24 |
by device- or OS- specific files, like avrlibc.h, ../rtems.h, etc. |
| 25 |
The specs are repeated in the device specs files. Subspecs are |
| 26 |
specs known to GCC or specs defined in the device specs files. */ |
| 27 |
|
| 28 |
|
| 29 |
#undef CPLUSPLUS_CPP_SPEC |
| 30 |
#define CPLUSPLUS_CPP_SPEC \ |
| 31 |
"%(cpp)" |
| 32 |
|
| 33 |
#undef CC1_SPEC |
| 34 |
#define CC1_SPEC \ |
| 35 |
"%(cc1_n_flash) " \ |
| 36 |
"%(cc1_errata_skip) " \ |
| 37 |
"%(cc1_rmw) " \ |
| 38 |
"%(cc1_absdata) " \ |
| 39 |
"%(cc1_rodata_in_ram) " |
| 40 |
|
| 41 |
#undef CC1PLUS_SPEC |
| 42 |
#define CC1PLUS_SPEC \ |
| 43 |
"%(cc1) " \ |
| 44 |
"%{!frtti:-fno-rtti} " \ |
| 45 |
"%{!fenforce-eh-specs:-fno-enforce-eh-specs} " \ |
| 46 |
"%{!fexceptions:-fno-exceptions} " |
| 47 |
|
| 48 |
#define ASM_RELAX_SPEC \ |
| 49 |
"%{mrelax:--mlink-relax} " |
| 50 |
|
| 51 |
#undef ASM_SPEC |
| 52 |
#define ASM_SPEC \ |
| 53 |
"%(asm_arch) " \ |
| 54 |
"%(asm_relax) " \ |
| 55 |
"%(asm_rmw) " \ |
| 56 |
"%(asm_gccisr) " \ |
| 57 |
"%(asm_errata_skip) " |
| 58 |
|
| 59 |
#define LINK_RELAX_SPEC \ |
| 60 |
"%{!r:%{mrelax:--relax}} " |
| 61 |
|
| 62 |
#undef LINK_SPEC |
| 63 |
#define LINK_SPEC \ |
| 64 |
"%(link_arch) " \ |
| 65 |
"%(link_data_start) " \ |
| 66 |
"%(link_text_start) " \ |
| 67 |
"%(link_relax) " \ |
| 68 |
"%(link_pmem_wrap) " \ |
| 69 |
"%(link_rodata_in_ram) " \ |
| 70 |
"%(link_no_call_main) " \ |
| 71 |
"%{shared:%eshared is not supported} " |
| 72 |
|
| 73 |
#undef LIB_SPEC |
| 74 |
#define LIB_SPEC " %{!mmcu=avr1:-lc} " |
| 75 |
|
| 76 |
#undef LIBGCC_SPEC |
| 77 |
#define LIBGCC_SPEC " %{!mmcu=avr1:-lgcc} " |
| 78 |
|
| 79 |
#define STARTFILE_SPEC "" |
| 80 |
#define ENDFILE_SPEC "" |