Given my file test.c
:
#include <stdarg.h>
int a(int b, ...) { __builtin_ms_va_list list; __builtin_ms_va_start(list,b); }
I try:
$ clang -m64 -c -g -O2 -mabi=ms test.c -Wall -Wextra
which returns with
clang: error: unsupported option '-mabi=' for target 'x86_64-redhat-linux-gnu'
But if I try with gcc:
gcc -m64 -c -g -O2 -mabi=ms test.c -Wall -Wextra
It compiles without any warnings or errors. What gives?
Extra info:
$ gcc --version
gcc (GCC) 11.4.1 20231218 (Red Hat 11.4.1-3)
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ clang --version
clang version 17.0.6 (CentOS 17.0.6-5.el9)
Target: x86_64-redhat-linux-gnu
Thread model: posix
InstalledDir: /usr/bin