All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] glibc: fixes for nscd and libnss-db
@ 2017-10-31  7:20 jackie.huang
  2017-10-31  7:20 ` [PATCH 1/2] glibc: re-package for libnss-db jackie.huang
  2017-10-31  7:20 ` [PATCH 2/2] glibc/nscd: do not cache for netgroup by default jackie.huang
  0 siblings, 2 replies; 7+ messages in thread
From: jackie.huang @ 2017-10-31  7:20 UTC (permalink / raw)
  To: openembedded-core

From: Jackie Huang <jackie.huang@windriver.com>

--
The following changes since commit 514a808f21c37b6ad704ce397bb2740ecc9a93bc:

  ref-manual: Updates to "Image Generation" section. (2017-10-30 15:55:08 +0000)

are available in the git repository at:

  git://git.pokylinux.org/poky-contrib.git jhuang0/d_nscd_171031_0
  http://git.pokylinux.org/cgit.cgi//log/?h=jhuang0/d_nscd_171031_0

Jackie Huang (2):
  glibc: re-package for libnss-db
  glibc/nscd: do not cache for netgroup by default

 meta/recipes-core/glibc/glibc-package.inc | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

-- 
2.11.0



^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH 1/2] glibc: re-package for libnss-db
  2017-10-31  7:20 [PATCH 0/2] glibc: fixes for nscd and libnss-db jackie.huang
@ 2017-10-31  7:20 ` jackie.huang
  2017-10-31 19:40   ` Khem Raj
  2017-10-31  7:20 ` [PATCH 2/2] glibc/nscd: do not cache for netgroup by default jackie.huang
  1 sibling, 1 reply; 7+ messages in thread
From: jackie.huang @ 2017-10-31  7:20 UTC (permalink / raw)
  To: openembedded-core

From: Jackie Huang <jackie.huang@windriver.com>

On other distros like ubuntu/centos, libnss-db usually provides:
- The libraries
- The Makefile to create database
  (in /var/db for centos, /var/lib/misc/ for ubuntu)
- The makedb command (it's in glibc-common for centos7)

What we had is:
- The libraries are in glibc-extra-nss
- The Makefile is removed
- The makedb command is in glibc-utils (lack of dependency)

So when glibc-extra-nss is installed but glibc-utils is not,
we see error like:
nscd[165]: 165 checking for monitored file `/var/db/group.db': No such file or directory
nscd[165]: 165 checking for monitored file `/var/db/passwd.db': No such file or directory

And there is not an easy way to create these databases.

To fix the issue:
- Re-package the libraries into libnss-db
- Don't remove the Makefile and add it in libnss-db
- Add RDEPENDS for libnss-db on glibc-utils and make

Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
---
 meta/recipes-core/glibc/glibc-package.inc | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-core/glibc/glibc-package.inc b/meta/recipes-core/glibc/glibc-package.inc
index df3db2cc45..1c3782dbb0 100644
--- a/meta/recipes-core/glibc/glibc-package.inc
+++ b/meta/recipes-core/glibc/glibc-package.inc
@@ -1,6 +1,6 @@
 INHIBIT_SYSROOT_STRIP = "1"
 
-PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-pic libcidn libmemusage libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
+PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-pic libcidn libmemusage libnss-db libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
 
 # The ld.so in this glibc supports the GNU_HASH
 RPROVIDES_${PN} = "eglibc rtld(GNU_HASH)"
@@ -23,6 +23,8 @@ FILES_ldd = "${bindir}/ldd"
 FILES_libsegfault = "${base_libdir}/libSegFault*"
 FILES_libcidn = "${base_libdir}/libcidn-*.so ${base_libdir}/libcidn.so.*"
 FILES_libmemusage = "${base_libdir}/libmemusage.so"
+FILES_libnss-db = "${base_libdir}/libnss_db.so.* ${base_libdir}/libnss_db-*.so ${localstatedir}/db/Makefile"
+RDEPENDS_libnss-db = "${PN}-utils make"
 FILES_glibc-extra-nss = "${base_libdir}/libnss_*-*.so ${base_libdir}/libnss_*.so.*"
 FILES_sln = "${base_sbindir}/sln"
 FILES_${PN}-pic = "${libdir}/*_pic.a ${libdir}/*_pic.map ${libdir}/libc_pic/*.o"
@@ -59,7 +61,6 @@ inherit libc-common multilib_header
 
 do_install_append () {
 	rm -f ${D}${sysconfdir}/localtime
-	rm -rf ${D}${localstatedir}
 
 	# remove empty glibc dir
 	if [ -d ${D}${libexecdir} ]; then
-- 
2.11.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 2/2] glibc/nscd: do not cache for netgroup by default
  2017-10-31  7:20 [PATCH 0/2] glibc: fixes for nscd and libnss-db jackie.huang
  2017-10-31  7:20 ` [PATCH 1/2] glibc: re-package for libnss-db jackie.huang
@ 2017-10-31  7:20 ` jackie.huang
  1 sibling, 0 replies; 7+ messages in thread
From: jackie.huang @ 2017-10-31  7:20 UTC (permalink / raw)
  To: openembedded-core

From: Jackie Huang <jackie.huang@windriver.com>

We don't have /etc/netgroup by default, so do not
cache for netgroup by default to avoid:
nscd[529]: 529 disabled inotify-based monitoring for file `/etc/netgroup': No such file or directory
nscd[529]: 529 stat failed for file `/etc/netgroup'; will try again later: No such file or directory

Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
---
 meta/recipes-core/glibc/glibc-package.inc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-core/glibc/glibc-package.inc b/meta/recipes-core/glibc/glibc-package.inc
index 1c3782dbb0..c4ca94c981 100644
--- a/meta/recipes-core/glibc/glibc-package.inc
+++ b/meta/recipes-core/glibc/glibc-package.inc
@@ -98,6 +98,7 @@ do_install_append () {
 	install -m 0755 ${S}/nscd/nscd.init ${D}${sysconfdir}/init.d/nscd
 	install -m 0755 ${S}/nscd/nscd.conf ${D}${sysconfdir}/nscd.conf
 	sed -i "s%daemon%start-stop-daemon --start --exec%g" ${D}${sysconfdir}/init.d/nscd
+	sed -i "s|\(enable-cache\t\+netgroup\t\+\)yes|\1no|" ${D}${sysconfdir}/nscd.conf
 
 	install -d ${D}${systemd_unitdir}/system
 	install -m 0644 ${S}/nscd/nscd.service ${D}${systemd_unitdir}/system/
-- 
2.11.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] glibc: re-package for libnss-db
  2017-10-31  7:20 ` [PATCH 1/2] glibc: re-package for libnss-db jackie.huang
@ 2017-10-31 19:40   ` Khem Raj
  2017-11-01  2:03     ` Huang, Jie (Jackie)
  0 siblings, 1 reply; 7+ messages in thread
From: Khem Raj @ 2017-10-31 19:40 UTC (permalink / raw)
  To: jhuang0; +Cc: Patches and discussions about the oe-core layer

On Tue, Oct 31, 2017 at 12:20 AM,  <jackie.huang@windriver.com> wrote:
> From: Jackie Huang <jackie.huang@windriver.com>
>
> On other distros like ubuntu/centos, libnss-db usually provides:
> - The libraries
> - The Makefile to create database
>   (in /var/db for centos, /var/lib/misc/ for ubuntu)
> - The makedb command (it's in glibc-common for centos7)
>
> What we had is:
> - The libraries are in glibc-extra-nss
> - The Makefile is removed
> - The makedb command is in glibc-utils (lack of dependency)
>
> So when glibc-extra-nss is installed but glibc-utils is not,
> we see error like:
> nscd[165]: 165 checking for monitored file `/var/db/group.db': No such file or directory
> nscd[165]: 165 checking for monitored file `/var/db/passwd.db': No such file or directory
>
> And there is not an easy way to create these databases.
>
> To fix the issue:
> - Re-package the libraries into libnss-db
> - Don't remove the Makefile and add it in libnss-db
> - Add RDEPENDS for libnss-db on glibc-utils and make
>

this looks ok although, changing glibc packaging is a bit thorny for
external toolchains and
other libraries. Would be better if this was added to commit saying
that they have yet another
package that they need to provide if replacing glibc from core.

> Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
> ---
>  meta/recipes-core/glibc/glibc-package.inc | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/meta/recipes-core/glibc/glibc-package.inc b/meta/recipes-core/glibc/glibc-package.inc
> index df3db2cc45..1c3782dbb0 100644
> --- a/meta/recipes-core/glibc/glibc-package.inc
> +++ b/meta/recipes-core/glibc/glibc-package.inc
> @@ -1,6 +1,6 @@
>  INHIBIT_SYSROOT_STRIP = "1"
>
> -PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-pic libcidn libmemusage libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
> +PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-pic libcidn libmemusage libnss-db libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
>
>  # The ld.so in this glibc supports the GNU_HASH
>  RPROVIDES_${PN} = "eglibc rtld(GNU_HASH)"
> @@ -23,6 +23,8 @@ FILES_ldd = "${bindir}/ldd"
>  FILES_libsegfault = "${base_libdir}/libSegFault*"
>  FILES_libcidn = "${base_libdir}/libcidn-*.so ${base_libdir}/libcidn.so.*"
>  FILES_libmemusage = "${base_libdir}/libmemusage.so"
> +FILES_libnss-db = "${base_libdir}/libnss_db.so.* ${base_libdir}/libnss_db-*.so ${localstatedir}/db/Makefile"
> +RDEPENDS_libnss-db = "${PN}-utils make"
>  FILES_glibc-extra-nss = "${base_libdir}/libnss_*-*.so ${base_libdir}/libnss_*.so.*"
>  FILES_sln = "${base_sbindir}/sln"
>  FILES_${PN}-pic = "${libdir}/*_pic.a ${libdir}/*_pic.map ${libdir}/libc_pic/*.o"
> @@ -59,7 +61,6 @@ inherit libc-common multilib_header
>
>  do_install_append () {
>         rm -f ${D}${sysconfdir}/localtime
> -       rm -rf ${D}${localstatedir}
>
>         # remove empty glibc dir
>         if [ -d ${D}${libexecdir} ]; then
> --
> 2.11.0
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] glibc: re-package for libnss-db
  2017-10-31 19:40   ` Khem Raj
@ 2017-11-01  2:03     ` Huang, Jie (Jackie)
  2017-11-01  8:34       ` Khem Raj
  0 siblings, 1 reply; 7+ messages in thread
From: Huang, Jie (Jackie) @ 2017-11-01  2:03 UTC (permalink / raw)
  To: Khem Raj; +Cc: Patches and discussions about the oe-core layer



> -----Original Message-----
> From: Khem Raj [mailto:raj.khem@gmail.com]
> Sent: Wednesday, November 01, 2017 03:40
> To: Huang, Jie (Jackie)
> Cc: Patches and discussions about the oe-core layer
> Subject: Re: [OE-core] [PATCH 1/2] glibc: re-package for libnss-db
> 
> On Tue, Oct 31, 2017 at 12:20 AM,  <jackie.huang@windriver.com> wrote:
> > From: Jackie Huang <jackie.huang@windriver.com>
> >
> > On other distros like ubuntu/centos, libnss-db usually provides:
> > - The libraries
> > - The Makefile to create database
> >   (in /var/db for centos, /var/lib/misc/ for ubuntu)
> > - The makedb command (it's in glibc-common for centos7)
> >
> > What we had is:
> > - The libraries are in glibc-extra-nss
> > - The Makefile is removed
> > - The makedb command is in glibc-utils (lack of dependency)
> >
> > So when glibc-extra-nss is installed but glibc-utils is not,
> > we see error like:
> > nscd[165]: 165 checking for monitored file `/var/db/group.db': No such file or
> directory
> > nscd[165]: 165 checking for monitored file `/var/db/passwd.db': No such file
> or directory
> >
> > And there is not an easy way to create these databases.
> >
> > To fix the issue:
> > - Re-package the libraries into libnss-db
> > - Don't remove the Makefile and add it in libnss-db
> > - Add RDEPENDS for libnss-db on glibc-utils and make
> >
> 
> this looks ok although, changing glibc packaging is a bit thorny for
> external toolchains and
> other libraries. Would be better if this was added to commit saying
> that they have yet another
> package that they need to provide if replacing glibc from core.

Sorry I'm not sure I understand correctly, did you mean I just need to add 
words in the commit message like the following?

"For external toolchain, an extra package 'libnss-db' need to be provided If replacing glibc from core."

Thanks,
Jackie 

> 
> > Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
> > ---
> >  meta/recipes-core/glibc/glibc-package.inc | 5 +++--
> >  1 file changed, 3 insertions(+), 2 deletions(-)
> >
> > diff --git a/meta/recipes-core/glibc/glibc-package.inc b/meta/recipes-
> core/glibc/glibc-package.inc
> > index df3db2cc45..1c3782dbb0 100644
> > --- a/meta/recipes-core/glibc/glibc-package.inc
> > +++ b/meta/recipes-core/glibc/glibc-package.inc
> > @@ -1,6 +1,6 @@
> >  INHIBIT_SYSROOT_STRIP = "1"
> >
> > -PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-
> pic libcidn libmemusage libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils
> glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
> > +PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-
> pic libcidn libmemusage libnss-db libsegfault ${PN}-pcprofile libsotruss ${PN}
> ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
> >
> >  # The ld.so in this glibc supports the GNU_HASH
> >  RPROVIDES_${PN} = "eglibc rtld(GNU_HASH)"
> > @@ -23,6 +23,8 @@ FILES_ldd = "${bindir}/ldd"
> >  FILES_libsegfault = "${base_libdir}/libSegFault*"
> >  FILES_libcidn = "${base_libdir}/libcidn-*.so ${base_libdir}/libcidn.so.*"
> >  FILES_libmemusage = "${base_libdir}/libmemusage.so"
> > +FILES_libnss-db = "${base_libdir}/libnss_db.so.* ${base_libdir}/libnss_db-*.so
> ${localstatedir}/db/Makefile"
> > +RDEPENDS_libnss-db = "${PN}-utils make"
> >  FILES_glibc-extra-nss = "${base_libdir}/libnss_*-*.so
> ${base_libdir}/libnss_*.so.*"
> >  FILES_sln = "${base_sbindir}/sln"
> >  FILES_${PN}-pic = "${libdir}/*_pic.a ${libdir}/*_pic.map ${libdir}/libc_pic/*.o"
> > @@ -59,7 +61,6 @@ inherit libc-common multilib_header
> >
> >  do_install_append () {
> >         rm -f ${D}${sysconfdir}/localtime
> > -       rm -rf ${D}${localstatedir}
> >
> >         # remove empty glibc dir
> >         if [ -d ${D}${libexecdir} ]; then
> > --
> > 2.11.0
> >
> > --
> > _______________________________________________
> > Openembedded-core mailing list
> > Openembedded-core@lists.openembedded.org
> > http://lists.openembedded.org/mailman/listinfo/openembedded-core

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] glibc: re-package for libnss-db
  2017-11-01  2:03     ` Huang, Jie (Jackie)
@ 2017-11-01  8:34       ` Khem Raj
  2017-11-02  6:43         ` Huang, Jie (Jackie)
  0 siblings, 1 reply; 7+ messages in thread
From: Khem Raj @ 2017-11-01  8:34 UTC (permalink / raw)
  To: Huang, Jie (Jackie); +Cc: Patches and discussions about the oe-core layer

On Tue, Oct 31, 2017 at 7:03 PM, Huang, Jie (Jackie)
<Jackie.Huang@windriver.com> wrote:
>
>
>> -----Original Message-----
>> From: Khem Raj [mailto:raj.khem@gmail.com]
>> Sent: Wednesday, November 01, 2017 03:40
>> To: Huang, Jie (Jackie)
>> Cc: Patches and discussions about the oe-core layer
>> Subject: Re: [OE-core] [PATCH 1/2] glibc: re-package for libnss-db
>>
>> On Tue, Oct 31, 2017 at 12:20 AM,  <jackie.huang@windriver.com> wrote:
>> > From: Jackie Huang <jackie.huang@windriver.com>
>> >
>> > On other distros like ubuntu/centos, libnss-db usually provides:
>> > - The libraries
>> > - The Makefile to create database
>> >   (in /var/db for centos, /var/lib/misc/ for ubuntu)
>> > - The makedb command (it's in glibc-common for centos7)
>> >
>> > What we had is:
>> > - The libraries are in glibc-extra-nss
>> > - The Makefile is removed
>> > - The makedb command is in glibc-utils (lack of dependency)
>> >
>> > So when glibc-extra-nss is installed but glibc-utils is not,
>> > we see error like:
>> > nscd[165]: 165 checking for monitored file `/var/db/group.db': No such file or
>> directory
>> > nscd[165]: 165 checking for monitored file `/var/db/passwd.db': No such file
>> or directory
>> >
>> > And there is not an easy way to create these databases.
>> >
>> > To fix the issue:
>> > - Re-package the libraries into libnss-db
>> > - Don't remove the Makefile and add it in libnss-db
>> > - Add RDEPENDS for libnss-db on glibc-utils and make
>> >
>>
>> this looks ok although, changing glibc packaging is a bit thorny for
>> external toolchains and
>> other libraries. Would be better if this was added to commit saying
>> that they have yet another
>> package that they need to provide if replacing glibc from core.
>
> Sorry I'm not sure I understand correctly, did you mean I just need to add
> words in the commit message like the following?
>
> "For external toolchain, an extra package 'libnss-db' need to be provided If replacing glibc from core."
>

yes, someway for folks to notice the change for external layer maintainers.

> Thanks,
> Jackie
>
>>
>> > Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
>> > ---
>> >  meta/recipes-core/glibc/glibc-package.inc | 5 +++--
>> >  1 file changed, 3 insertions(+), 2 deletions(-)
>> >
>> > diff --git a/meta/recipes-core/glibc/glibc-package.inc b/meta/recipes-
>> core/glibc/glibc-package.inc
>> > index df3db2cc45..1c3782dbb0 100644
>> > --- a/meta/recipes-core/glibc/glibc-package.inc
>> > +++ b/meta/recipes-core/glibc/glibc-package.inc
>> > @@ -1,6 +1,6 @@
>> >  INHIBIT_SYSROOT_STRIP = "1"
>> >
>> > -PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-
>> pic libcidn libmemusage libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-utils
>> glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
>> > +PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db ${PN}-
>> pic libcidn libmemusage libnss-db libsegfault ${PN}-pcprofile libsotruss ${PN}
>> ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
>> >
>> >  # The ld.so in this glibc supports the GNU_HASH
>> >  RPROVIDES_${PN} = "eglibc rtld(GNU_HASH)"
>> > @@ -23,6 +23,8 @@ FILES_ldd = "${bindir}/ldd"
>> >  FILES_libsegfault = "${base_libdir}/libSegFault*"
>> >  FILES_libcidn = "${base_libdir}/libcidn-*.so ${base_libdir}/libcidn.so.*"
>> >  FILES_libmemusage = "${base_libdir}/libmemusage.so"
>> > +FILES_libnss-db = "${base_libdir}/libnss_db.so.* ${base_libdir}/libnss_db-*.so
>> ${localstatedir}/db/Makefile"
>> > +RDEPENDS_libnss-db = "${PN}-utils make"
>> >  FILES_glibc-extra-nss = "${base_libdir}/libnss_*-*.so
>> ${base_libdir}/libnss_*.so.*"
>> >  FILES_sln = "${base_sbindir}/sln"
>> >  FILES_${PN}-pic = "${libdir}/*_pic.a ${libdir}/*_pic.map ${libdir}/libc_pic/*.o"
>> > @@ -59,7 +61,6 @@ inherit libc-common multilib_header
>> >
>> >  do_install_append () {
>> >         rm -f ${D}${sysconfdir}/localtime
>> > -       rm -rf ${D}${localstatedir}
>> >
>> >         # remove empty glibc dir
>> >         if [ -d ${D}${libexecdir} ]; then
>> > --
>> > 2.11.0
>> >
>> > --
>> > _______________________________________________
>> > Openembedded-core mailing list
>> > Openembedded-core@lists.openembedded.org
>> > http://lists.openembedded.org/mailman/listinfo/openembedded-core


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH 1/2] glibc: re-package for libnss-db
  2017-11-01  8:34       ` Khem Raj
@ 2017-11-02  6:43         ` Huang, Jie (Jackie)
  0 siblings, 0 replies; 7+ messages in thread
From: Huang, Jie (Jackie) @ 2017-11-02  6:43 UTC (permalink / raw)
  To: Khem Raj; +Cc: Patches and discussions about the oe-core layer



> -----Original Message-----
> From: Khem Raj [mailto:raj.khem@gmail.com]
> Sent: Wednesday, November 01, 2017 16:35
> To: Huang, Jie (Jackie)
> Cc: Patches and discussions about the oe-core layer
> Subject: Re: [OE-core] [PATCH 1/2] glibc: re-package for libnss-db
> 
> On Tue, Oct 31, 2017 at 7:03 PM, Huang, Jie (Jackie)
> <Jackie.Huang@windriver.com> wrote:
> >
> >
> >> -----Original Message-----
> >> From: Khem Raj [mailto:raj.khem@gmail.com]
> >> Sent: Wednesday, November 01, 2017 03:40
> >> To: Huang, Jie (Jackie)
> >> Cc: Patches and discussions about the oe-core layer
> >> Subject: Re: [OE-core] [PATCH 1/2] glibc: re-package for libnss-db
> >>
> >> On Tue, Oct 31, 2017 at 12:20 AM,  <jackie.huang@windriver.com> wrote:
> >> > From: Jackie Huang <jackie.huang@windriver.com>
> >> >
> >> > On other distros like ubuntu/centos, libnss-db usually provides:
> >> > - The libraries
> >> > - The Makefile to create database
> >> >   (in /var/db for centos, /var/lib/misc/ for ubuntu)
> >> > - The makedb command (it's in glibc-common for centos7)
> >> >
> >> > What we had is:
> >> > - The libraries are in glibc-extra-nss
> >> > - The Makefile is removed
> >> > - The makedb command is in glibc-utils (lack of dependency)
> >> >
> >> > So when glibc-extra-nss is installed but glibc-utils is not,
> >> > we see error like:
> >> > nscd[165]: 165 checking for monitored file `/var/db/group.db': No such file
> or
> >> directory
> >> > nscd[165]: 165 checking for monitored file `/var/db/passwd.db': No such
> file
> >> or directory
> >> >
> >> > And there is not an easy way to create these databases.
> >> >
> >> > To fix the issue:
> >> > - Re-package the libraries into libnss-db
> >> > - Don't remove the Makefile and add it in libnss-db
> >> > - Add RDEPENDS for libnss-db on glibc-utils and make
> >> >
> >>
> >> this looks ok although, changing glibc packaging is a bit thorny for
> >> external toolchains and
> >> other libraries. Would be better if this was added to commit saying
> >> that they have yet another
> >> package that they need to provide if replacing glibc from core.
> >
> > Sorry I'm not sure I understand correctly, did you mean I just need to add
> > words in the commit message like the following?
> >
> > "For external toolchain, an extra package 'libnss-db' need to be provided If
> replacing glibc from core."
> >
> 
> yes, someway for folks to notice the change for external layer maintainers.

Got it, I added the note and sent v2 for this.

Thanks,
Jackie

> 
> > Thanks,
> > Jackie
> >
> >>
> >> > Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
> >> > ---
> >> >  meta/recipes-core/glibc/glibc-package.inc | 5 +++--
> >> >  1 file changed, 3 insertions(+), 2 deletions(-)
> >> >
> >> > diff --git a/meta/recipes-core/glibc/glibc-package.inc b/meta/recipes-
> >> core/glibc/glibc-package.inc
> >> > index df3db2cc45..1c3782dbb0 100644
> >> > --- a/meta/recipes-core/glibc/glibc-package.inc
> >> > +++ b/meta/recipes-core/glibc/glibc-package.inc
> >> > @@ -1,6 +1,6 @@
> >> >  INHIBIT_SYSROOT_STRIP = "1"
> >> >
> >> > -PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db
> ${PN}-
> >> pic libcidn libmemusage libsegfault ${PN}-pcprofile libsotruss ${PN} ${PN}-
> utils
> >> glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
> >> > +PACKAGES = "${PN}-dbg catchsegv sln nscd ldd tzcode glibc-thread-db
> ${PN}-
> >> pic libcidn libmemusage libnss-db libsegfault ${PN}-pcprofile libsotruss ${PN}
> >> ${PN}-utils glibc-extra-nss ${PN}-dev ${PN}-staticdev ${PN}-doc"
> >> >
> >> >  # The ld.so in this glibc supports the GNU_HASH
> >> >  RPROVIDES_${PN} = "eglibc rtld(GNU_HASH)"
> >> > @@ -23,6 +23,8 @@ FILES_ldd = "${bindir}/ldd"
> >> >  FILES_libsegfault = "${base_libdir}/libSegFault*"
> >> >  FILES_libcidn = "${base_libdir}/libcidn-*.so ${base_libdir}/libcidn.so.*"
> >> >  FILES_libmemusage = "${base_libdir}/libmemusage.so"
> >> > +FILES_libnss-db = "${base_libdir}/libnss_db.so.* ${base_libdir}/libnss_db-
> *.so
> >> ${localstatedir}/db/Makefile"
> >> > +RDEPENDS_libnss-db = "${PN}-utils make"
> >> >  FILES_glibc-extra-nss = "${base_libdir}/libnss_*-*.so
> >> ${base_libdir}/libnss_*.so.*"
> >> >  FILES_sln = "${base_sbindir}/sln"
> >> >  FILES_${PN}-pic = "${libdir}/*_pic.a ${libdir}/*_pic.map
> ${libdir}/libc_pic/*.o"
> >> > @@ -59,7 +61,6 @@ inherit libc-common multilib_header
> >> >
> >> >  do_install_append () {
> >> >         rm -f ${D}${sysconfdir}/localtime
> >> > -       rm -rf ${D}${localstatedir}
> >> >
> >> >         # remove empty glibc dir
> >> >         if [ -d ${D}${libexecdir} ]; then
> >> > --
> >> > 2.11.0
> >> >
> >> > --
> >> > _______________________________________________
> >> > Openembedded-core mailing list
> >> > Openembedded-core@lists.openembedded.org
> >> > http://lists.openembedded.org/mailman/listinfo/openembedded-core

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2017-11-02  6:43 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-31  7:20 [PATCH 0/2] glibc: fixes for nscd and libnss-db jackie.huang
2017-10-31  7:20 ` [PATCH 1/2] glibc: re-package for libnss-db jackie.huang
2017-10-31 19:40   ` Khem Raj
2017-11-01  2:03     ` Huang, Jie (Jackie)
2017-11-01  8:34       ` Khem Raj
2017-11-02  6:43         ` Huang, Jie (Jackie)
2017-10-31  7:20 ` [PATCH 2/2] glibc/nscd: do not cache for netgroup by default jackie.huang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.