All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] rpm: avoid dependency on perl and python for -native build
@ 2011-06-02  9:48 Phil Blundell
  2011-06-02 13:29 ` Mark Hatle
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Phil Blundell @ 2011-06-02  9:48 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

Update override naming (_native -> _virtclass-native) to disable perl
and python bindings when building native rpm, and adjust the DEPENDS to
match.

Perl bindings were, in fact, already disabled for both native and target
builds so it's only the python ones that have really changed.

Signed-off-by: Phil Blundell <philb@gnu.org>
---
 meta/recipes-devtools/rpm/rpm_5.4.0.bb |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/meta/recipes-devtools/rpm/rpm_5.4.0.bb b/meta/recipes-devtools/rpm/rpm_5.4.0.bb
index d3f85f2..5c30f1c 100644
--- a/meta/recipes-devtools/rpm/rpm_5.4.0.bb
+++ b/meta/recipes-devtools/rpm/rpm_5.4.0.bb
@@ -42,8 +42,10 @@ HOMEPAGE = "http://rpm5.org/"
 LICENSE = "LGPL 2.1"
 LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1"
 
-DEPENDS = "bzip2 zlib python perl db openssl elfutils expat libpcre attr acl popt"
-PR = "r16"
+rpmdeps = "bzip2 zlib db openssl elfutils expat libpcre attr acl popt"
+DEPENDS = "${rpmdeps} python perl"
+DEPENDS_virtclass-native = "${rpmdeps}"
+PR = "r17"
 
 # rpm2cpio is a shell script, which is part of the rpm src.rpm.  It is needed
 # in order to extract the distribution SRPM into a format we can extract...
@@ -92,7 +94,7 @@ WITH_PYTHON = "	--with-python=${PYTHON_BASEVERSION} \
 		--without-pythonembed \
 	      "
 
-WITH_PYTHON_native = " --without-python"
+WITH_PYTHON_virtclass-native = " --without-python"
 
 # Perl modules are not built, but they could be enabled fairly easily
 # the perl module creation and installation would need to be patched.
@@ -100,7 +102,7 @@ WITH_PYTHON_native = " --without-python"
 #WITH_PERL = "	--with-perl --without-perlembed"
 WITH_PERL = "	--without-perl"
 
-WITH_PERL_native = " --without-perl"
+WITH_PERL_virtclass-native = " --without-perl"
 
 WITH_DB = "--with-db --with-dbsql --without-db-tools-integrated --without-sqlite"
 
-- 
1.7.1






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

* Re: [PATCH] rpm: avoid dependency on perl and python for -native build
  2011-06-02  9:48 [PATCH] rpm: avoid dependency on perl and python for -native build Phil Blundell
@ 2011-06-02 13:29 ` Mark Hatle
  2011-06-02 13:52 ` Richard Purdie
  2011-06-02 21:25 ` Richard Purdie
  2 siblings, 0 replies; 7+ messages in thread
From: Mark Hatle @ 2011-06-02 13:29 UTC (permalink / raw)
  To: openembedded-core

On 6/2/11 4:48 AM, Phil Blundell wrote:
> Update override naming (_native -> _virtclass-native) to disable perl
> and python bindings when building native rpm, and adjust the DEPENDS to
> match.
> 
> Perl bindings were, in fact, already disabled for both native and target
> builds so it's only the python ones that have really changed.
> 
> Signed-off-by: Phil Blundell <philb@gnu.org>

Acked-by: Mark Hatle <mark.hatle@windriver.com>

> ---
>  meta/recipes-devtools/rpm/rpm_5.4.0.bb |   10 ++++++----
>  1 files changed, 6 insertions(+), 4 deletions(-)
> 
> diff --git a/meta/recipes-devtools/rpm/rpm_5.4.0.bb b/meta/recipes-devtools/rpm/rpm_5.4.0.bb
> index d3f85f2..5c30f1c 100644
> --- a/meta/recipes-devtools/rpm/rpm_5.4.0.bb
> +++ b/meta/recipes-devtools/rpm/rpm_5.4.0.bb
> @@ -42,8 +42,10 @@ HOMEPAGE = "http://rpm5.org/"
>  LICENSE = "LGPL 2.1"
>  LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1"
>  
> -DEPENDS = "bzip2 zlib python perl db openssl elfutils expat libpcre attr acl popt"
> -PR = "r16"
> +rpmdeps = "bzip2 zlib db openssl elfutils expat libpcre attr acl popt"
> +DEPENDS = "${rpmdeps} python perl"
> +DEPENDS_virtclass-native = "${rpmdeps}"
> +PR = "r17"
>  
>  # rpm2cpio is a shell script, which is part of the rpm src.rpm.  It is needed
>  # in order to extract the distribution SRPM into a format we can extract...
> @@ -92,7 +94,7 @@ WITH_PYTHON = "	--with-python=${PYTHON_BASEVERSION} \
>  		--without-pythonembed \
>  	      "
>  
> -WITH_PYTHON_native = " --without-python"
> +WITH_PYTHON_virtclass-native = " --without-python"
>  
>  # Perl modules are not built, but they could be enabled fairly easily
>  # the perl module creation and installation would need to be patched.
> @@ -100,7 +102,7 @@ WITH_PYTHON_native = " --without-python"
>  #WITH_PERL = "	--with-perl --without-perlembed"
>  WITH_PERL = "	--without-perl"
>  
> -WITH_PERL_native = " --without-perl"
> +WITH_PERL_virtclass-native = " --without-perl"
>  
>  WITH_DB = "--with-db --with-dbsql --without-db-tools-integrated --without-sqlite"
>  




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

* Re: [PATCH] rpm: avoid dependency on perl and python for -native build
  2011-06-02  9:48 [PATCH] rpm: avoid dependency on perl and python for -native build Phil Blundell
  2011-06-02 13:29 ` Mark Hatle
@ 2011-06-02 13:52 ` Richard Purdie
  2011-06-02 21:25 ` Richard Purdie
  2 siblings, 0 replies; 7+ messages in thread
From: Richard Purdie @ 2011-06-02 13:52 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On Thu, 2011-06-02 at 10:48 +0100, Phil Blundell wrote:
> Update override naming (_native -> _virtclass-native) to disable perl
> and python bindings when building native rpm, and adjust the DEPENDS to
> match.
> 
> Perl bindings were, in fact, already disabled for both native and target
> builds so it's only the python ones that have really changed.
> 
> Signed-off-by: Phil Blundell <philb@gnu.org>
> ---

Merged to master, thanks.

Richard




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

* Re: [PATCH] rpm: avoid dependency on perl and python for -native build
  2011-06-02  9:48 [PATCH] rpm: avoid dependency on perl and python for -native build Phil Blundell
  2011-06-02 13:29 ` Mark Hatle
  2011-06-02 13:52 ` Richard Purdie
@ 2011-06-02 21:25 ` Richard Purdie
  2011-06-02 21:37   ` Phil Blundell
  2 siblings, 1 reply; 7+ messages in thread
From: Richard Purdie @ 2011-06-02 21:25 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On Thu, 2011-06-02 at 10:48 +0100, Phil Blundell wrote:
> Update override naming (_native -> _virtclass-native) to disable perl
> and python bindings when building native rpm, and adjust the DEPENDS to
> match.
> 
> Perl bindings were, in fact, already disabled for both native and target
> builds so it's only the python ones that have really changed.
> 
> Signed-off-by: Phil Blundell <philb@gnu.org>
> ---
>  meta/recipes-devtools/rpm/rpm_5.4.0.bb |   10 ++++++----
>  1 files changed, 6 insertions(+), 4 deletions(-)
> 
> diff --git a/meta/recipes-devtools/rpm/rpm_5.4.0.bb b/meta/recipes-devtools/rpm/rpm_5.4.0.bb
> index d3f85f2..5c30f1c 100644
> --- a/meta/recipes-devtools/rpm/rpm_5.4.0.bb
> +++ b/meta/recipes-devtools/rpm/rpm_5.4.0.bb
> @@ -42,8 +42,10 @@ HOMEPAGE = "http://rpm5.org/"
>  LICENSE = "LGPL 2.1"
>  LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1"
>  
> -DEPENDS = "bzip2 zlib python perl db openssl elfutils expat libpcre attr acl popt"
> -PR = "r16"
> +rpmdeps = "bzip2 zlib db openssl elfutils expat libpcre attr acl popt"
> +DEPENDS = "${rpmdeps} python perl"
> +DEPENDS_virtclass-native = "${rpmdeps}"
> +PR = "r17"
>  
>  # rpm2cpio is a shell script, which is part of the rpm src.rpm.  It is needed
>  # in order to extract the distribution SRPM into a format we can extract...
> @@ -92,7 +94,7 @@ WITH_PYTHON = "	--with-python=${PYTHON_BASEVERSION} \
>  		--without-pythonembed \
>  	      "
>  
> -WITH_PYTHON_native = " --without-python"
> +WITH_PYTHON_virtclass-native = " --without-python"
>  
>  # Perl modules are not built, but they could be enabled fairly easily
>  # the perl module creation and installation would need to be patched.
> @@ -100,7 +102,7 @@ WITH_PYTHON_native = " --without-python"
>  #WITH_PERL = "	--with-perl --without-perlembed"
>  WITH_PERL = "	--without-perl"
>  
> -WITH_PERL_native = " --without-perl"
> +WITH_PERL_virtclass-native = " --without-perl"
>  
>  WITH_DB = "--with-db --with-dbsql --without-db-tools-integrated --without-sqlite"
>  

This appears to break the rpm-native build with:

| checking whether to build with Lua library... no
| ++ executing failure action
| ++ mapping --with-pcre=yes to --with-pcre="external:internal:none"
| ++ searching location: external
| ++ searching location: internal
| -- skipping not existing local sub-directory: pcre
| ++ searching location: none
| -- no operation
| checking pcre.h usability... no
| checking pcre.h presence... no
| checking for pcre.h... no
| checking for pcre_compile in -lpcre... no
| checking whether to build with PCRE library... no
| ++ executing failure action
| configure: error: PCRE is mandatory. If you don't have  libpcre then --with-pcre=internal could be used
| ERROR: oe_runconf failed
| ERROR: Function 'do_configure' failed (see /media/build2/builds/rptest/b2/tmp/work/x86_64-linux/rpm-native-5.4.0-r17/temp/log.do_configure.8572 for further information)
| ERROR: Function 'do_configure' failed (see /media/build2/builds/rptest/b2/tmp/work/x86_64-linux/rpm-native-5.4.0-r17/temp/log.do_configure.8572 for further information)
NOTE: package rpm-native-5.4.0-r17: task do_configure: Failed
ERROR: Task 48 (virtual:native:/media/build2/builds/rptest/meta/recipes-devtools/rpm/rpm_5.4.0.bb, do_configure) failed with exit code '1'
ERROR: 'virtual:native:/media/build2/builds/rptest/meta/recipes-devtools/rpm/rpm_5.4.0.bb' failed

:(

Cheers,

Richard





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

* Re: [PATCH] rpm: avoid dependency on perl and python for -native build
  2011-06-02 21:25 ` Richard Purdie
@ 2011-06-02 21:37   ` Phil Blundell
  2011-06-02 22:26     ` Richard Purdie
  0 siblings, 1 reply; 7+ messages in thread
From: Phil Blundell @ 2011-06-02 21:37 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On Thu, 2011-06-02 at 22:25 +0100, Richard Purdie wrote:
> | checking pcre.h usability... no
> | checking pcre.h presence... no
> | checking for pcre.h... no
> | checking for pcre_compile in -lpcre... no
> | checking whether to build with PCRE library... no
> | ++ executing failure action
> | configure: error: PCRE is mandatory. If you don't have  libpcre then --with-pcre=internal could be used

Oh dear, that's not too good.  Can you send me a copy of the config.log
corresponding to that failure?  Is pcre actually in your sysroot, or has
it just not been built and staged at all?

p.





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

* Re: [PATCH] rpm: avoid dependency on perl and python for -native build
  2011-06-02 21:37   ` Phil Blundell
@ 2011-06-02 22:26     ` Richard Purdie
  2011-06-03 10:32       ` Phil Blundell
  0 siblings, 1 reply; 7+ messages in thread
From: Richard Purdie @ 2011-06-02 22:26 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On Thu, 2011-06-02 at 22:37 +0100, Phil Blundell wrote:
> On Thu, 2011-06-02 at 22:25 +0100, Richard Purdie wrote:
> > | checking pcre.h usability... no
> > | checking pcre.h presence... no
> > | checking for pcre.h... no
> > | checking for pcre_compile in -lpcre... no
> > | checking whether to build with PCRE library... no
> > | ++ executing failure action
> > | configure: error: PCRE is mandatory. If you don't have  libpcre then --with-pcre=internal could be used
> 
> Oh dear, that's not too good.  Can you send me a copy of the config.log
> corresponding to that failure?  Is pcre actually in your sysroot, or has
> it just not been built and staged at all?

Its not been built or staged at all. I think I'm being a little hasty in
blaming your patch directly, its interacting very badly with one that
was working happily in my tree todo with cleaning up native.bbclass.

What you're doing is setting:

DEPENDS = "X"
DEPENDS_virtclass-native = "X"

and assuming that the DEPENDS_virtclass-native will get post processed
by native.bbclass to add the -native bits where needed. With my cleanup
one side effect is that no longer happens.

My understanding is that if you are going to explicitly override DEPENDS
like that you get what you say you want. We therefore likely need to do
something like:

DEPENDS = "X Y Z ${EXTRAPERLDEPS}"
EXTRAPERLDEPS = "perl python"
EXTRAPERLDEPS_virtclass-native = ""

Cheers,

Richard










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

* Re: [PATCH] rpm: avoid dependency on perl and python for -native build
  2011-06-02 22:26     ` Richard Purdie
@ 2011-06-03 10:32       ` Phil Blundell
  0 siblings, 0 replies; 7+ messages in thread
From: Phil Blundell @ 2011-06-03 10:32 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On Thu, 2011-06-02 at 23:26 +0100, Richard Purdie wrote:
> My understanding is that if you are going to explicitly override DEPENDS
> like that you get what you say you want. We therefore likely need to do
> something like:
> 
> DEPENDS = "X Y Z ${EXTRAPERLDEPS}"
> EXTRAPERLDEPS = "perl python"
> EXTRAPERLDEPS_virtclass-native = ""

Yes, that would be neater.  As it happens I did try that first but it
didn't seem to work: for reasons which were (and remain) a bit
mysterious to me, the original EXTRAPERLDEPS were always showing up in
DEPENDS for the virtclass-native build.  I assumed at the time that
there was some ordering problem between the override being processed and
the ORIG_DEPENDS assignment in native.bbclass, but I wasn't entirely
sure what the intended semantics were and so I didn't pursue that line
of enquiry any further.

p.





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

end of thread, other threads:[~2011-06-03 10:35 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-02  9:48 [PATCH] rpm: avoid dependency on perl and python for -native build Phil Blundell
2011-06-02 13:29 ` Mark Hatle
2011-06-02 13:52 ` Richard Purdie
2011-06-02 21:25 ` Richard Purdie
2011-06-02 21:37   ` Phil Blundell
2011-06-02 22:26     ` Richard Purdie
2011-06-03 10:32       ` Phil Blundell

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.