Gentoo Archives: gentoo-dev

From: Francesco Riosa <vivo75@×××××.com>
To: gentoo development <gentoo-dev@l.g.o>
Subject: Re: [gentoo-dev] New project: binhost
Date: Tue, 16 Feb 2021 01:37:49
Message-Id: CAD6zcDxZH8aJjybUNBWQqzJt_u9+SniRa9Y9OV9VCy-qpbNBbw@mail.gmail.com
In Reply to: Re: [gentoo-dev] New project: binhost by "Andreas K. Hüttel"
1 Il giorno mer 10 feb 2021 alle ore 20:15 Andreas K. Hüttel <
2 dilfridge@g.o> ha scritto:
3
4 > > Some ideas for portage enhancements:
5 > >
6 > > 1. Ability to fetch binary packages from some kind of repo.
7 > > 2. Ability to have multiple binary packages co-exist in a repo (local
8 > > or remote) with different build attributes (arch, USE, CFLAGS,
9 > > DEPENDS, whatever).
10 > > 3. Ability to pick the most appropriate binary packages to use based
11 > > on user preferences (with a mix of hard and soft preferences).
12 >
13 > The more definite answer should come from Zac, but I think a good part of
14 > this
15 > is already implemented. :)
16 >
17 > kind of, from make.conf manpage:
18
19 binpkg-multi-instance
20
21 Enable support for multiple binary package in‐
22 stances per ebuild. Having multiple instances is
23 useful for a number of purposes, such as retaining
24 builds that were built with different USE flags or
25 linked against different versions of libraries.
26 The location of any particular package within
27 PKGDIR can be expressed as follows:
28
29 ${PKGDIR}/${CATEGORY}/${PN}/${PF}-${BUILD_ID}.xpak
30
31 The build-id starts at 1 for the first build of a
32 particular ebuild, and is incremented by 1 for
33 each new build. It is possible to share a writable
34 PKGDIR over NFS, and locking ensures that each
35 package added to PKGDIR will have a unique
36 build-id. It is not necessary to migrate an exist‐
37 ing PKGDIR to the new layout, since portage is ca‐
38 pable of working with a mixed PKGDIR layout, where
39 packages using the old layout are allowed to re‐
40 main in place.
41
42 The new PKGDIR layout is backward-compatible with
43 binhost clients running older portage, since the
44 file format is identical, the per-package PATH at‐
45 tribute in the 'Packages' index directs them to
46 download the file from the correct URI, and they
47 automatically use BUILD_TIME metadata to select
48 the latest builds.
49
50 There is currently no automated way to prune old
51 builds from PKGDIR, although it is possible to re‐
52 move packages manually, and then run 'emaint --fix
53 binhost' to update the ${PKGDIR}/Packages index.