Patchwork [2/6] gmp: also generate the libgmpcxx library

login
register
mail settings
Submitter Nitin A Kamble
Date Oct. 19, 2011, 12:30 a.m.
Message ID <35417d38f61615445ed0c4d875e0bd0aa5649af4.1318984111.git.nitin.a.kamble@intel.com>
Download mbox | patch
Permalink /patch/13447/
State New, archived
Headers show

Comments

Nitin A Kamble - Oct. 19, 2011, 12:30 a.m.
From: Nitin A Kamble <nitin.a.kamble@intel.com>

configure runs few checks to make sure c++ compiler and runtime are working as expected
with the --enable-cxx=detect option.

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
---
 meta/recipes-support/gmp/gmp.inc      |    2 ++
 meta/recipes-support/gmp/gmp_4.2.1.bb |    2 +-
 meta/recipes-support/gmp/gmp_5.0.2.bb |    2 +-
 3 files changed, 4 insertions(+), 2 deletions(-)
Saul Wold - Oct. 20, 2011, 7:50 a.m.
On 10/18/2011 05:30 PM, nitin.a.kamble@intel.com wrote:
> From: Nitin A Kamble<nitin.a.kamble@intel.com>
>
> configure runs few checks to make sure c++ compiler and runtime are working as expected
> with the --enable-cxx=detect option.
>
Somehow this change has also changed what the gmp package provides, 
before this change the package provided libgmp10 via PKG_gmp: libgmp10, 
after this change, the libgmp10 is no longer provided and causes other 
breakage.

The example case I found was a coreutils package that was built prior to 
this change failed to fulfill it's dependencies after this change when 
creating an image.  If I rebuild coreutils with the newer gmp build, 
then all is well, I think we need to understand this better before 
making this change.

Did something else change in the packaging that would cause use to look 
the mapping above?


Sau!


> Signed-off-by: Nitin A Kamble<nitin.a.kamble@intel.com>
> ---
>   meta/recipes-support/gmp/gmp.inc      |    2 ++
>   meta/recipes-support/gmp/gmp_4.2.1.bb |    2 +-
>   meta/recipes-support/gmp/gmp_5.0.2.bb |    2 +-
>   3 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/meta/recipes-support/gmp/gmp.inc b/meta/recipes-support/gmp/gmp.inc
> index 66349e6..3c662a0 100644
> --- a/meta/recipes-support/gmp/gmp.inc
> +++ b/meta/recipes-support/gmp/gmp.inc
> @@ -14,3 +14,5 @@ ARM_INSTRUCTION_SET = "arm"
>   acpaths = ""
>
>   BBCLASSEXTEND = "native nativesdk"
> +
> +EXTRA_OECONF += " --enable-cxx=detect"
> diff --git a/meta/recipes-support/gmp/gmp_4.2.1.bb b/meta/recipes-support/gmp/gmp_4.2.1.bb
> index 74da6b8..97ac4b2 100644
> --- a/meta/recipes-support/gmp/gmp_4.2.1.bb
> +++ b/meta/recipes-support/gmp/gmp_4.2.1.bb
> @@ -6,7 +6,7 @@ LICENSE = "LGPLv2.1+"
>   LIC_FILES_CHKSUM = "file://COPYING;md5=892f569a555ba9c07a568a7c0c4fa63a \
>                       file://COPYING.LIB;md5=fbc093901857fcd118f065f900982c24 \
>                       file://gmp-h.in;startline=6;endline=21;md5=5e25ffd16996faba8c1cd27b04b16099"
> -PR = "r0"
> +PR = "r1"
>
>   SRC_URI = "${GNU_MIRROR}/gmp/${BP}.tar.bz2 \
>              file://disable-stdc.patch"
> diff --git a/meta/recipes-support/gmp/gmp_5.0.2.bb b/meta/recipes-support/gmp/gmp_5.0.2.bb
> index 03fef45..f80971e 100644
> --- a/meta/recipes-support/gmp/gmp_5.0.2.bb
> +++ b/meta/recipes-support/gmp/gmp_5.0.2.bb
> @@ -2,7 +2,7 @@ require gmp.inc
>   LICENSE="LGPLv3&GPLv3"
>   LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
>   		    file://version.c;endline=18;md5=d8c56b52b9092346b9f93b4da65ef790"
> -PR = "r0"
> +PR = "r1"
>
>   SRC_URI_append += "file://sh4-asmfix.patch \
>                      file://use-includedir.patch "
Koen Kooi - Oct. 20, 2011, 8:01 a.m.
Op 20 okt. 2011, om 09:50 heeft Saul Wold het volgende geschreven:

> On 10/18/2011 05:30 PM, nitin.a.kamble@intel.com wrote:
>> From: Nitin A Kamble<nitin.a.kamble@intel.com>
>> 
>> configure runs few checks to make sure c++ compiler and runtime are working as expected
>> with the --enable-cxx=detect option.
>> 
> Somehow this change has also changed what the gmp package provides, before this change the package provided libgmp10 via PKG_gmp: libgmp10, after this change, the libgmp10 is no longer provided and causes other breakage.
> 
> The example case I found was a coreutils package that was built prior to this change failed to fulfill it's dependencies after this change when creating an image.  If I rebuild coreutils with the newer gmp build, then all is well, I think we need to understand this better before making this change.
> 
> Did something else change in the packaging that would cause use to look the mapping above?

I suspect the shlib renaming doesn't happen when 2 libraries are present without LEAD_SONAME being set in the recipe. I suggest making a new subpackage for libgmpcxx.

regards,

Koen
Phil Blundell - Oct. 20, 2011, 9:01 a.m.
On Thu, 2011-10-20 at 00:50 -0700, Saul Wold wrote:
> The example case I found was a coreutils package that was built prior to 
> this change failed to fulfill it's dependencies after this change when 
> creating an image.  If I rebuild coreutils with the newer gmp build, 
> then all is well, I think we need to understand this better before 
> making this change.
> 
> Did something else change in the packaging that would cause use to look 
> the mapping above?

If you've now got two DSOs in one output package (which it sounds like
you might have, since libgmpcxx was apparently added) then the autonamer
will be defeated.  They need to go in separate PACKAGES for that to work
out right.

p.
Nitin A Kamble - Oct. 21, 2011, 6:04 a.m.
> -----Original Message-----
> From: Saul Wold [mailto:saul.wold@intel.com]
> Sent: Thursday, October 20, 2011 12:50 AM
> To: Patches and discussions about the oe-core layer
> Cc: Kamble, Nitin A
> Subject: Re: [OE-core] [PATCH 2/6] gmp: also generate the libgmpcxx
> library
> 
> On 10/18/2011 05:30 PM, nitin.a.kamble@intel.com wrote:
> > From: Nitin A Kamble<nitin.a.kamble@intel.com>
> >
> > configure runs few checks to make sure c++ compiler and runtime are
> working as expected
> > with the --enable-cxx=detect option.
> >
> Somehow this change has also changed what the gmp package provides,
> before this change the package provided libgmp10 via PKG_gmp: libgmp10,
> after this change, the libgmp10 is no longer provided and causes other
> breakage.
> 
> The example case I found was a coreutils package that was built prior
> to
> this change failed to fulfill it's dependencies after this change when
> creating an image.  If I rebuild coreutils with the newer gmp build,
> then all is well, I think we need to understand this better before
> making this change.
> 
> Did something else change in the packaging that would cause use to look
> the mapping above?
> 
Saul,
  In my testing I did not get any of these issues you mentioned above. 

Also I tried to reproduce the issue with coreutils as mentioned above, and I can not reproduce the issue for creations of an image. Can you verify the issue one more time?

Thanks,
Nitin

> 
> Sau!
> 
> 
> > Signed-off-by: Nitin A Kamble<nitin.a.kamble@intel.com>
> > ---
> >   meta/recipes-support/gmp/gmp.inc      |    2 ++
> >   meta/recipes-support/gmp/gmp_4.2.1.bb |    2 +-
> >   meta/recipes-support/gmp/gmp_5.0.2.bb |    2 +-
> >   3 files changed, 4 insertions(+), 2 deletions(-)
> >
> > diff --git a/meta/recipes-support/gmp/gmp.inc b/meta/recipes-
> support/gmp/gmp.inc
> > index 66349e6..3c662a0 100644
> > --- a/meta/recipes-support/gmp/gmp.inc
> > +++ b/meta/recipes-support/gmp/gmp.inc
> > @@ -14,3 +14,5 @@ ARM_INSTRUCTION_SET = "arm"
> >   acpaths = ""
> >
> >   BBCLASSEXTEND = "native nativesdk"
> > +
> > +EXTRA_OECONF += " --enable-cxx=detect"
> > diff --git a/meta/recipes-support/gmp/gmp_4.2.1.bb b/meta/recipes-
> support/gmp/gmp_4.2.1.bb
> > index 74da6b8..97ac4b2 100644
> > --- a/meta/recipes-support/gmp/gmp_4.2.1.bb
> > +++ b/meta/recipes-support/gmp/gmp_4.2.1.bb
> > @@ -6,7 +6,7 @@ LICENSE = "LGPLv2.1+"
> >   LIC_FILES_CHKSUM =
> "file://COPYING;md5=892f569a555ba9c07a568a7c0c4fa63a \
> >
> file://COPYING.LIB;md5=fbc093901857fcd118f065f900982c24 \
> >                       file://gmp-
> h.in;startline=6;endline=21;md5=5e25ffd16996faba8c1cd27b04b16099"
> > -PR = "r0"
> > +PR = "r1"
> >
> >   SRC_URI = "${GNU_MIRROR}/gmp/${BP}.tar.bz2 \
> >              file://disable-stdc.patch"
> > diff --git a/meta/recipes-support/gmp/gmp_5.0.2.bb b/meta/recipes-
> support/gmp/gmp_5.0.2.bb
> > index 03fef45..f80971e 100644
> > --- a/meta/recipes-support/gmp/gmp_5.0.2.bb
> > +++ b/meta/recipes-support/gmp/gmp_5.0.2.bb
> > @@ -2,7 +2,7 @@ require gmp.inc
> >   LICENSE="LGPLv3&GPLv3"
> >   LIC_FILES_CHKSUM =
> "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
> >
> file://version.c;endline=18;md5=d8c56b52b9092346b9f93b4da65ef790"
> > -PR = "r0"
> > +PR = "r1"
> >
> >   SRC_URI_append += "file://sh4-asmfix.patch \
> >                      file://use-includedir.patch "
Saul Wold - Oct. 21, 2011, 7:54 a.m.
On 10/20/2011 11:04 PM, Kamble, Nitin A wrote:
>
>
>> -----Original Message-----
>> From: Saul Wold [mailto:saul.wold@intel.com]
>> Sent: Thursday, October 20, 2011 12:50 AM
>> To: Patches and discussions about the oe-core layer
>> Cc: Kamble, Nitin A
>> Subject: Re: [OE-core] [PATCH 2/6] gmp: also generate the libgmpcxx
>> library
>>
>> On 10/18/2011 05:30 PM, nitin.a.kamble@intel.com wrote:
>>> From: Nitin A Kamble<nitin.a.kamble@intel.com>
>>>
>>> configure runs few checks to make sure c++ compiler and runtime are
>> working as expected
>>> with the --enable-cxx=detect option.
>>>
>> Somehow this change has also changed what the gmp package provides,
>> before this change the package provided libgmp10 via PKG_gmp: libgmp10,
>> after this change, the libgmp10 is no longer provided and causes other
>> breakage.
>>
>> The example case I found was a coreutils package that was built prior
>> to
>> this change failed to fulfill it's dependencies after this change when
>> creating an image.  If I rebuild coreutils with the newer gmp build,
>> then all is well, I think we need to understand this better before
>> making this change.
>>
>> Did something else change in the packaging that would cause use to look
>> the mapping above?
>>
> Saul,
>    In my testing I did not get any of these issues you mentioned above.
>
> Also I tried to reproduce the issue with coreutils as mentioned above, and I can not reproduce the issue for creations of an image. Can you verify the issue one more time?
>
Just to confirm, did you have a build of coreutils prior to your gmp 
changes? Which image did you build?  Be sure you build an image that 
includes coreutils, such at an -sdk image.

I can easily reproduce this issue.

Sau!

> Thanks,
> Nitin
>
>>
>> Sau!
>>
>>
>>> Signed-off-by: Nitin A Kamble<nitin.a.kamble@intel.com>
>>> ---
>>>    meta/recipes-support/gmp/gmp.inc      |    2 ++
>>>    meta/recipes-support/gmp/gmp_4.2.1.bb |    2 +-
>>>    meta/recipes-support/gmp/gmp_5.0.2.bb |    2 +-
>>>    3 files changed, 4 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/meta/recipes-support/gmp/gmp.inc b/meta/recipes-
>> support/gmp/gmp.inc
>>> index 66349e6..3c662a0 100644
>>> --- a/meta/recipes-support/gmp/gmp.inc
>>> +++ b/meta/recipes-support/gmp/gmp.inc
>>> @@ -14,3 +14,5 @@ ARM_INSTRUCTION_SET = "arm"
>>>    acpaths = ""
>>>
>>>    BBCLASSEXTEND = "native nativesdk"
>>> +
>>> +EXTRA_OECONF += " --enable-cxx=detect"
>>> diff --git a/meta/recipes-support/gmp/gmp_4.2.1.bb b/meta/recipes-
>> support/gmp/gmp_4.2.1.bb
>>> index 74da6b8..97ac4b2 100644
>>> --- a/meta/recipes-support/gmp/gmp_4.2.1.bb
>>> +++ b/meta/recipes-support/gmp/gmp_4.2.1.bb
>>> @@ -6,7 +6,7 @@ LICENSE = "LGPLv2.1+"
>>>    LIC_FILES_CHKSUM =
>> "file://COPYING;md5=892f569a555ba9c07a568a7c0c4fa63a \
>>>
>> file://COPYING.LIB;md5=fbc093901857fcd118f065f900982c24 \
>>>                        file://gmp-
>> h.in;startline=6;endline=21;md5=5e25ffd16996faba8c1cd27b04b16099"
>>> -PR = "r0"
>>> +PR = "r1"
>>>
>>>    SRC_URI = "${GNU_MIRROR}/gmp/${BP}.tar.bz2 \
>>>               file://disable-stdc.patch"
>>> diff --git a/meta/recipes-support/gmp/gmp_5.0.2.bb b/meta/recipes-
>> support/gmp/gmp_5.0.2.bb
>>> index 03fef45..f80971e 100644
>>> --- a/meta/recipes-support/gmp/gmp_5.0.2.bb
>>> +++ b/meta/recipes-support/gmp/gmp_5.0.2.bb
>>> @@ -2,7 +2,7 @@ require gmp.inc
>>>    LICENSE="LGPLv3&GPLv3"
>>>    LIC_FILES_CHKSUM =
>> "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
>>>
>> file://version.c;endline=18;md5=d8c56b52b9092346b9f93b4da65ef790"
>>> -PR = "r0"
>>> +PR = "r1"
>>>
>>>    SRC_URI_append += "file://sh4-asmfix.patch \
>>>                       file://use-includedir.patch "
>
Nitin A Kamble - Oct. 21, 2011, 4:54 p.m.
> -----Original Message-----
> From: Saul Wold [mailto:saul.wold@intel.com]
> Sent: Friday, October 21, 2011 12:55 AM
> To: Kamble, Nitin A
> Cc: Patches and discussions about the oe-core layer
> Subject: Re: [OE-core] [PATCH 2/6] gmp: also generate the libgmpcxx
> library
> 
> On 10/20/2011 11:04 PM, Kamble, Nitin A wrote:
> >
> >
> >> -----Original Message-----
> >> From: Saul Wold [mailto:saul.wold@intel.com]
> >> Sent: Thursday, October 20, 2011 12:50 AM
> >> To: Patches and discussions about the oe-core layer
> >> Cc: Kamble, Nitin A
> >> Subject: Re: [OE-core] [PATCH 2/6] gmp: also generate the libgmpcxx
> >> library
> >>
> >> On 10/18/2011 05:30 PM, nitin.a.kamble@intel.com wrote:
> >>> From: Nitin A Kamble<nitin.a.kamble@intel.com>
> >>>
> >>> configure runs few checks to make sure c++ compiler and runtime are
> >> working as expected
> >>> with the --enable-cxx=detect option.
> >>>
> >> Somehow this change has also changed what the gmp package provides,
> >> before this change the package provided libgmp10 via PKG_gmp:
> libgmp10,
> >> after this change, the libgmp10 is no longer provided and causes
> other
> >> breakage.
> >>
> >> The example case I found was a coreutils package that was built
> prior
> >> to
> >> this change failed to fulfill it's dependencies after this change
> when
> >> creating an image.  If I rebuild coreutils with the newer gmp build,
> >> then all is well, I think we need to understand this better before
> >> making this change.
> >>
> >> Did something else change in the packaging that would cause use to
> look
> >> the mapping above?
> >>
> > Saul,
> >    In my testing I did not get any of these issues you mentioned
> above.
> >
> > Also I tried to reproduce the issue with coreutils as mentioned
> above, and I can not reproduce the issue for creations of an image. Can
> you verify the issue one more time?
> >
> Just to confirm, did you have a build of coreutils prior to your gmp
> changes? Which image did you build?  Be sure you build an image that
> includes coreutils, such at an -sdk image.
> 
> I can easily reproduce this issue.
> 
> Sau!
> 
I am able to reproduce the issue with sdk image, The packages(rpms) generated are different in r0 vs r1 version of gmp. Hence you are seeing that issue. Earlier libgmp.so.10 was the only library need packaging, so I guest package name was chosen aslibgmp10. now libgmpxx.so is also part of the package, hence recipe name which is gmp is chosen as the package name.  

$ ls gmp-5.0.2-r0/deploy-rpms/i586/
libgmp10-5.0.2-r0.i586.rpm    libgmp-dev-5.0.2-r0.i586.rpm  libgmp-staticdev-5.0.2-r0.i586.rpm
libgmp-dbg-5.0.2-r0.i586.rpm  libgmp-doc-5.0.2-r0.i586.rpm

$ ls gmp-5.0.2-r1/deploy-rpms/i586/
gmp-5.0.2-r1.i586.rpm      gmp-dev-5.0.2-r1.i586.rpm  gmp-staticdev-5.0.2-r1.i586.rpm
gmp-dbg-5.0.2-r1.i586.rpm  gmp-doc-5.0.2-r1.i586.rpm

Thanks,
Nitin

> > Thanks,
> > Nitin
> >
> >>
> >> Sau!
> >>
> >>
> >>> Signed-off-by: Nitin A Kamble<nitin.a.kamble@intel.com>
> >>> ---
> >>>    meta/recipes-support/gmp/gmp.inc      |    2 ++
> >>>    meta/recipes-support/gmp/gmp_4.2.1.bb |    2 +-
> >>>    meta/recipes-support/gmp/gmp_5.0.2.bb |    2 +-
> >>>    3 files changed, 4 insertions(+), 2 deletions(-)
> >>>
> >>> diff --git a/meta/recipes-support/gmp/gmp.inc b/meta/recipes-
> >> support/gmp/gmp.inc
> >>> index 66349e6..3c662a0 100644
> >>> --- a/meta/recipes-support/gmp/gmp.inc
> >>> +++ b/meta/recipes-support/gmp/gmp.inc
> >>> @@ -14,3 +14,5 @@ ARM_INSTRUCTION_SET = "arm"
> >>>    acpaths = ""
> >>>
> >>>    BBCLASSEXTEND = "native nativesdk"
> >>> +
> >>> +EXTRA_OECONF += " --enable-cxx=detect"
> >>> diff --git a/meta/recipes-support/gmp/gmp_4.2.1.bb b/meta/recipes-
> >> support/gmp/gmp_4.2.1.bb
> >>> index 74da6b8..97ac4b2 100644
> >>> --- a/meta/recipes-support/gmp/gmp_4.2.1.bb
> >>> +++ b/meta/recipes-support/gmp/gmp_4.2.1.bb
> >>> @@ -6,7 +6,7 @@ LICENSE = "LGPLv2.1+"
> >>>    LIC_FILES_CHKSUM =
> >> "file://COPYING;md5=892f569a555ba9c07a568a7c0c4fa63a \
> >>>
> >> file://COPYING.LIB;md5=fbc093901857fcd118f065f900982c24 \
> >>>                        file://gmp-
> >> h.in;startline=6;endline=21;md5=5e25ffd16996faba8c1cd27b04b16099"
> >>> -PR = "r0"
> >>> +PR = "r1"
> >>>
> >>>    SRC_URI = "${GNU_MIRROR}/gmp/${BP}.tar.bz2 \
> >>>               file://disable-stdc.patch"
> >>> diff --git a/meta/recipes-support/gmp/gmp_5.0.2.bb b/meta/recipes-
> >> support/gmp/gmp_5.0.2.bb
> >>> index 03fef45..f80971e 100644
> >>> --- a/meta/recipes-support/gmp/gmp_5.0.2.bb
> >>> +++ b/meta/recipes-support/gmp/gmp_5.0.2.bb
> >>> @@ -2,7 +2,7 @@ require gmp.inc
> >>>    LICENSE="LGPLv3&GPLv3"
> >>>    LIC_FILES_CHKSUM =
> >> "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
> >>>
> >> file://version.c;endline=18;md5=d8c56b52b9092346b9f93b4da65ef790"
> >>> -PR = "r0"
> >>> +PR = "r1"
> >>>
> >>>    SRC_URI_append += "file://sh4-asmfix.patch \
> >>>                       file://use-includedir.patch "
> >

Patch

diff --git a/meta/recipes-support/gmp/gmp.inc b/meta/recipes-support/gmp/gmp.inc
index 66349e6..3c662a0 100644
--- a/meta/recipes-support/gmp/gmp.inc
+++ b/meta/recipes-support/gmp/gmp.inc
@@ -14,3 +14,5 @@  ARM_INSTRUCTION_SET = "arm"
 acpaths = ""
 
 BBCLASSEXTEND = "native nativesdk"
+
+EXTRA_OECONF += " --enable-cxx=detect"
diff --git a/meta/recipes-support/gmp/gmp_4.2.1.bb b/meta/recipes-support/gmp/gmp_4.2.1.bb
index 74da6b8..97ac4b2 100644
--- a/meta/recipes-support/gmp/gmp_4.2.1.bb
+++ b/meta/recipes-support/gmp/gmp_4.2.1.bb
@@ -6,7 +6,7 @@  LICENSE = "LGPLv2.1+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=892f569a555ba9c07a568a7c0c4fa63a \
                     file://COPYING.LIB;md5=fbc093901857fcd118f065f900982c24 \
                     file://gmp-h.in;startline=6;endline=21;md5=5e25ffd16996faba8c1cd27b04b16099"
-PR = "r0"
+PR = "r1"
 
 SRC_URI = "${GNU_MIRROR}/gmp/${BP}.tar.bz2 \
            file://disable-stdc.patch"
diff --git a/meta/recipes-support/gmp/gmp_5.0.2.bb b/meta/recipes-support/gmp/gmp_5.0.2.bb
index 03fef45..f80971e 100644
--- a/meta/recipes-support/gmp/gmp_5.0.2.bb
+++ b/meta/recipes-support/gmp/gmp_5.0.2.bb
@@ -2,7 +2,7 @@  require gmp.inc
 LICENSE="LGPLv3&GPLv3"
 LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
 		    file://version.c;endline=18;md5=d8c56b52b9092346b9f93b4da65ef790"
-PR = "r0"
+PR = "r1"
 
 SRC_URI_append += "file://sh4-asmfix.patch \
                    file://use-includedir.patch "