* musl + libc++
@ 2016-03-21 23:39 Hayden Livingston
2016-03-22 3:43 ` Lei Zhang
2016-03-22 11:10 ` Christian Neukirchen
0 siblings, 2 replies; 6+ messages in thread
From: Hayden Livingston @ 2016-03-21 23:39 UTC (permalink / raw)
To: musl
Have folks gotten around using musl + libc++ (from the llvm project)?
I'm trying to get a setup where all my dependencies can be moved to
musl and libc++ to build static executables.
I've heard of all sorts of weird interactions when libc++ and
libstdc++ are in the same process. Or is that unfounded?
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: musl + libc++
2016-03-21 23:39 musl + libc++ Hayden Livingston
@ 2016-03-22 3:43 ` Lei Zhang
2016-03-22 11:48 ` Luca Barbato
2016-03-22 11:10 ` Christian Neukirchen
1 sibling, 1 reply; 6+ messages in thread
From: Lei Zhang @ 2016-03-22 3:43 UTC (permalink / raw)
To: musl
[-- Attachment #1: Type: text/plain, Size: 438 bytes --]
2016-03-22 7:39 GMT+08:00 Hayden Livingston <halivingston@gmail.com>:
> Have folks gotten around using musl + libc++ (from the llvm project)?
>
> I'm trying to get a setup where all my dependencies can be moved to
> musl and libc++ to build static executables.
>
I've tried to do about the same thing before and failed because libc++
depends on some functions not implemented in musl yet, like strtoll_l()
and __printf_chk() IIRC.
Lei
[-- Attachment #2: Type: text/html, Size: 857 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: musl + libc++
2016-03-21 23:39 musl + libc++ Hayden Livingston
2016-03-22 3:43 ` Lei Zhang
@ 2016-03-22 11:10 ` Christian Neukirchen
1 sibling, 0 replies; 6+ messages in thread
From: Christian Neukirchen @ 2016-03-22 11:10 UTC (permalink / raw)
To: Hayden Livingston; +Cc: musl
Hayden Livingston <halivingston@gmail.com> writes:
> Have folks gotten around using musl + libc++ (from the llvm project)?
>
> I'm trying to get a setup where all my dependencies can be moved to
> musl and libc++ to build static executables.
>
> I've heard of all sorts of weird interactions when libc++ and
> libstdc++ are in the same process. Or is that unfounded?
I managed to build a pure LLVM-clang-libc++-musl branch of Void Linux,
without too heavy patching required.
The base-system is completely free of gcc or libgcc.
https://github.com/chneukirchen/xbps-packages/tree/llvm-musl
--
Christian Neukirchen <chneukirchen@gmail.com> http://chneukirchen.org
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: musl + libc++
2016-03-22 3:43 ` Lei Zhang
@ 2016-03-22 11:48 ` Luca Barbato
2016-03-22 12:05 ` Lei Zhang
0 siblings, 1 reply; 6+ messages in thread
From: Luca Barbato @ 2016-03-22 11:48 UTC (permalink / raw)
To: musl
On 22/03/16 04:43, Lei Zhang wrote:
> 2016-03-22 7:39 GMT+08:00 Hayden Livingston <halivingston@gmail.com>:
>
>> Have folks gotten around using musl + libc++ (from the llvm project)?
>>
>> I'm trying to get a setup where all my dependencies can be moved to
>> musl and libc++ to build static executables.
>>
>
> I've tried to do about the same thing before and failed because libc++
> depends on some functions not implemented in musl yet, like strtoll_l()
> and __printf_chk() IIRC.
Nothing should directly use __printf_chk() how did you get that symbol
there?.
lu
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: musl + libc++
2016-03-22 11:48 ` Luca Barbato
@ 2016-03-22 12:05 ` Lei Zhang
2016-03-22 12:28 ` Szabolcs Nagy
0 siblings, 1 reply; 6+ messages in thread
From: Lei Zhang @ 2016-03-22 12:05 UTC (permalink / raw)
To: musl
On Mar 22, 2016, at 7:48 PM, Luca Barbato <lu_zero@gentoo.org> wrote:
>
> On 22/03/16 04:43, Lei Zhang wrote:
>> 2016-03-22 7:39 GMT+08:00 Hayden Livingston <halivingston@gmail.com>:
>>
>>> Have folks gotten around using musl + libc++ (from the llvm project)?
>>>
>>> I'm trying to get a setup where all my dependencies can be moved to
>>> musl and libc++ to build static executables.
>>>
>>
>> I've tried to do about the same thing before and failed because libc++
>> depends on some functions not implemented in musl yet, like strtoll_l()
>> and __printf_chk() IIRC.
>
> Nothing should directly use __printf_chk() how did you get that symbol
> there?.
Well, I manually linked a toy C++ program with musl and libc++, and when I ran the program the dynamic linker complained about not finding a bunch of symbols, including strtoll_l, __printf_chk, etc. Perhaps I mistakenly messed musl with glibc somehow...
Lei
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: musl + libc++
2016-03-22 12:05 ` Lei Zhang
@ 2016-03-22 12:28 ` Szabolcs Nagy
0 siblings, 0 replies; 6+ messages in thread
From: Szabolcs Nagy @ 2016-03-22 12:28 UTC (permalink / raw)
To: musl
* Lei Zhang <zhanglei.april@gmail.com> [2016-03-22 20:05:29 +0800]:
> On Mar 22, 2016, at 7:48 PM, Luca Barbato <lu_zero@gentoo.org> wrote:
> >
> > On 22/03/16 04:43, Lei Zhang wrote:
> >> 2016-03-22 7:39 GMT+08:00 Hayden Livingston <halivingston@gmail.com>:
> >>
> >>> Have folks gotten around using musl + libc++ (from the llvm project)?
> >>>
> >>> I'm trying to get a setup where all my dependencies can be moved to
> >>> musl and libc++ to build static executables.
> >>>
> >>
> >> I've tried to do about the same thing before and failed because libc++
> >> depends on some functions not implemented in musl yet, like strtoll_l()
> >> and __printf_chk() IIRC.
> >
> > Nothing should directly use __printf_chk() how did you get that symbol
> > there?.
>
> Well, I manually linked a toy C++ program with musl and libc++, and when I ran the program the dynamic linker complained about not finding a bunch of symbols, including strtoll_l, __printf_chk, etc. Perhaps I mistakenly messed musl with glibc somehow...
>
you probably used a libc++ built against glibc.
that should work on x86_64 if you provide the missing
symbols (e.g. LD_PRELOAD a dso with a dummy strtoll_l
and __printf_chk).
but it is better to build the entire toolchain for
musl instead of doing musl-gcc like wrapping for
c++ even if you can get the wrapper to work.
e.g. a libstdc++ built against glibc works for simple
things but can be broken for multi-threaded code.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2016-03-22 12:28 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-21 23:39 musl + libc++ Hayden Livingston
2016-03-22 3:43 ` Lei Zhang
2016-03-22 11:48 ` Luca Barbato
2016-03-22 12:05 ` Lei Zhang
2016-03-22 12:28 ` Szabolcs Nagy
2016-03-22 11:10 ` Christian Neukirchen
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).