Bug 197271 - createrepo creates arch="i386" for src.rpm files
Summary: createrepo creates arch="i386" for src.rpm files
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: createrepo
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Paul Nasrat
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-06-29 19:14 UTC by Robert Scheck
Modified: 2014-01-21 22:54 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-06-30 12:45:48 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Proposed patch (608 bytes, patch)
2006-06-30 01:42 UTC, Paul Nasrat
no flags Details | Diff

Description Robert Scheck 2006-06-29 19:14:10 UTC
Description of problem:
createrepo creates arch="i386" for src.rpm files. At least the following (taken 
from filelists.xml.gz) created by createrepo looks very broken to me:

<package pkgid="c3442e30a9ca21f9875809d4891e4d4dbc7dcada" name="tk" 
arch="i386"><version epoch="0" ver="8.4.13" rel="1"/><file>tk-8.3.5-tclm4-
soname.patch</file><file>tk-8.4-no_rpath.patch</file><file>tk-8.4.13-autoconf.
patch</file><file>tk-8.4.4-lib-perm.patch</file><file>tk.spec</file><file>tk8.4.
13-src.tar.gz</file></package>

Ever tried to upgrade from i386.rpm to a src.rpm? :)

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

How reproducible:
Everytime, just run createrepo when you've got src.rpms and i386.rpms within a 
(sub-)directory accessed by createrepo. After removing src.rpms and re-executing 
of createrepo the repodata stuff seems to be correct.

Actual results:
createrepo creates broken repodata.

Expected results:
Working repodata again - even when src.rpm and i386.rpm files are in the same 
(sub-)directory.

Comment 1 Paul Nasrat 2006-06-29 21:31:46 UTC
Technically the src.rpm has RPMTAG_ARCH set - try it:

rpm -qp --qf '%{arch}\n' dummy-1.0-1.src.rpm
i386

This is why the convention has been to keep src.rpm repos seperate for fedora. 
The way to identify a src.rpm is the absence of sourcerpm filed.

rpm -qp --qf '%{sourcerpm}\n' dummy-1.0-1.src.rpm
(none)




Comment 2 Robert Scheck 2006-06-29 21:34:43 UTC
But the stuff worked with older versions of createrepo...

Comment 3 Paul Nasrat 2006-06-30 01:33:28 UTC
If you let me know which version we regress from I'll look into. Particularly
with xml fragment, etc.

Comment 4 Paul Nasrat 2006-06-30 01:42:19 UTC
Created attachment 131777 [details]
Proposed patch

Hmm are you using rpm >= 4.4.6? If so see CHANGES for why this broke - attached
createrepo patch will work around.  Please in future if you are using
non-standard core packages mention this in the bug report.

Please test this and I'll commit upstream (it looks logically correct to me).

Comment 5 Robert Scheck 2006-06-30 08:47:42 UTC
Oops...yes I am - sorry. And yes your patch works, of course and looks sane, 
too. Thank you very much for resolving it anyway :)

Comment 6 Paul Nasrat 2006-06-30 12:45:48 UTC
Commited to upstream createrepo.


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