All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ola x Nilsson <ola.x.nilsson@axis.com>
To: <openembedded-core@lists.openembedded.org>
Subject: ASSUME_PROVIDED and pkg-config-native
Date: Thu, 17 Sep 2026 08:24:03 +0200	[thread overview]
Message-ID: <jwqo6dwz98c.fsf@axis.com> (raw)

Hi,

It seems it's not possible to use pkg-config to find .pc files of
all native recipes that are in the ASSUME_PROVIDED list.  Is this
supposed to work and I'm doing something wrong?  I'd appreciate any
pointers. 

Some background: 

I ran into a problem with a recipe using the Meson that had

DEPENDS = "libxcrypt apr-util"
BBCLASSEXTEND = "native"

In the native case, libaprutil.so is linked against host
libcrypt.so.1, but this recipe tries to link against libxcrypt.so.2
from libxcrypt-native, causing a conflict.

apr-util does not DEPENDS on virtual/crypt; for target builds,  it's
pulled in via util-linux. Maybe virtual/crypt should be added to
PACKAGECONFIG[crypto], but that's not really the core issue here.

virtual/crypt-native is in ASSUME_PROVIDED.  When switching to DEPENDS =
"virtual/crypt" Meson's dependency('libxcrypt') can no longer find the
.pc file, neither in recipe-sysroot-native nor in
/usr/lib/x86_64-linux-gnu/pkgconfig.  The pkg-config-native and
pkg-config wrappers around pkgconf ensure that system library folders
are not searched.

I don't think EXTRA_NATIVE_PKGCONFIG_PATH can be used here.  We want the
system folders to be searched last, and ideally only for packages listed
in ASSUME_PROVIDED.  In my case the project depends on several libraries
whose options are found using pkg-config.  I don't want to accidentaly
find a system library for something that is not ASSUME_PROVIDED. 

-- 
Ola Nilsson


             reply	other threads:[~2026-09-17  6:24 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-17  6:24 Ola x Nilsson [this message]
2026-09-17  6:28 ` [OE-core] ASSUME_PROVIDED and pkg-config-native Richard Purdie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwqo6dwz98c.fsf@axis.com \
    --to=ola.x.nilsson@axis.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.