summaryrefslogtreecommitdiff
path: root/src/SDCCasm.c
diff options
context:
space:
mode:
authorXavi Del Campo <xavi.dcr@tutanota.com>2019-11-06 04:10:53 +0100
committerXavi Del Campo <xavi.dcr@tutanota.com>2019-11-06 04:34:26 +0100
commitcf1d3aec552ebaea437935e74e5eabda4bd989e7 (patch)
treeebff2398497ea6ff20a1d6e57e63a12531d53ea2 /src/SDCCasm.c
parent0290d8bd12f3cd188c200367ade7d569a92f1d2d (diff)
downloadsdcc-gas-cf1d3aec552ebaea437935e74e5eabda4bd989e7.tar.gz
Fixed github sdcc-gas issues #1, #2 and #4
Issue #1 was caused because code_name and data_name had been incorrectly defined as const-qualified pointers, but this must be an exception for the z80 backend, as stated by the comments. Issue #2 has been solved by removing the --gas switch from SDCCmain.c, renaming it to "--asm=" (as requested by PKK) and moved to STM8's main.c, so the option is limited to those targets supporting it. Issue #4 was because of SDCCglue.c, that generated local labels using "!labeldef" instead of "!slabeldef", causing those __str_%d labels to be printed as "__str_%d::" (the double colons stand for globa label according to asxxx documentation) instead of "__str_%d":". I ran the regression tests and most of them passed, but "wchar" returned another "Multiple definition of..." error that I cannot explain so far. It is better than nothing, though.
Diffstat (limited to 'src/SDCCasm.c')
-rw-r--r--src/SDCCasm.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/SDCCasm.c b/src/SDCCasm.c
index e6db1c8..2d00250 100644
--- a/src/SDCCasm.c
+++ b/src/SDCCasm.c
@@ -413,7 +413,7 @@ static const ASM_MAPPING _gas_mapping[] = {
{"areadata", ".section %s"},
{"areahome", ".section %s"},
{"ascii", ".ascii \"%s\""},
- {"comm", ".comm %s, %d, %d"},
+ {"comm", ".comm %s, %d"},
{"local", ".local %s"},
{"db", ".byte"},
{"dbs", ".byte %s"},
@@ -476,8 +476,8 @@ static const ASM_MAPPING _asxxxx_mapping[] = {
{"immedword", "#0x%04x"},
{"immedbyte", "#0x%02x"},
{"hashedstr", "#%s"},
- {"lsbimmeds", "#<(%s)"},
- {"msbimmeds", "#>(%s)"},
+ {"lsbimmeds", "#<%s"},
+ {"msbimmeds", "#>%s"},
{"module", ".module %s"},
{"global", ".globl %s"},
{"fileprelude", ""},
@@ -529,8 +529,8 @@ static const ASM_MAPPING _asxxxx_smallpdk_mapping[] = {
{"immedword", "#0x%04x"},
{"immedbyte", "#0x%02x"},
{"hashedstr", "#%s"},
- {"lsbimmeds", "#<(%s)"},
- {"msbimmeds", "#>(%s)"},
+ {"lsbimmeds", "#<%s"},
+ {"msbimmeds", "#>%s"},
{"module", ".module %s"},
{"global", ".globl %s"},
{"fileprelude", ""},