RPM

app-arch/rpm-4.4.6-r3: rpmbuild -tb can't find the embedded specfile

Bug #634189 reported by Jeff Johnson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
RPM
Triaged
Low
Unassigned
Gentoo Linux
Fix Released
Medium

Bug Description

tracker

Revision history for this message
In , jlh (jlherren) wrote :

"rpmbuild -tb tarball.tar.gz" cannot find the embedded '*.spec' file because it's not passing --wildcards to tar who requires this to match wildcards. Tar then prints a message about this, which rpmbuild misinterprets as a real output and goes on to create a file called "%{_topdir}/SPECS/tar: Pattern matching characters used in file names. Please,", which is the first line of tar's message.

Reproducible: Always

Steps to Reproduce:
Invoke "rpmbuild -tb tarball.tar.gz" on a tarball that includes a specfile that is supposed to work.
Actual Results:
rpmbuild emits the following output:

error: Name field must be present in package: (main package)
error: Version field must be present in package: (main package)
error: Release field must be present in package: (main package)
error: Summary field must be present in package: (main package)
error: Group field must be present in package: (main package)
error: License field must be present in package: (main package)

That's rpmbuild's clever way of saying that it didn't find the spec file. Using strace you can see that the following gets invoked behind the scenes: "tar xOvf - '*.spec'". Manually running this command show tar's message about wildcards.

Expected Results:
Expected result is of course that rpmbuild finds the spec file. It should pass --wildcards before the *.spec argument to tar.

app-arch/rpm-4.4.6-r6 behaves the same. I didn't test app-arch/rpm-4.4.7* as they are hard masked and said to be broken on x86 anyway.

My tar is app-arch/tar-1.20.

Revision history for this message
In , jlh (jlherren) wrote :

Here's a link to the git commit that fixes this problem:

http://devel.linux.duke.edu/gitweb/?p=rpm.git;a=commitdiff;h=39defaa877956e0719451f37d1eee81350a163ca

Putting this commit's diff into files/rpm-4.4.6-tar-wildcards.patch and enabling it in the ebuild works fine.

Revision history for this message
In , jlh (jlherren) wrote :
Revision history for this message
In , Jeff Johnson (n3npq) wrote :
tags: added: gentoo rpmbuild
Revision history for this message
Jeff Johnson (n3npq) wrote :

heh ... tar --wildcards all over again again.

Changed in rpm:
status: New → Triaged
importance: Undecided → Low
Changed in gentoo:
status: Unknown → Confirmed
Changed in gentoo:
importance: Unknown → Medium
Revision history for this message
In , Sochotnicky (sochotnicky) wrote :

Unlikely you are still experiencing the same problem, though the only stable rpm is basically the same.

I will be trying to stabilize rpm 4.9.1.2 after some more testing in the tree and cleanup older releases. It would be nice if you could test it. A simple test I've done on rpmbuild -tb with one project seemed to work for me.

Changed in gentoo:
status: Confirmed → Unknown
Revision history for this message
In , Sochotnicky (sochotnicky) wrote :

We did a cleanup of older app-arch/rpm versions. Oldest is now 4.9.1.3, please update and if you can still reproduce feel free to reopen.

Changed in gentoo:
status: Unknown → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.