diff mbox

[1/2] skeleton: ld.so.conf include ld.so.conf.d/*.conf

Message ID 1413186949-7006-1-git-send-email-jezz@sysmic.org
State Changes Requested
Headers show

Commit Message

Jérôme Pouiller Oct. 13, 2014, 7:55 a.m. UTC
Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
---
 system/skeleton/etc/ld.so.conf | 1 +
 1 file changed, 1 insertion(+)
 create mode 100644 system/skeleton/etc/ld.so.conf

Comments

Yann E. MORIN Oct. 14, 2014, 8:03 a.m. UTC | #1
Jérôme, All,

On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
> Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
> ---
>  system/skeleton/etc/ld.so.conf | 1 +
>  1 file changed, 1 insertion(+)
>  create mode 100644 system/skeleton/etc/ld.so.conf
> 
> diff --git a/system/skeleton/etc/ld.so.conf b/system/skeleton/etc/ld.so.conf
> new file mode 100644
> index 0000000..83327c0
> --- /dev/null
> +++ b/system/skeleton/etc/ld.so.conf
> @@ -0,0 +1 @@
> +include /etc/ld.so.conf.d/*.conf

Are you sure this works with uClibc? Looking at the code of ldconfig
from uClibc seems to imply it does not support including files.

Regards,
Yann E. MORIN.
Jérôme Pouiller Oct. 14, 2014, 8:24 a.m. UTC | #2
On Tuesday 14 October 2014 10:03:41 Yann E. MORIN wrote:
> Jérôme, All,
> 
> On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
> > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
> > ---
> > 
> >  system/skeleton/etc/ld.so.conf | 1 +
> >  1 file changed, 1 insertion(+)
> >  create mode 100644 system/skeleton/etc/ld.so.conf
> > 
> > diff --git a/system/skeleton/etc/ld.so.conf
> > b/system/skeleton/etc/ld.so.conf new file mode 100644
> > index 0000000..83327c0
> > --- /dev/null
> > +++ b/system/skeleton/etc/ld.so.conf
> > @@ -0,0 +1 @@
> > +include /etc/ld.so.conf.d/*.conf
> 
> Are you sure this works with uClibc? Looking at the code of ldconfig
> from uClibc seems to imply it does not support including files.
I admit I have not tested with uclibc. 

hmm... Suddenly, it is more complex to implement. I see two options:
  * Provide /etc/ld.so.conf during toolchain build depending of libc.
  * Add extra library paths directly in /etc/ld.so.conf instead of adding a 
file in /etc/ld.so.conf.d. However, modifying files during install step is 
error prone.

Any preference?
Samuel Martin Oct. 14, 2014, 8:33 a.m. UTC | #3
On Tue, Oct 14, 2014 at 10:24 AM, Jérôme Pouiller <jezz@sysmic.org> wrote:
> On Tuesday 14 October 2014 10:03:41 Yann E. MORIN wrote:
>> Jérôme, All,
>>
>> On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
>> > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
>> > ---
>> >
>> >  system/skeleton/etc/ld.so.conf | 1 +
>> >  1 file changed, 1 insertion(+)
>> >  create mode 100644 system/skeleton/etc/ld.so.conf
>> >
>> > diff --git a/system/skeleton/etc/ld.so.conf
>> > b/system/skeleton/etc/ld.so.conf new file mode 100644
>> > index 0000000..83327c0
>> > --- /dev/null
>> > +++ b/system/skeleton/etc/ld.so.conf
>> > @@ -0,0 +1 @@
>> > +include /etc/ld.so.conf.d/*.conf
>>
>> Are you sure this works with uClibc? Looking at the code of ldconfig
>> from uClibc seems to imply it does not support including files.
> I admit I have not tested with uclibc.
>
> hmm... Suddenly, it is more complex to implement. I see two options:
>   * Provide /etc/ld.so.conf during toolchain build depending of libc.
>   * Add extra library paths directly in /etc/ld.so.conf instead of adding a
> file in /etc/ld.so.conf.d. However, modifying files during install step is
> error prone.
>

or add a post-build hook for uclibc, which does:
cat <target>/etc/ld.conf.d/* >> <target>/etc/ld.conf

> Any preference?
>
>
> --
> Jérôme Pouiller, Sysmic
> Embedded Linux specialist
> http://www.sysmic.fr
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
Yann E. MORIN Oct. 14, 2014, 8:37 a.m. UTC | #4
Jérôme, Maxime, All,

On 2014-10-14 10:24 +0200, Jérôme Pouiller spake thusly:
> On Tuesday 14 October 2014 10:03:41 Yann E. MORIN wrote:
> > Jérôme, All,
> > 
> > On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
> > > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
> > > ---
> > > 
> > >  system/skeleton/etc/ld.so.conf | 1 +
> > >  1 file changed, 1 insertion(+)
> > >  create mode 100644 system/skeleton/etc/ld.so.conf
> > > 
> > > diff --git a/system/skeleton/etc/ld.so.conf
> > > b/system/skeleton/etc/ld.so.conf new file mode 100644
> > > index 0000000..83327c0
> > > --- /dev/null
> > > +++ b/system/skeleton/etc/ld.so.conf
> > > @@ -0,0 +1 @@
> > > +include /etc/ld.so.conf.d/*.conf
> > 
> > Are you sure this works with uClibc? Looking at the code of ldconfig
> > from uClibc seems to imply it does not support including files.
> I admit I have not tested with uclibc. 
> 
> hmm... Suddenly, it is more complex to implement. I see two options:
>   * Provide /etc/ld.so.conf during toolchain build depending of libc.
>   * Add extra library paths directly in /etc/ld.so.conf instead of adding a 
> file in /etc/ld.so.conf.d. However, modifying files during install step is 
> error prone.
> 
> Any preference?

Adding MAxime in the loop, since he's working on making the skeleton a
generic package.

Probably, at install time of the skeleton package, we could shoe-horn
this depending on whether this is glibc, uClibc or musl.

Maxime, thoughts?

Regards,
Yann E. MORIN.
Jérôme Pouiller Oct. 14, 2014, 8:40 a.m. UTC | #5
On Tuesday 14 October 2014 10:33:16 Samuel Martin wrote:
> On Tue, Oct 14, 2014 at 10:24 AM, Jérôme Pouiller <jezz@sysmic.org> wrote:
> > On Tuesday 14 October 2014 10:03:41 Yann E. MORIN wrote:
> >> Jérôme, All,
> >> 
> >> On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
> >> > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
> >> > ---
> >> > 
> >> >  system/skeleton/etc/ld.so.conf | 1 +
> >> >  1 file changed, 1 insertion(+)
> >> >  create mode 100644 system/skeleton/etc/ld.so.conf
> >> > 
> >> > diff --git a/system/skeleton/etc/ld.so.conf
> >> > b/system/skeleton/etc/ld.so.conf new file mode 100644
> >> > index 0000000..83327c0
> >> > --- /dev/null
> >> > +++ b/system/skeleton/etc/ld.so.conf
> >> > @@ -0,0 +1 @@
> >> > +include /etc/ld.so.conf.d/*.conf
> >> 
> >> Are you sure this works with uClibc? Looking at the code of ldconfig
> >> from uClibc seems to imply it does not support including files.
> > 
> > I admit I have not tested with uclibc.
> > 
> > hmm... Suddenly, it is more complex to implement. I see two options:
> >   * Provide /etc/ld.so.conf during toolchain build depending of libc.
> >   * Add extra library paths directly in /etc/ld.so.conf instead of adding
> >   a
> > 
> > file in /etc/ld.so.conf.d. However, modifying files during install step is
> > error prone.
> 
> or add a post-build hook for uclibc, which does:
> cat <target>/etc/ld.conf.d/* >> <target>/etc/ld.conf
This will not been executed if an external toolchain is used.
Samuel Martin Oct. 14, 2014, 8:44 a.m. UTC | #6
On Tue, Oct 14, 2014 at 10:40 AM, Jérôme Pouiller <jezz@sysmic.org> wrote:
> On Tuesday 14 October 2014 10:33:16 Samuel Martin wrote:
>> On Tue, Oct 14, 2014 at 10:24 AM, Jérôme Pouiller <jezz@sysmic.org> wrote:
>> > On Tuesday 14 October 2014 10:03:41 Yann E. MORIN wrote:
>> >> Jérôme, All,
>> >>
>> >> On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
>> >> > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
>> >> > ---
>> >> >
>> >> >  system/skeleton/etc/ld.so.conf | 1 +
>> >> >  1 file changed, 1 insertion(+)
>> >> >  create mode 100644 system/skeleton/etc/ld.so.conf
>> >> >
>> >> > diff --git a/system/skeleton/etc/ld.so.conf
>> >> > b/system/skeleton/etc/ld.so.conf new file mode 100644
>> >> > index 0000000..83327c0
>> >> > --- /dev/null
>> >> > +++ b/system/skeleton/etc/ld.so.conf
>> >> > @@ -0,0 +1 @@
>> >> > +include /etc/ld.so.conf.d/*.conf
>> >>
>> >> Are you sure this works with uClibc? Looking at the code of ldconfig
>> >> from uClibc seems to imply it does not support including files.
>> >
>> > I admit I have not tested with uclibc.
>> >
>> > hmm... Suddenly, it is more complex to implement. I see two options:
>> >   * Provide /etc/ld.so.conf during toolchain build depending of libc.
>> >   * Add extra library paths directly in /etc/ld.so.conf instead of adding
>> >   a
>> >
>> > file in /etc/ld.so.conf.d. However, modifying files during install step is
>> > error prone.
>>
>> or add a post-build hook for uclibc, which does:
>> cat <target>/etc/ld.conf.d/* >> <target>/etc/ld.conf
> This will not been executed if an external toolchain is used.

Why not?
In case of external toolchain, we have to select what libc is used in
the toolchain; so it should be ok.

>
>
> --
> Jérôme Pouiller, Sysmic
> Embedded Linux specialist
> http://www.sysmic.fr
Jérôme Pouiller Oct. 14, 2014, 8:52 a.m. UTC | #7
On Tuesday 14 October 2014 10:44:48 Samuel Martin wrote:
> On Tue, Oct 14, 2014 at 10:40 AM, Jérôme Pouiller <jezz@sysmic.org> wrote:
> > On Tuesday 14 October 2014 10:33:16 Samuel Martin wrote:
> >> On Tue, Oct 14, 2014 at 10:24 AM, Jérôme Pouiller <jezz@sysmic.org> 
wrote:
> >> > On Tuesday 14 October 2014 10:03:41 Yann E. MORIN wrote:
> >> >> Jérôme, All,
> >> >> 
> >> >> On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
> >> >> > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
> >> >> > ---
> >> >> > 
> >> >> >  system/skeleton/etc/ld.so.conf | 1 +
> >> >> >  1 file changed, 1 insertion(+)
> >> >> >  create mode 100644 system/skeleton/etc/ld.so.conf
> >> >> > 
> >> >> > diff --git a/system/skeleton/etc/ld.so.conf
> >> >> > b/system/skeleton/etc/ld.so.conf new file mode 100644
> >> >> > index 0000000..83327c0
> >> >> > --- /dev/null
> >> >> > +++ b/system/skeleton/etc/ld.so.conf
> >> >> > @@ -0,0 +1 @@
> >> >> > +include /etc/ld.so.conf.d/*.conf
> >> >> 
> >> >> Are you sure this works with uClibc? Looking at the code of ldconfig
> >> >> from uClibc seems to imply it does not support including files.
> >> > 
> >> > I admit I have not tested with uclibc.
> >> > 
> >> > hmm... Suddenly, it is more complex to implement. I see two options:
> >> >   * Provide /etc/ld.so.conf during toolchain build depending of libc.
> >> >   * Add extra library paths directly in /etc/ld.so.conf instead of
> >> >   adding
> >> >   a
> >> > 
> >> > file in /etc/ld.so.conf.d. However, modifying files during install step
> >> > is
> >> > error prone.
> >> 
> >> or add a post-build hook for uclibc, which does:
> >> cat <target>/etc/ld.conf.d/* >> <target>/etc/ld.conf
> > 
> > This will not been executed if an external toolchain is used.
> 
> Why not?
> In case of external toolchain, we have to select what libc is used in
> the toolchain; so it should be ok.
Ok. I understood a "package post build hook", but you mean a "target finalize 
hook".
Samuel Martin Oct. 14, 2014, 9 a.m. UTC | #8
On Tue, Oct 14, 2014 at 10:52 AM, Jérôme Pouiller <jezz@sysmic.org> wrote:
> On Tuesday 14 October 2014 10:44:48 Samuel Martin wrote:
>> On Tue, Oct 14, 2014 at 10:40 AM, Jérôme Pouiller <jezz@sysmic.org> wrote:
>> > On Tuesday 14 October 2014 10:33:16 Samuel Martin wrote:
>> >> On Tue, Oct 14, 2014 at 10:24 AM, Jérôme Pouiller <jezz@sysmic.org>
> wrote:
>> >> > On Tuesday 14 October 2014 10:03:41 Yann E. MORIN wrote:
>> >> >> Jérôme, All,
>> >> >>
>> >> >> On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
>> >> >> > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
>> >> >> > ---
>> >> >> >
>> >> >> >  system/skeleton/etc/ld.so.conf | 1 +
>> >> >> >  1 file changed, 1 insertion(+)
>> >> >> >  create mode 100644 system/skeleton/etc/ld.so.conf
>> >> >> >
>> >> >> > diff --git a/system/skeleton/etc/ld.so.conf
>> >> >> > b/system/skeleton/etc/ld.so.conf new file mode 100644
>> >> >> > index 0000000..83327c0
>> >> >> > --- /dev/null
>> >> >> > +++ b/system/skeleton/etc/ld.so.conf
>> >> >> > @@ -0,0 +1 @@
>> >> >> > +include /etc/ld.so.conf.d/*.conf
>> >> >>
>> >> >> Are you sure this works with uClibc? Looking at the code of ldconfig
>> >> >> from uClibc seems to imply it does not support including files.
>> >> >
>> >> > I admit I have not tested with uclibc.
>> >> >
>> >> > hmm... Suddenly, it is more complex to implement. I see two options:
>> >> >   * Provide /etc/ld.so.conf during toolchain build depending of libc.
>> >> >   * Add extra library paths directly in /etc/ld.so.conf instead of
>> >> >   adding
>> >> >   a
>> >> >
>> >> > file in /etc/ld.so.conf.d. However, modifying files during install step
>> >> > is
>> >> > error prone.
>> >>
>> >> or add a post-build hook for uclibc, which does:
>> >> cat <target>/etc/ld.conf.d/* >> <target>/etc/ld.conf
>> >
>> > This will not been executed if an external toolchain is used.
>>
>> Why not?
>> In case of external toolchain, we have to select what libc is used in
>> the toolchain; so it should be ok.
> Ok. I understood a "package post build hook", but you mean a "target finalize
> hook".

Yes exactly.
Sorry for the confusion.

>
>
> --
> Jérôme Pouiller, Sysmic
> Embedded Linux specialist
> http://www.sysmic.fr
Yann E. MORIN Oct. 24, 2014, 11:53 p.m. UTC | #9
Jérôme, All,

On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
> Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>

Given the feedback given in the thread, I've marked this patch "Changes
Requested" in patchwork.

Are you working on an updated patch?

Regards,
Yann E. MORIN.

> ---
>  system/skeleton/etc/ld.so.conf | 1 +
>  1 file changed, 1 insertion(+)
>  create mode 100644 system/skeleton/etc/ld.so.conf
> 
> diff --git a/system/skeleton/etc/ld.so.conf b/system/skeleton/etc/ld.so.conf
> new file mode 100644
> index 0000000..83327c0
> --- /dev/null
> +++ b/system/skeleton/etc/ld.so.conf
> @@ -0,0 +1 @@
> +include /etc/ld.so.conf.d/*.conf
> -- 
> 1.9.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
Jérôme Pouiller Oct. 25, 2014, 4:23 p.m. UTC | #10
On Friday 24 October 2014 16:53:23 Yann E. MORIN wrote:
> Jérôme, All,
> 
> On 2014-10-13 09:55 +0200, Jérôme Pouiller spake thusly:
> > Signed-off-by: Jérôme Pouiller <jezz@sysmic.org>
> 
> Given the feedback given in the thread, I've marked this patch "Changes
> Requested" in patchwork.
> 
> Are you working on an updated patch?
I will do next week I think.
diff mbox

Patch

diff --git a/system/skeleton/etc/ld.so.conf b/system/skeleton/etc/ld.so.conf
new file mode 100644
index 0000000..83327c0
--- /dev/null
+++ b/system/skeleton/etc/ld.so.conf
@@ -0,0 +1 @@ 
+include /etc/ld.so.conf.d/*.conf