Open Atry opened 2 years ago
Since we are now creating the Apt repository for universal deb packages, now we have a chance to revisit the convention for package names, versions and suites.
In brief, the package name should be always hhvm
, while the version of a hhvm
package might be either a dev version or a release version, and each version could belongs to one or more suites.
All deb packages should be named hhvm
, no matter if it is built nightly or released biweekly. The unified package name allows upgrading between different suites.
The deb package versions are different from the versions printed by hhvm --version
. Instead, they are adjusted to meet the algorithm described in https://manpages.debian.org/wheezy/dpkg-dev/deb-version.5.en.html
The version is always determined from version.h
in the code base, not from parameters passed to the build.
If the HHVM_VERSION_SUFFIX
is defined as "-dev"
in the code base, the deb package version should be major.minor.patch~dev%Y%m%d%H%M%S, where %Y%m%d%H%M%S is the commit time. For example: 4.199.0~dev20221231235959
.
If the HHVM_VERSION_SUFFIX
is defined as ""
in the code base, the deb package version should be major.minor.patch. For example: 4.199.0
.
Note that we choose tilde instead of hyphen, so that dpkg would consider a dev suffixed version as a smaller version than unsuffixed version, according to its sorting algorithm. We also choose commit time instead of nightly date to support version comparison between arbitrary commits.
The universal deb package built from HHVM-x.y.z
tag will have an unsuffixed version x.y.z. The deb package will be uploaded to the following suites:
If x.y is a LTS version, the deb package will be also uploaded to the following suite:
The universal deb package built from night-YYYY.MM.DD
tag will have a suffixed version. The deb package will be uploaded to the following suite:
The universal deb package built from other commits will not be uploaded to the Apt repository.
According to a private conversation with @fredemmott, the reason why the package names are different is to support installing both hhvm
and hhvm-nightly
on the same machine.
Unfortunately the ability to install both hhvm
and hhvm-nightly
from deb
packages is not super helpful because:
Note that the versioning in RPM 4.10.0 or higher also supports tilde: https://rpm.org/ticket/56
Currently we have
hhvm
andhhvm-nightly
named differently. However, they are not actually independent. We cannot install both:If you installed
hhvm
from the APT repository, then the attempt to installhhvm-nightly
would fail