Bug 1241135 - allow builddep to process file regardless of filename
Summary: allow builddep to process file regardless of filename
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf-plugins-core
Version: 22
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Michael Mráka
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-07-08 14:19 UTC by Milan Kubík
Modified: 2016-07-04 18:35 UTC (History)
11 users (show)

Fixed In Version: dnf-plugins-core-0.1.10-1.fc23
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-08-15 02:13:35 UTC


Attachments (Terms of Use)

Description Milan Kubík 2015-07-08 14:19:37 UTC
Description of problem:
Up until version 0.1.6.-3 included, builddep was able to parse files that didn't end with .src.rpm, .rpm or .spec and parse them if they were spec file format compliant and install the dependencies (For example <package-name>.spec.in template).

Was this a bug/dropped intentionally? Would it be possible to reintroduce such functionality using some kind of a switch (such as --format=[spec|srpm|name])?

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Radek Holy 2015-07-09 10:19:11 UTC
I don't agree with the "regression" tag since the documentation never promised that it should work.

Comment 2 Honza Silhan 2015-07-13 09:44:48 UTC
I've got your point. You're probably dealing with chicken-egg problem. You don't have satisfied dependencies so you can't generate spec file from spec.in. We had these issues in our projects too but we have solved it with scripts and tito.

Comment 3 Honza Silhan 2015-07-13 09:50:22 UTC
The problem is the spec.in is not a valid spec file which is parsed by rpm API - rpm.spec(<file>), rpm.ds(spec.sourceHeader, 'requires'). I'd advice you to figure out how to fix it in your project setup first. Parsing invalid file seems to me hacky.

What's your view on that Florian? How can RPM handle parsing of partial spec files?

Comment 4 Milan Kubík 2015-07-13 11:56:06 UTC
Our current 'hack' around it is something like awk '/BuildRequires/ { print $2 }'  <file.spec.in> | xargs dnf install -y

This has different issues though sometimes.

Comment 5 Michael Mráka 2015-07-15 09:25:29 UTC
Proposed fix in
https://github.com/rpm-software-management/dnf-plugins-core/pull/102

Comment 6 Fedora Update System 2015-08-10 10:05:38 UTC
dnf-plugins-core-0.1.10-1.fc23,dnf-1.1.0-1.fc23,hawkey-0.6.0-1.fc23 has been submitted as an update for Fedora 23.
https://admin.fedoraproject.org/updates/dnf-plugins-core-0.1.10-1.fc23,dnf-1.1.0-1.fc23,hawkey-0.6.0-1.fc23

Comment 7 Fedora Update System 2015-08-10 10:49:39 UTC
dnf-plugins-core-0.1.10-1.fc22,dnf-1.1.0-1.fc22,hawkey-0.6.0-1.fc22 has been submitted as an update for Fedora 22.
https://admin.fedoraproject.org/updates/dnf-plugins-core-0.1.10-1.fc22,dnf-1.1.0-1.fc22,hawkey-0.6.0-1.fc22

Comment 8 Fedora Update System 2015-08-11 02:10:53 UTC
Package dnf-plugins-core-0.1.10-1.fc22, dnf-1.1.0-1.fc22, hawkey-0.6.0-1.fc22:
* should fix your issue,
* was pushed to the Fedora 22 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing dnf-plugins-core-0.1.10-1.fc22 dnf-1.1.0-1.fc22 hawkey-0.6.0-1.fc22'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2015-13162/dnf-plugins-core-0.1.10-1.fc22,dnf-1.1.0-1.fc22,hawkey-0.6.0-1.fc22
then log in and leave karma (feedback).

Comment 9 Fedora Update System 2015-08-15 02:13:35 UTC
dnf-plugins-core-0.1.10-1.fc22, hawkey-0.6.0-1.fc22, dnf-1.1.0-2.fc22 has been pushed to the Fedora 22 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 10 Fedora Update System 2015-08-19 07:51:27 UTC
dnf-plugins-core-0.1.10-1.fc23, hawkey-0.6.0-1.fc23, dnf-1.1.0-2.fc23 has been pushed to the Fedora 23 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 11 Florian Festi 2016-07-04 18:35:21 UTC
> What's your view on that Florian? How can RPM handle parsing of partial spec files?

Poorly!


Note You need to log in before you can comment on or make changes to this bug.