Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 8 Mar 2023 08:24:42 -0500
From: Rich Felker <>
To: "Max R. Dechantsreiter" <>
Subject: Re: unknown type name '__gnuc_va_list'

On Wed, Mar 08, 2023 at 01:09:25PM +0000, Max R. Dechantsreiter wrote:
> ....I got the "validation test" working by setting C_INCLUDE_PATH:
> cat > hello.c <<EOF
> #include <stdio.h>
> int main()
> {
>   printf("Hello, world!\n");
>   return 0;
> }
> echo $CPATH
> # /home/maxd/GNU/opt/gnu/gcc-12.1.0/include:/usr/include
> $INSTALL/bin/musl-gcc hello.c
> ../a.out
> # Hello, world!

I suspect you already had C_INCLUDE_PATH in your environment and gcc
was finding /usr/include via that despite the musl-gcc wrapper
suppressing the default. You should unset C_INCLUDE_PATH, or if you
really need to set it, ensure that any non-musl include paths (e.g.
/usr/include) do not appear in C_INCLUDE_PATH or any -I, etc.

It's not clear to me whether the musl-gcc wrapper should try to do
anything to suppress C_INCLUDE_PATH, since you might want it for
adding intended paths when invoking the wrapper. Maybe it could be
enhanced to remove known-bad pathss but that seems fragile.

> For what it's worth:
> [/home/maxd] 56> cat /proc/version
> Linux version 4.19.0 ( (gcc version 4.8.5 20150623 (Red Hat 4.8.5-44) (GCC) ) #1 SMP Thu Dec 15 20:31:06 MSK 2022
> [/home/maxd] 57>
> However, my application built with this musl-gcc still ends with
> Killed

This is probably just a bug in the application. You could run it under
gdb to see. Are you using static or dynamic linking? I thought you
wanted static but I don't see -static in your command line above.


Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.