pve-manager/PVE/pvecfg.pm.in
Thomas Lamprecht 180a86d39a pvecfg: adapt version and release semantic
Wit commit a74ba607d4b02c5734c5480de62700f52f96ac71 we switched over
to using the dpkg-dev provided helpers to set package version,
architecture and such in the buildsystem.

But unlike other repositories we used the version also for giving it
back over the API through the during build generated PVE::pvecfg
module, which wasn't fully updated to the new style.

This patch does that, and also cleans up semantics a bit, the
following two changed:

release is now the Debian release, instead of the "package release"
(i.e., the -X part of a full package version).
version is now simply the full (pve-manager) version, e.g., 6.0-1 or
the currently for testing used 6.0-0+1

This allows to do everything we used this information for even in a
slightly easier way (no  string concat needed anymore), and fits also
with the terminology we often used in our public channels (mailing
lists, forum, website)

Remove some cruft as we touch things.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2019-05-26 16:11:43 +02:00

36 lines
425 B
Perl

package PVE::pvecfg;
use strict;
use warnings;
sub package {
return '@PACKAGE@';
}
sub version {
return '@VERSION@';
}
sub release {
return '@PVERELEASE@';
}
sub repoid {
return '@REPOID@';
}
sub version_text {
return '@VERSION@/@REPOID@';
}
# this is returned by the API
sub version_info {
return {
'version' => '@VERSION@',
'release' => '@PVERELEASE@',
'repoid' => '@REPOID@',
}
}
1;