Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 6 Jul 2016 13:44:03 -0400
From: Rich Felker <dalias@...c.org>
To: musl@...ts.openwall.com
Subject: Re: [PATCH 1/1] Use compiler includes for musl-clang, like musl-gcc

On Wed, Jul 06, 2016 at 06:22:05PM +0100, Aidan Hobson Sayers wrote:
> #include <unwind.h>
> int main() {}
> 
> The above currently compiles with musl-gcc but not with musl-clang. This
> patch fixes the latter.
> 
> ---
>  tools/musl-clang.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/musl-clang.in b/tools/musl-clang.in
> index 623de6f..0018932 100644
> --- a/tools/musl-clang.in
> +++ b/tools/musl-clang.in
> @@ -24,7 +24,7 @@ exec $cc \
>      -B"$thisdir" \
>      -fuse-ld=musl-clang \
>      -static-libgcc \
> -    -nostdinc \
> +    -nostdlibinc \
>      --sysroot "$libc" \
>      -isystem "$libc_inc" \
>      -L-user-start \
> -- 

What happens when you #include <stddef.h> after making this change? Do
you get the compiler-provided one or musl's? You should be able to
tell by running musl-clang -E foo.c

Rich

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.