#116 _ansi.h defines symbols not actually provided

open
nobody
devkitPPC (14)
5
2012-10-09
2010-09-24
Anonymous
No

I have modified directory.c from examples/wii/filesystem to include unistd.h and use rmdir("stuff"). The compilation worked fine, but when linking, I get:
[code]
powerpc-eabi-gcc directory.o -g -DGEKKO -mrvl -mcpu=750 -meabi -mhard-float -Wl,-Map,directory.elf.map -L/c/dev/devkitPPC/libogc/lib/wii -lwiiuse -lbte -lfat -logc -lm -o /c/dev/devkitPPC/examples/wii/filesystem/directory/directory.elf
directory.o: In function main': c:/dev/devkitPPC/examples/wii/filesystem/directory/source/directory.c:85: undefined reference tormdir'
collect2: ld returned 1 exit status
make[2]: [/c/dev/devkitPPC/examples/wii/filesystem/directory/directory.elf]
Error 1
make[1]:
[build] Error 2
make[1]: Leaving directory `/c/dev/devkitPPC/examples/wii/filesystem/directory'
make: *** [all] Error 1
[/code]
Same happens with dup, and maybe other files.

Discussion


  • Anonymous
    2010-09-24

    Modified directory.c to test the problem

     
    Attachments

  • Anonymous
    2010-09-24

    Note: rmdir can be replaced by remove, and dup by fnctl(..., F_DUPFD), but this is still cumbersome.

    Also, I suspect the same to happen with iconv_{close,open} but that's probably another bug report.