libffi / libffi

A portable foreign-function interface library.
http://sourceware.org/libffi
Other
3.17k stars 696 forks source link

ISO C99 doesn't support unnamed structs/unions #795

Open auouymous opened 1 year ago

auouymous commented 1 year ago

System Details

gcc (Gentoo 12.3.1_p20230526 p2) 12.3.1 20230526 libffi 3.4.4

Problems Description

Using libffi with -std=c99 throws an error.

/usr/lib/libffi/include/ffi.h:343:4: error: ISO C99 doesn't support unnamed structs/unions [-Wpedantic]
  343 |   };
      |    ^

The README mentions a C99 compiler is required to build, however, a GNU99 or C11 compiler is required to use the library.

auouymous commented 1 year ago

It would also require GNU99 or C11 to build if that header file is used in the build process.