From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Alexander Kanavin <alex.kanavin@gmail.com>,
Khem Raj <raj.khem@gmail.com>
Cc: Patches and discussions about the oe-core layer
<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH] libmodulemd: fix erroneous linking against v2 library when v1 was requested
Date: Wed, 22 May 2019 12:08:21 +0100 [thread overview]
Message-ID: <33700e11097f8b98ea98acfce06977e24c3bfb8d.camel@linuxfoundation.org> (raw)
In-Reply-To: <CANNYZj8cSb0_7fRhG=bbizctTnaQg53hVwSzOu5WoWr9ywbMKQ@mail.gmail.com>
On Wed, 2019-05-22 at 12:28 +0200, Alexander Kanavin wrote:
> On Wed, 22 May 2019 at 04:04, Khem Raj <raj.khem@gmail.com> wrote:
> > > +
> > > + pkg.generate(
> > > +- libraries : modulemd_v1_lib,
> > > ++ libraries : '-l:libmodulemd.so.1',
> >
> > shouldn't it be generating a separate package for v1 ?
> > hardcoding linker paths seems a bit hackish here, is it going
> > to generate a .pc file with .so.1 version ?
>
> The problem is that both v2 and v1 are installed into the sysroot; we
> don't have a mechanism to choose one or the other via DEPENDS (unlike
> desktop distros where you can install -v1-dev or -v2-dev package for
> your build).
> Then both v2 and v1 .pc files (without this patch) refer to
> '-lmodulemd' which in our case always resolves to v2 library.
>
> Wth the patch the generated v1 .pc will look like this, while v2
> continues to use the original '-lmodlulemd' in Libs:
>
> prefix=${pcfiledir}/../../../usr
> libdir=${prefix}/lib
> includedir=${prefix}/include
>
> Name: modulemd
> Description: Module metadata manipulation library
> Version: 1.8.10
> Requires: glib-2.0, gobject-2.0
> Libs: -l:libmodulemd.so.1
> Cflags: -I${includedir}/modulemd
FWIW I think if there were two different recipes we could select which
was in the sysroot through DEPENDS?
Cheers,
Richard
next prev parent reply other threads:[~2019-05-22 11:08 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-21 16:11 [PATCH] libmodulemd: fix erroneous linking against v2 library when v1 was requested Alexander Kanavin
2019-05-22 2:04 ` Khem Raj
2019-05-22 10:28 ` Alexander Kanavin
2019-05-22 11:08 ` Richard Purdie [this message]
2019-05-22 11:20 ` Alexander Kanavin
2019-05-22 13:48 ` Khem Raj
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=33700e11097f8b98ea98acfce06977e24c3bfb8d.camel@linuxfoundation.org \
--to=richard.purdie@linuxfoundation.org \
--cc=alex.kanavin@gmail.com \
--cc=openembedded-core@lists.openembedded.org \
--cc=raj.khem@gmail.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox