All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2] pciutils: Move headers from pciutils-dev to libpci-dev
@ 2018-12-02  3:14 Robert Joslyn
  2018-12-02 10:43 ` Richard Purdie
  0 siblings, 1 reply; 3+ messages in thread
From: Robert Joslyn @ 2018-12-02  3:14 UTC (permalink / raw)
  To: openembedded-core

The pciutils recipe places libpci in a separate package, but the default
package split puts the headers for the library in pciutils-dev. When
building an SDK for an image that uses libpci, but not pciutils, the
headers for libpci are not included.

Move the headers, unversioned so symlink, and pkgconfig files from
pciutils-dev to libpci-dev so the SDK gets those files for images using
libpci.

Signed-off-by: Robert Joslyn <robert.joslyn@redrectangle.org>
---
 meta/recipes-bsp/pciutils/pciutils_3.6.2.bb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb b/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
index 413421cd8a..de1e54e5a5 100644
--- a/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
+++ b/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
@@ -52,9 +52,11 @@ do_install () {
 	oe_multilib_header pci/config.h
 }
 
-PACKAGES =+ "${PN}-ids libpci"
+PACKAGES =+ "${PN}-ids libpci libpci-dev"
 FILES_${PN}-ids = "${datadir}/pci.ids*"
 FILES_libpci = "${libdir}/libpci.so.*"
+FILES_libpci-dev = "${includedir} ${FILES_SOLIBSDEV} ${libdir}/pkgconfig"
 SUMMARY_${PN}-ids = "PCI utilities - device ID database"
 DESCRIPTION_${PN}-ids = "Package providing the PCI device ID database for pciutils."
 RDEPENDS_${PN} += "${PN}-ids"
+RDEPENDS_libpci-dev = "libpci (= ${EXTENDPKGV})"
-- 
2.19.2



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

* Re: [PATCH v2] pciutils: Move headers from pciutils-dev to libpci-dev
  2018-12-02  3:14 [PATCH v2] pciutils: Move headers from pciutils-dev to libpci-dev Robert Joslyn
@ 2018-12-02 10:43 ` Richard Purdie
  2018-12-03  1:42   ` Robert Joslyn
  0 siblings, 1 reply; 3+ messages in thread
From: Richard Purdie @ 2018-12-02 10:43 UTC (permalink / raw)
  To: Robert Joslyn, openembedded-core

On Sat, 2018-12-01 at 19:14 -0800, Robert Joslyn wrote:
> The pciutils recipe places libpci in a separate package, but the
> default
> package split puts the headers for the library in pciutils-dev. When
> building an SDK for an image that uses libpci, but not pciutils, the
> headers for libpci are not included.
> 
> Move the headers, unversioned so symlink, and pkgconfig files from
> pciutils-dev to libpci-dev so the SDK gets those files for images
> using
> libpci.
> 
> Signed-off-by: Robert Joslyn <robert.joslyn@redrectangle.org>
> ---
>  meta/recipes-bsp/pciutils/pciutils_3.6.2.bb | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> b/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> index 413421cd8a..de1e54e5a5 100644
> --- a/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> +++ b/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> @@ -52,9 +52,11 @@ do_install () {
>  	oe_multilib_header pci/config.h
>  }
>  
> -PACKAGES =+ "${PN}-ids libpci"
> +PACKAGES =+ "${PN}-ids libpci libpci-dev"
>  FILES_${PN}-ids = "${datadir}/pci.ids*"
>  FILES_libpci = "${libdir}/libpci.so.*"
> +FILES_libpci-dev = "${includedir} ${FILES_SOLIBSDEV}
> ${libdir}/pkgconfig"
>  SUMMARY_${PN}-ids = "PCI utilities - device ID database"
>  DESCRIPTION_${PN}-ids = "Package providing the PCI device ID
> database for pciutils."
>  RDEPENDS_${PN} += "${PN}-ids"
> +RDEPENDS_libpci-dev = "libpci (= ${EXTENDPKGV})"

"dev" packages per library don't really work unfortunately as most code
can't be split like that.

The general policy is one dev package per recipe. This patch doesn't
just move things but creates a new package.

The dev-pkgs code should be resolving "libpci" back to "pciutils" and
from there it can figure out it should be adding pciutils-dev, that is
the real bug we need to fix.

Cheers,

Richard





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

* Re: [PATCH v2] pciutils: Move headers from pciutils-dev to libpci-dev
  2018-12-02 10:43 ` Richard Purdie
@ 2018-12-03  1:42   ` Robert Joslyn
  0 siblings, 0 replies; 3+ messages in thread
From: Robert Joslyn @ 2018-12-03  1:42 UTC (permalink / raw)
  To: Richard Purdie, openembedded-core

On Sun, 2018-12-02 at 10:43 +0000, Richard Purdie wrote:
> On Sat, 2018-12-01 at 19:14 -0800, Robert Joslyn wrote:
> > The pciutils recipe places libpci in a separate package, but the
> > default
> > package split puts the headers for the library in pciutils-dev.
> > When
> > building an SDK for an image that uses libpci, but not pciutils,
> > the
> > headers for libpci are not included.
> > 
> > Move the headers, unversioned so symlink, and pkgconfig files from
> > pciutils-dev to libpci-dev so the SDK gets those files for images
> > using
> > libpci.
> > 
> > Signed-off-by: Robert Joslyn <robert.joslyn@redrectangle.org>
> > ---
> >  meta/recipes-bsp/pciutils/pciutils_3.6.2.bb | 4 +++-
> >  1 file changed, 3 insertions(+), 1 deletion(-)
> > 
> > diff --git a/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> > b/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> > index 413421cd8a..de1e54e5a5 100644
> > --- a/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> > +++ b/meta/recipes-bsp/pciutils/pciutils_3.6.2.bb
> > @@ -52,9 +52,11 @@ do_install () {
> >  	oe_multilib_header pci/config.h
> >  }
> >  
> > -PACKAGES =+ "${PN}-ids libpci"
> > +PACKAGES =+ "${PN}-ids libpci libpci-dev"
> >  FILES_${PN}-ids = "${datadir}/pci.ids*"
> >  FILES_libpci = "${libdir}/libpci.so.*"
> > +FILES_libpci-dev = "${includedir} ${FILES_SOLIBSDEV}
> > ${libdir}/pkgconfig"
> >  SUMMARY_${PN}-ids = "PCI utilities - device ID database"
> >  DESCRIPTION_${PN}-ids = "Package providing the PCI device ID
> > database for pciutils."
> >  RDEPENDS_${PN} += "${PN}-ids"
> > +RDEPENDS_libpci-dev = "libpci (= ${EXTENDPKGV})"
> 
> "dev" packages per library don't really work unfortunately as most
> code
> can't be split like that.
> 
> The general policy is one dev package per recipe. This patch doesn't
> just move things but creates a new package.
> 
> The dev-pkgs code should be resolving "libpci" back to "pciutils" and
> from there it can figure out it should be adding pciutils-dev, that
> is
> the real bug we need to fix.
> 
> Cheers,
> 
> Richard


Hi Richard,

The reason I thought to create a libpci-dev package was because if
there is only pciutils-dev, it means the other things in pciutils are
then pulled into the SDK that you may not care about. Not that big a
deal with the SDK, but it seemed better to avoid it. I can see it being
fairly annoying to split out multiple *-dev packages for more complex
recipes though.

I'm not familiar with the packaging code, but I can try to take a look
at what it would take to tie the dev-pkgs dependency back to the the
single -dev package for the recipe.

Thanks,
Robert


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

end of thread, other threads:[~2018-12-03  1:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-02  3:14 [PATCH v2] pciutils: Move headers from pciutils-dev to libpci-dev Robert Joslyn
2018-12-02 10:43 ` Richard Purdie
2018-12-03  1:42   ` Robert Joslyn

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.