On l�rdagen den 10 augusti 2002 14.05 Ben Reser wrote:
> On Sat, Aug 10, 2002 at 03:28:50PM -0400, Oden Eriksson wrote:
> > This was very simple and strips down the spef file a great deal, I'm
> > impressed!. But..., I think there's a limit of 255 characters that you
> > can have on one line. Aslo it doesn't provide the /usr/bin/webalizer
> > binary for each package, only the softlinks.
>
> Quite possible.  But if there was some sort of limit I was running into
> it would error out because the for loop would be closed with a "done."
> However, I do believe the output is limited to 4K that rpm can capture.
> But for this sort of thing that probably isn't an issue.  If the line
> length ever did become an issue we could move the script into a separate
> file referenced as a source.  Which took params for whatever info it
> needed (e.g. %lang) and then could be run something like this:
> %(SOURCE2 %lang)

Ok, I will try to look into this later. Thank you very much for the tip.

> Sure it provides the webalizer binary:
> [root@occipital i586]# rpm -qpl webalizer-russian-2.01.10-5mdk.i586.rpm
> /usr/bin/webalizer-russian
>
> And after install:
> [root@occipital i586]# ls -l /usr/bin/weba*
> lrwxrwxrwx    1 root     root           17 Aug 10 10:56
> /usr/bin/webalizer -> webalizer-russian*
> -rwxr-xr-x    1 root     root       130904 Aug  9 16:52
> /usr/bin/webalizer-english*
> -rwxr-xr-x    1 root     root       132632 Aug  9 16:52
> /usr/bin/webalizer-russian*
> lrwxrwxrwx    1 root     root           17 Aug 10 10:56
> /usr/bin/webazolver -> webalizer-russian*
>
> The only other way to do it is to rename the file to webalizer in the
> actually package.  But then all the languages would have to conflict
> with each other.

Yes, they would conflict... I guess I just leave the package as is. Maybe with 
a session aware wrapper that does the softlinking depending on what language 
you feed it with.

> > As I come to think of it we also have another package "snort" in main
> > that would also benefit from this if we come up with a solution.
>
> I could take a look at this...
>
> > Maybe like this if it was possible:
> >
> > %install -n webalizer-swedish
> > bla bla bla
> >
> > %install -n webalizer-german
> > bla bla bla
> >
> > If this was possible I think we would have found the solution.
>
> I'm not sure I follow what you want here.  If you mean to package the
> webalizer-german so it's actually /usr/bin/webalizer well then you run
> into packages with conflicting files.  To me symlinking is the better
> option.  Probably the best thing to do would be to use the
> update-alternatives system.  This would let everyone install more than
> one language if that's what they wanted but they could switch back and
> forth.  IMHO it's better not to stop people from doing something but to
> do things in a way that's less restrictive if at all possible.  :)

What I meant here was that the install macro itself would install into a 
different buildroot or something. And yes we would have conflicting binaries 
but that's not the point. I just want to know how to do this.

-- 
Regards // Oden Eriksson
Deserve-IT Networks -> http://d-srv.com

Reply via email to