All of lore.kernel.org
 help / color / mirror / Atom feed
* Question about automatic dependencies when native packages are used
@ 2018-04-10 17:49 Aaron M. Biver
  2018-04-13 15:25 ` Burton, Ross
  0 siblings, 1 reply; 2+ messages in thread
From: Aaron M. Biver @ 2018-04-10 17:49 UTC (permalink / raw)
  To: yocto

[-- Attachment #1: Type: text/plain, Size: 1422 bytes --]

I'm having some trouble with native dependencies in my recipe, and I'm wondering if anyone has any tips.  I'm building with the petalinux toolset on an x64 linux for an arm architecture.

I have a recipe myapp, which has a native version, myapp-native.  myapp depends on its myapp-native, as this builds an application used in the build of myapp.  myapp also depends on a kernel module, mymodule.

So, an excerpt from myapp.bb:

DEPENDS += "mymodule myapp-native"
BBCLASSEXTEND = "native"

The problem that myapp-native is trying to include mymodule-native.  This complains:

ERROR: Nothing PROVIDES 'mymodule-native' (but virtual:native:/path/.../myapp/myapp.bb DEPENDS on or otherwise requires it)

I've tried adding a 'BBCLASSEXTEND = "native"' to mymodule.bb, but that generated build errors.

I've tried overriding the dependency in myapp.bb with
DEPENDS-native = ""

And then I tried adding this to myapp.bb
DEPENDS_${PN}-native = ""

I've also tried allowing the mymodule-native package to be empty by adding this to mymodule.bb
ALLOW_EMPTY_${PN} = "1"

As well as this:
ALLOW_EMPTY_${PN}-native = "1"

But nothing seems to work... it keeps trying to find mymodule-native.  I'd like a way to either override this dependency or make mymodule-native an empty package.  I'm all out of random spaghetti to throw against this wall, and I'm hoping someone has some experience with this.




[-- Attachment #2: Type: text/html, Size: 4380 bytes --]

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

* Re: Question about automatic dependencies when native packages are used
  2018-04-10 17:49 Question about automatic dependencies when native packages are used Aaron M. Biver
@ 2018-04-13 15:25 ` Burton, Ross
  0 siblings, 0 replies; 2+ messages in thread
From: Burton, Ross @ 2018-04-13 15:25 UTC (permalink / raw)
  To: Aaron M. Biver; +Cc: yocto

On 10 April 2018 at 18:49, Aaron M. Biver <amb58@arl.psu.edu> wrote:
> The problem that myapp-native is trying to include mymodule-native.  This
> complains:

Just make the dependency on mymodule target-specific.  Lots of ways
depending on what the dependencies are.

Either clear the native depends:

DEPENDS = "myapp-native mymodule"
DEPENDS_class-native = ""

Or add only to the target depends:

DEPENDS = "myapp-native"
DEPENDS_class-target = "mymodule"

I'm assuming that mymodule is installing headers that you need, and
you're not using DEPENDS instead of RDEPENDS.

Ross


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

end of thread, other threads:[~2018-04-13 15:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-10 17:49 Question about automatic dependencies when native packages are used Aaron M. Biver
2018-04-13 15:25 ` Burton, Ross

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.