Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#1080 Cannot debug files that contain spaces in the path name

closed-fixed
Borut Ražem
assembler (26)
5
2007-01-14
2006-03-10
No

Hello,

I have been a long-time user of your compiler, and I
recommend it to everyone, including our customers. I
seem to have found a small issue. It seems that
projects that contain files with spaces in the path
cannot be compiled using the --debug option.

1:
Attached is a zip file containing "Example 1.c" and
"Example2.c". They contain identical code.

2:
Both files were compiled as follows:
sdcc --debug "Example 1.c"
sdcc --debug "Example2.c"

3:
Tested on 2 versions:

SDCC :
mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/ds400/hc08
2.5.0 #1020 (May 8 2005) (MINGW32)

SDCC :
mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/ds400/hc08
2.5.4 #1223 (Mar 9 2006) (MINGW32)

4:
"Example2.c" compiles correctly
"Example 1.c" produces this error:

?ASxxxx-Error-<o> in line 112 of Example 1.asm
<o> .org in REL area or directive /
mnemonic error
?ASxxxx-Error-<o> in line 126 of Example 1.asm
<o> .org in REL area or directive /
mnemonic error
?ASxxxx-Error-<o> in line 131 of Example 1.asm
<o> .org in REL area or directive /
mnemonic error
?ASxxxx-Error-<o> in line 149 of Example 1.asm
<o> .org in REL area or directive /
mnemonic error
?ASxxxx-Error-<o> in line 162 of Example 1.asm
<o> .org in REL area or directive /
mnemonic error
?ASxxxx-Error-<o> in line 173 of Example 1.asm
<o> .org in REL area or directive /
mnemonic error
removing Example 1.rel

Checking "Example 1.asm", these line contain symbols
such as:
C$Example 1.c$13$0$0 ==.

In "Example2.asm", these lines have lines like:
C$Example2.c$13$0$0 ==.

It seems that the filename is inserted in the symbol
without checking for illegal characters.

Thank you for your hard work on a great compiler!

Discussion

  • Archive of the 2 examples and generated files

     
  • Borut Ražem
    Borut Ražem
    2007-01-14

    • assigned_to: nobody --> borutr
     
  • Borut Ražem
    Borut Ražem
    2007-01-14

    Logged In: YES
    user_id=568035
    Originator: NO

    This problem was fixed in SDCC sometime in the past: SDCC replaces spaces with underscores in sdcc --version
    SDCC : mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/ds400/hc08 2.6.3 #4
    543 (Dec 31 2006) (MINGW32)

    Now the problem is in asx8051 assembler: it generates "A$Example 1$103" lines with spaces in .sym file if the .asm file name contains spaces.

    Borut

     
  • Borut Ražem
    Borut Ražem
    2007-01-14

    Logged In: YES
    user_id=568035
    Originator: NO

    Fixed in svn revision #4571
    by converting spaces in asm file name to underscores.

    Borut

     
  • Borut Ražem
    Borut Ražem
    2007-01-14

    • labels: --> assembler
    • status: open --> closed-fixed