SCIENTIFIC-LINUX-USERS Archives

December 2009

SCIENTIFIC-LINUX-USERS@LISTSERV.FNAL.GOV

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Garrett Holmstrom <[log in to unmask]>
Reply To:
Garrett Holmstrom <[log in to unmask]>
Date:
Fri, 11 Dec 2009 09:57:33 -0600
Content-Type:
text/plain
Parts/Attachments:
text/plain (50 lines)
Troy Dawson wrote:
> Garrett Holmstrom wrote:
>> Yumdownloader relies on repository names ending in -source to tell 
>> whether or not it should enable them when one runs ``yumdownloader 
>> --source $package'' to grab the source for an rpm.  But unlike most 
>> repositories, SL's source repository is called "sl-srpms" instead of 
>> "sl-source", so the program doesn't work correctly for anything in the 
>> SL base repositories.
>>
>> Is there some historical reason for SL's strange naming scheme?  Is it 
>> something that can change in a later release like 6.x?
> 
> I had no idea that naming the repository had any impact on any part of 
> yum.  It's sorta a bad hack in my opinion.  I would think that it would 
> actually look at the rpm's in question.
> 
> That being said, I have no problem renaming the source repositories.
> 
> Was it historic.  Yes.
> We said to ourselves
> "What should we name the repository for the source rpms?"
> "Well, they are always in a directory called SRPMS, let call it srpms."
> "But we should distinguish it so they know it's the Scientific Linux 
> source rpms."
> "OK, then let's call it sl-srpms"
> And there you have your historic moment. :)
> 
> I've never actually used yum and the source rpms.
> Does yum have any way of knowing that something is a src.rpm or not ... 
> other than a repostory name?
> (I've looked in the man page and I'm not seeing anything)

Yum recognizes a source rpm when it appears in a repository, but source 
repositories are always disabled because it is silly to download repo 
data for source repositories when sources are so rarely needed.  Since 
they are disabled, yum has no idea what packages are there because it 
has no repo data for them.  So when yumdownloader is asked to download a 
source rpm it has two choices:  it can enable every repository on the 
system, which uses a lot of extra time, memory, and bandwidth, and then 
try to find the source rpm it is looking for; or it can enable only some 
of the repositories based on what information it does have, which 
usually means names.  I agree, it is a sort of hack, but it is a 
necessary one that prevents yum from having to do a whole lot of extra 
work that can add minutes to the command's run time.

--
Garrett Holmstrom
University of Minnesota School of Physics and Astronomy
Systems Staff

ATOM RSS1 RSS2