Package name separators
Guilherme Manika
gwm at conectiva.com.br
Tue Jul 25 05:22:23 PDT 2000
On Tue, Jul 25, 2000 at 04:08:02AM -0400, Jim Knoble wrote:
> Programs that deal with package specifications (name-version-release)
> directly pretty much do what the following awk scriptlet describes:
> awk -F '-' '{
> if (NF < 3) {
> printf("Bad package specification: \"%s\"\n", $0)
> } else {
> printf("name=\"%s", $1)
> for (i = 2; i < (NF - 1); i++) {
> printf("-%s", $i)
> }
> printf("\"")
> printf(" version=\"%s\"", $(NF - 1))
> printf(" release=\"%s\"\n", $NF)
> }
> }'
Maybe programs do this kind of thing, but they really shouldn't. A RPM may
have any name it wishes, and %{name}-%{version}-%{release}.%{arch}.rpm
is simply the default. Packages may be renamed after generated, or
you could redefine your system's %_rpmfilename macro to something
else.
Relying on the file name is wrong.
- gwm
More information about the lsb-discuss
mailing list