Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFE: allow running rpminspect on single rpms built locally #23

Closed
clime opened this issue Aug 10, 2019 · 5 comments
Closed

RFE: allow running rpminspect on single rpms built locally #23

clime opened this issue Aug 10, 2019 · 5 comments

Comments

@clime
Copy link

clime commented Aug 10, 2019

Hello,

I would like to integrate rpminspect into rpkg-util (https://pagure.io/rpkg-util) - a packaging utillity that I am working on. For that I would need to have support for inspecting locally built rpms. Example usage could look like this:

$ rpminspect /tmp/rpkg/rpkg-util-4-0xrca84g/noarch/rpkg-3.prototype.git.117.3a9c9748-1.fc30.noarch.rpm
@dcantrell
Copy link
Collaborator

Would you like it to run against just a single .rpm file and run the inspections it can run on a single RPM or would you like it to run against a locally created build from an SRPM file? The latter may produce multiple subpackages.

@clime
Copy link
Author

clime commented Aug 22, 2019

Hey David,

basically I will have a local srpm build results in a directory which looks like this:

drwxr-xr-x.  2 clime clime     60 Aug 22 11:03 noarch
drwxr-xr-x. 10 clime clime    500 Aug 22 11:03 rpkg-util
-rw-rw-r--.  1 clime clime 172588 Aug 22 11:03 rpkg-util-3.prototype.git.118.e948b5bb.dirty.z6w11t-1.fc30.src.rpm
-rw-rw-r--.  1 clime clime 150663 Aug 22 11:03 rpkg-util-e948b5bb-dirty.tar.gz
-rw-rw-r--.  1 clime clime  14126 Aug 22 11:03 rpkg-util.spec

where noarch contains:

rpkg-3.prototype.git.118.e948b5bb.dirty.z6w11t-1.fc30.noarch.rpm

I would like to run rpminspect on all rpms that were built. I plan to auto-discover them and pass them to rpminspect.

@clime
Copy link
Author

clime commented Aug 22, 2019

So basically, I can run rpminspect for each auto-discovered rpm or i can run rpminspect just once with all the auto-discovered rpms. I don't know, which one is better.

dcantrell added a commit that referenced this issue Aug 28, 2019
In addition to Koji builds, Koji modules, and locally cached directories
of Koji builds, rpminspect now supports specifying a single RPM as the
input.  You can specify a single RPM just like you would a single Koji
build or you can specify two RPMs to get rpminspect to perform the
comparison between the two.

Syntax example:

    $ cd ~/rpmbuild/RPMS/x86_64
    $ rpminspect -v tmux-2.9a-2.fc31.x86_64.rpm tmux-2.9a-3.fc31.x86_64.rpm

You can specify binary or source RPMs as the input.
@dcantrell
Copy link
Collaborator

I have added support for specifying local RPM packages as the input to rpminspect. You can specify just one or two and have it perform the comparison between the two. This should appear in the next Copr build as well as the next tagged release of rpminspect.

@clime
Copy link
Author

clime commented Aug 28, 2019

Cool, thanks!

jeremycline pushed a commit to jeremycline/rpminspect that referenced this issue Jul 13, 2020
In addition to Koji builds, Koji modules, and locally cached directories
of Koji builds, rpminspect now supports specifying a single RPM as the
input.  You can specify a single RPM just like you would a single Koji
build or you can specify two RPMs to get rpminspect to perform the
comparison between the two.

Syntax example:

    $ cd ~/rpmbuild/RPMS/x86_64
    $ rpminspect -v tmux-2.9a-2.fc31.x86_64.rpm tmux-2.9a-3.fc31.x86_64.rpm

You can specify binary or source RPMs as the input.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants