> On Feb 12, 2021, at 5:31 PM, tech-lists <tech-lists at zyxst.net>
wrote:
> As subject, where to get sources for 12-stable upgrade now? Is it still
> svn or is it git?
tl;dr: git is the source of truth, but there?s a bunch of details that might
matter.
The current source of truth is git repository on gitrepo.freebsd.org. It is the
canonical repo for the project. A very close copy can be found at
cgit.freebsd.org (it usually lags by the time it takes to copy new commits over
to it, usually some small number of seconds). All other sources are derived from
these.
The subversion repo was the source of truth for FreeBSD between the time it was
adopted until git replaced it late last year. Prior to using subversion, CVS was
the source of truth. The CVS repository was retired when we did the conversion
to subversion. For the life of the stable/11 and stable/12 branches (and any
releng branches from those), we will be mirroring commits to those branches to
the subversion repository. When we were doing the conversion, we often heard
that changing VCS mid-branch would be too burdensome and would really go against
the branch stability guarantees we have.
The svn mirroring service should be a faithful reflection of the git source of
truth. Or is modulo bugs and semantic differences in the different VCS. If
there?s a discrepancy, then git is authoritative. There will be a lag between
what?s committed to git and its appearance in svn mirrors because the mirroring
is done via a cron job and there?s propagation delays. Since subversion has
different semantics, it expands the $FreeBSD$ keywords in the source, while git
does not (and cannot in a meaningful way). This will result in a difference
between trees checked out in one versus the order. Normally, this difference is
inconsequential, though some folks may need it for various reasons.
There?s a small wrinkle with any 12.x releases. Those will be built out of the
subversion mirror of the git source of truth. We?re doing this to continue the
$FreeBSD$ expansion through the life of the 12.x branch. This will result in a
slightly different build for the non-reproducible builds when one builds out of
subversion vs out of git. Should there be a difference between the svn sources
and git sources, say due to a bug in the mirroring or the $FreeBSD$ expansion
being meaningful, this can lead to some confusion. If this is a material
difference, an updated would be issued right away to correct it. And in this
case, the source of truth is still the git repo, it?s just been transformed in
various ways before landing in the source artifacts that are used to create a
release.
In many ways the little difference have long been accepted. The tree you get
from the old CVS repo differed from the tree you?d get from the same version
post conversion to svn from the svn repo because of semantic differences in how
$FreeBSD$ was expanded. You could never checkout a 2.1 release from subversion
and get exactly the sources that phk used to build the 2.1.0 release because CVS
expanded the keywords as $FreeSBD: foo.c 1.7$ and svn expanded them $FreeBSD:
path/to/file/foo.c 3255$. This is muddied a bit further with the git conversion
since the sources on the ISO images were used to recreate the 1.x series of
releases. There may also be some early tags that haven?t made it through all the
conversion processes...
Even the git repo copies that are mirrored out differ slightly in that they
publish a slightly abridged version. GitHub?s interface does not like having
~10k entries in it for the ?branch? menu. So we don?t publish vendor branches to
GitHub because of how the subversion repo vendor branches and tags were
converted lead to too many branches for GitHub to be happy. This information is
available from gitrepo.freebsd.org, however.
Warner