Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Steffen Sledz <sledz@dresearch-fe.de>
To: Mark Hatle <mark.hatle@windriver.com>,
	 openembedded-core@lists.openembedded.org,
	 Richard Purdie <richard.purdie@linuxfoundation.org>,
	Martin Jansa <martin.jansa@gmail.com>
Subject: Re: complex versioning scenario
Date: Mon, 07 Apr 2014 14:37:06 +0200	[thread overview]
Message-ID: <53429BF2.2050804@dresearch-fe.de> (raw)
In-Reply-To: <53319AAD.5070506@windriver.com>

On 25.03.2014 16:03, Mark Hatle wrote:
> On 3/25/14, 5:31 AM, Steffen Sledz wrote:
>> On 24.03.2014 16:15, Martin Jansa wrote:
>>> On Mon, Mar 24, 2014 at 03:22:35PM +0100, Steffen Sledz wrote:
>>>> On 24.03.2014 13:53, Richard Purdie wrote:
>>>>> On Mon, 2014-03-24 at 13:49 +0100, Steffen Sledz wrote:
>>>>>> On 24.03.2014 13:35, Richard Purdie wrote:
>>>>>>> On Mon, 2014-03-24 at 13:16 +0100, Steffen Sledz wrote:
>>>>>>>> We've a complex versioning scenario here which leads me to my limits. :(
>>>>>>>>
>>>>>>>> There are two recipes. One for a shared library and one for an application using this library.
>>>>>>>>
>>>>>>>> Both use GNU autotools (so they have internal version information). For continuous integration purposes both use AUTOREV.
>>>>>>>>
>>>>>>>> At the moment the recipes look like this:
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------ libfoo_git.bb ------------- PR = "r7" PE = "2" SRCREV="${AUTOREV}" PV = "gitr${SRCPV}" ...
>>>>>>>>
>>>>>>>>
>>>>>>>> ------------ app_git.bb ---------------- DEPENDS = "... libfoo ..." PR = "r10" PE = "1" SRCREV="${AUTOREV}" PV = "gitr${SRCPV}" ...
>>>>>>>>
>>>>>>>>
>>>>>>>> Now we have the following problem. libfoo has some incompatible changes in its interface (a new internal major version).
>>>>>>>>
>>>>>>>> In my opinion this should find its represenation in the package versioning in a way that the dependency checker can guarantee that the library and the application package match each other.
>>>>>>>
>>>>>>> It is generally impossible to directly compare two git hashes and decide whether one is "greater" than the other. This is why most git recipes have PV = "0.0+git${SRCPV}" so that you can change 0.0 when something major changes. That way you can put a constraint in the second recipe.
>>>>>>>
>>>>>>> This is a fundamental problem with git versioning and not something we can fix generically.
>>>>>>
>>>>>> To have an order in the git based versions we use the PRSERV method. This works well.
>>>>>>
>>>>>> But this does not help here. The change in the library interface leads directly to a new version of the library package itself (e.g. from libfoo0_gitr100+somehash to libfoo0_gitr101+someotherhash). But i need something i can write into the DEPENDS list of the application. :(
>>>>>>
>>>>>> Steffen
>>>>>>
>>>>>> BTW: Where comes the 0 in libfoo0 from?
>>>>>
>>>>> debian.bbclass (debian package naming) which I believe in turn is derived from the actual library version.
>>>>>
>>>>> Its a class specific implementation so you can't depend on it in version information though.
>>>>
>>>> But where does it come from? A bb variable?
>>>
>>> SONAME header in library
>>>
>>> so if you're using debian.bbclass and change ABI then you should just increase major version in SONAME (that way your foo will rdepend on libfoo0 until it's rebuilt against newer libfoo1).
>>
>> Thanx, this was the decisive hint.
>>
>> I've increased the version in the SONAME header of the library and the result is a libfoo1 package. :)
>>
>> But now i hit the next problem. The following rootfs stage results in this error:
>>
>> ---------------> snip <-----------------
>> | Collected errors:
>> |  * satisfy_dependencies_for: Cannot satisfy the following dependencies for app:
>> |  *    libfoo0 (>= gitr101+somehash) *
>> ---------------> snap <-----------------
>>
>> Should the new build of libfoo1 trigger a new compile of all packages with DEPENDS containing libfoo?
>>
> 
> If the package 'requiring libfoo' has a DEPENDS += ... in it.. then yes, it should have been rebuilt when the libfoo was rebuilt.

Unfortunately i can't confirm that.  :(

part of the real app recipe:
------------> snip <-------------
DEPENDS = "vala-native libdrtrace libdrhip libdrbcc jansson"
RDEPENDS_${PN} = "dropmodes"
------------> snap <-------------

part of the real resulting opkg control file for this app:
------------> snip <-------------
Depends: dropmodes, libglib-2.0-0 (>= 2.36.4), libdrhip1 (>= gitr27+42af787eb2), libjansson4 (>= 2.4), libc6 (>= 2.18)
------------> snap <-------------

I miss the runtime dependencies for libdrtrace and libdrbcc. Where are they gone?

-- 
DResearch Fahrzeugelektronik GmbH
Otto-Schmirgal-Str. 3, 10319 Berlin, Germany
Tel: +49 30 515932-237 mailto:sledz@dresearch-fe.de
Fax: +49 30 515932-299
Geschäftsführer: Dr. Michael Weber, Werner Mögle;
Amtsgericht Berlin Charlottenburg; HRB 130120 B;
Ust.-IDNr. DE273952058


  reply	other threads:[~2014-04-07 12:37 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-24 12:16 complex versioning scenario Steffen Sledz
2014-03-24 12:35 ` Richard Purdie
2014-03-24 12:49   ` Steffen Sledz
2014-03-24 12:53     ` Richard Purdie
2014-03-24 14:22       ` Steffen Sledz
2014-03-24 15:07         ` Richard Purdie
2014-03-24 15:15         ` Martin Jansa
2014-03-25 10:31           ` Steffen Sledz
2014-03-25 10:40             ` Richard Purdie
2014-03-25 15:03             ` Mark Hatle
2014-04-07 12:37               ` Steffen Sledz [this message]
2014-04-07 13:22                 ` Steffen Sledz
2014-04-07 14:49                   ` Richard Purdie
2014-04-08 12:33                     ` Steffen Sledz
2014-04-08 17:20                       ` Khem Raj
2014-04-08 18:58                         ` Steffen Sledz
2014-04-08 21:32                           ` Khem Raj
2014-03-24 18:00 ` 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=53429BF2.2050804@dresearch-fe.de \
    --to=sledz@dresearch-fe.de \
    --cc=mark.hatle@windriver.com \
    --cc=martin.jansa@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=richard.purdie@linuxfoundation.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox