All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paul Eggleton <paul.eggleton@linux.intel.com>
To: Giuseppe Condorelli <giuseppe.condorelli@gmail.com>
Cc: openembedded-core@lists.openembedded.org
Subject: Re: How to query installed rpm packages
Date: Tue, 29 May 2012 14:32:58 +0100	[thread overview]
Message-ID: <11156699.ieWXhGW3v3@helios> (raw)
In-Reply-To: <CAOHjBZu6_vfPkPnVj9E48nc=1jEO9dqMG8hkrtLkLesbWZ8g6w@mail.gmail.com>

On Tuesday 29 May 2012 15:20:14 Giuseppe Condorelli wrote:
> What I'm not understanding is how I can invoke my shell function. Do you
> mean I have to invoke it as append function of populate_rootfs one? 

If you aren't including packaging data in the resulting image (i.e. 
IMAGE_FEATURES does not contain "package-management"), you need to do your rpm 
calls from a function called via ROOTFS_POSTPROCESS_COMMAND because afterwards 
the data will be removed and rpm will not be usable.

> What I really need is a way to query the rpm database
> out from the build system, as we normally do with host packages.
> I tried to have a standalone run of  the rpm command the
> list_installed_packages invokes but (obviously) I got a long series of
> errors.

Below is what I meant - you could put this into some bbclass that you could 
add using INHERIT += "someclass.bbclass" in local.conf:

------------- snip --------------
ROOTFS_POSTPROCESS_COMMAND += "do_some_packaging_stuff ; "

do_some_packaging_stuff() {
	list_installed_packages > /path/to/output/file
}
------------- snip --------------

Substitute list_installed_packages for a similar rpm query command to the one 
list_installed_packages uses.

Out of interest, what information are you querying from the packaging system?

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre



  reply	other threads:[~2012-05-29 13:43 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-28 13:14 How to query installed rpm packages Giuseppe Condorelli
2012-05-28 13:26 ` Paul Eggleton
2012-05-28 15:30   ` Giuseppe Condorelli
2012-05-28 16:23     ` Paul Eggleton
2012-05-29 13:20       ` Giuseppe Condorelli
2012-05-29 13:32         ` Paul Eggleton [this message]
2012-05-29 13:49           ` Giuseppe Condorelli
2012-05-30 10:29             ` Giuseppe Condorelli
2012-05-30 10:34               ` Paul Eggleton

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=11156699.ieWXhGW3v3@helios \
    --to=paul.eggleton@linux.intel.com \
    --cc=giuseppe.condorelli@gmail.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.