[pacman-dev] Package name and version check
ngaba at bibl.u-szeged.hu
Sat Dec 15 06:45:22 EST 2007
I refer to this thread:
Well, I agree with Dan and Aaron, quote:
"Maybe I want my packages just named pkgname.lol".
However, I don't see the clear rules, where (pkgname,pkgver) comes
from in case of repos.
I would like make a little comment here:
Packages in sync (and local) dbs are identified by their directory
names, not by %NAME% and %VERSION% in desc (reason: speed-up): see line
220 in be_files.c:
if(_alpm_db_splitname(ent->d_name, pkg->name, pkg->version) != 0)...
So we should make sure, that directory name contains the valid %NAME%
and %VERSION% (or %NAME% and %VERSION% is not needed in desc)
And of course %FILENAME% should point to a package with the correct
%NAME% and %VERSION% <- we may want to check the .PKGINFO content of
the (downloaded) pointed file, not the filename itself. However, I'm not
sure if this is needed: then we should also check %DEPENDS%, %PROVIDES%
and other fields... (checkdeps might have been fooled for example)
More information about the pacman-dev