If you have osx arm64 and gcc (not clang) installed...

Brian Callahan bcallah at openbsd.org
Thu Apr 9 04:07:22 UTC 2026


On Tuesday, 7 April 2026 at 22:56:37 UTC, Walter Bright wrote:
> Can you please compile this program:
> ```C
> #include <stdio.h>
>
> extern int foo(int *pi);
>
> int main() { int i = 7; return foo(&i); }
> ```
> with:
>
> gcc -c -femit-dwarf-unwind=always test.c
>
>
> and pls send me the resulting .o file. The reason I ask is 
> because it turns out that gcc on the Mac is actually clang, and 
> clang won't emit the dwarf eh_frame stuff. I need an example to 
> make sure I'm doing it right.

GCC 15.2.0 of macOS/aarch64 doesn't have that flag:
gcc: error: unrecognized command-line option 
‘-femit-dwarf-unwind=always’

I'll have my MacBook Neo on me this weekend, and I'll bring a USB 
key with a full binary package of GCC 15.2.0 (gcc, g++, gdc, 
whatever other frontends you want) for macOS/aarch64 for you.

~Brian


More information about the Digitalmars-d mailing list