bebbo / libnix

libnix (v4): a C link library for AmigaOS/m68k
15 stars 9 forks source link

Executable compiled with -mcrt=nix13 crashes on a1000/a500, runs on a500+/a1200 #7

Closed alexalkis closed 5 years ago

alexalkis commented 5 years ago

hexdump.zip

Crashes on OS<2.0 I've updated all the toolchain on 9/4/2019 :)

bebbo commented 5 years ago

please test

alexalkis commented 5 years ago

Yes, fixed. Thanks!

dwhinham commented 5 years ago

If using C99 mode (-std=c99) in combination with -mcrt=nix13 or -noixemul then compilation fails with the following error:

C:\amiga-gcc>m68k-amigaos-gcc -o hello -std=c99 -mcrt=nix13 hello.c
In file included from hello.c:1:0:
C:/amiga-gcc/m68k-amigaos/libnix/include/stdio.h:234:83: error: unknown type name 'fd_set'
  int __stdargs (*lx_select)(struct _StdFileDes *sfd, int select_cmd, int io_mode, fd_set *, u_long *);
                                                                                   ^~~~~~
C:/amiga-gcc/m68k-amigaos/libnix/include/stdio.h:234:93: error: unknown type name 'u_long'
  int __stdargs (*lx_select)(struct _StdFileDes *sfd, int select_cmd, int io_mode, fd_set *, u_long *);
                                                                                             ^~~~~~

Any ideas? 😃

alexalkis commented 5 years ago

Reproducible here as well. But maybe you should open a new issue :)

dwhinham commented 5 years ago

Thanks - sorry, I thought it was related to this issue. Opening a new one :)

alexalkis commented 5 years ago

Well a crash is a bit different than not linking. Your issue might be more related to this #8 that I just posted. Looks like that some staff is not pulled in the nix13 libs.

alexalkis commented 5 years ago

Hmm, scratch that, your issue is with header files only.