From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 7278939938131804160 X-Received: by 2002:adf:f9ce:0:b0:317:55c:4936 with SMTP id w14-20020adff9ce000000b00317055c4936mr8158423wrr.9.1695715189255; Tue, 26 Sep 2023 00:59:49 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:adf:de92:0:b0:31f:ebf1:ed8 with SMTP id w18-20020adfde92000000b0031febf10ed8ls2330552wrl.2.-pod-prod-07-eu; Tue, 26 Sep 2023 00:59:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHoUkck0gScfQ5gOeUw5+4LyqV7g7VNCm2vdQfx79Uqpa2Qr5pMxOlVlJvZexAVNVaI8POW X-Received: by 2002:a05:600c:b55:b0:400:57d1:4913 with SMTP id k21-20020a05600c0b5500b0040057d14913mr8755392wmr.9.1695715187036; Tue, 26 Sep 2023 00:59:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695715187; cv=none; d=google.com; s=arc-20160816; b=ByNTqRAQeLQXoe9ckjjPmqXvtKF705bkXo1aw5rhzWwRZT4Rrdf6VWR2vLdm0ByxLY 7IL2owdBjkxuYX5orCvFXbVf1ewIQglVAi+GCJ94S6n+M1IzVYPyqp5wkoKxPO1L8nou HdUlmJz8Qlhi2GFraJmy+IzyTXqjF6+YKIBypOX7ejBt1MffDK9nsFpiZboscYrNtXih O45NgithsrFJr2MInPa0YqwTokOdielBmHmVyb8tCxdUzVi0curxZl2DrqRtjrCgiJjP P8HoB3LUFC9FD0tuBhDUeUOcNuszjzblu9n5ROasQM8vsf0GwtWYAjBeLqvqPh44hDGa qiyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id; bh=se68g52iHuqYgWkPzdO0pBvBEIUsONptRReV4e2px54=; fh=O+ZMFUiiuyZKsfz7Fw8hsdknZlxcSFSsLsCydBEGD0o=; b=jOCUvmqaEpGeShH4qQCgXjRzvvLBrN5iHdEzRvHqdsv2lRJ9cgavzl5kqul0RyV9DX dsU37Kufo9k1DsA/gVsn9ou+cpKJO98yUcpoTc9byNcxZ0dXx18qdIF4rf0sWKO8KRHX HJ8hQH4TprzauvvGNeVOZ+U7qE79FLVHd+BF3rgsOQlj+EKYv0H4bYaYZpEjGIChRBQL QEOYRBNJbstxjtueosnSLN7DYfi16Asn/C/2Iqj6OPhKzrdjY2WUTK1Lg9iXaC+5zQgQ hydH0lk/JmNRWeh+3iexZL2jCk+2TTjYk4TE2ei7ymX364T74hPK7+hviEbHxNj4q/oZ Rduw== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=ubely@ilbers.de Return-Path: Received: from shymkent.ilbers.de (shymkent.ilbers.de. [85.214.156.166]) by gmr-mx.google.com with ESMTPS id bh20-20020a05600c3d1400b003fef434e6a5si82531wmb.0.2023.09.26.00.59.46 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 26 Sep 2023 00:59:46 -0700 (PDT) Received-SPF: pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) client-ip=85.214.156.166; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of ubely@ilbers.de designates 85.214.156.166 as permitted sender) smtp.mailfrom=ubely@ilbers.de Received: from [127.0.0.1] (host-80-81-17-52.static.customer.m-online.net [80.81.17.52]) (authenticated bits=0) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPSA id 38Q7xjp8018072 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 26 Sep 2023 09:59:46 +0200 Message-ID: <70a2540801d732a0f0463bcc199c2f474b0e2919.camel@ilbers.de> Subject: Re: [PATCH v4 03/13] kas: Add mirror selection From: Uladzimir Bely To: Jan Kiszka , isar-users@googlegroups.com Date: Tue, 26 Sep 2023 10:59:47 +0300 In-Reply-To: <733a44b2-5f56-429a-aa6c-701e74f51cbd@siemens.com> References: <20230922091003.20763-1-ubely@ilbers.de> <20230922091003.20763-4-ubely@ilbers.de> <37f46918-9d42-42f8-82ed-2158c2459fb9@siemens.com> <733a44b2-5f56-429a-aa6c-701e74f51cbd@siemens.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.48.4 (by Flathub.org) MIME-Version: 1.0 X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-TUID: 29qsclM8N1S2 On Mon, 2023-09-25 at 16:49 +0200, Jan Kiszka wrote: > On 25.09.23 16:38, Uladzimir Bely wrote: > > On Mon, 2023-09-25 at 13:34 +0200, Jan Kiszka wrote: > > > On 22.09.23 11:09, Uladzimir Bely wrote: > > > > This allows to select better (faster) mirror for Debian and > > > > Ubuntu > > > > distributions. > > > >=20 > > > > Isar DISTRO_APT_PREMIRRORS is used under the hood. > > > >=20 > > > > Signed-off-by: Uladzimir Bely > > > > --- > > > > =C2=A0Kconfig=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2=A0 1 + > > > > =C2=A0kas/opt/Kconfig=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0 | 42 > > > > ++++++++++++++++++++++++++++++++++++++ > > > > =C2=A0kas/opt/mirror-debian.yaml | 10 +++++++++ > > > > =C2=A0kas/opt/mirror-ubuntu.yaml | 10 +++++++++ > > > > =C2=A04 files changed, 63 insertions(+) > > > > =C2=A0create mode 100644 kas/opt/Kconfig > > > > =C2=A0create mode 100644 kas/opt/mirror-debian.yaml > > > > =C2=A0create mode 100644 kas/opt/mirror-ubuntu.yaml > > > >=20 > > > > diff --git a/Kconfig b/Kconfig > > > > index 591fe765..a62fbf6c 100644 > > > > --- a/Kconfig > > > > +++ b/Kconfig > > > > @@ -16,3 +16,4 @@ config KAS_BUILD_SYSTEM > > > > =C2=A0 > > > > =C2=A0source "kas/distro/Kconfig" > > > > =C2=A0source "kas/machine/Kconfig" > > > > +source "kas/opt/Kconfig" > > > > diff --git a/kas/opt/Kconfig b/kas/opt/Kconfig > > > > new file mode 100644 > > > > index 00000000..06a9e3e5 > > > > --- /dev/null > > > > +++ b/kas/opt/Kconfig > > > > @@ -0,0 +1,42 @@ > > > > +# This software is a part of ISAR. > > > > +# Copyright (C) 2023 ilbers GmbH > > > > +# > > > > +# Authors: > > > > +#=C2=A0 Uladzimir Bely > > > > + > > > > +menu "Mirror selection" > > > > + > > > > +config MIRROR_DEBIAN > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0bool "Use specific Debia= n mirror" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0depends on DEBIAN_BUSTER= || DEBIAN_BULLSEYE || > > > > DEBIAN_BOOKWORM > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0help > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 Select better loc= al Debian mirror instead of > > > > deb.debian.org > > > > + > > > > +config MIRROR_DEBIAN_URL > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0string "URL of Debian mi= rror" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0default "http://deb.debi= an.org" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0depends on MIRROR_DEBIAN > > > > + > > > > +config KAS_INCLUDE_MIRROR_DEBIAN > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0string > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0default "kas/opt/mirror-= debian.yaml" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0depends on MIRROR_DEBIAN > > > > + > > > > + > > > > +config MIRROR_UBUNTU > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0bool "Use specific Ubunt= u mirror" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0depends on UBUNTU_FOCAL = || UBUNTU_JAMMY > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0help > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 Select better loc= al Ubuntu mirror instead of > > > > archive.ubuntu.com > > > > + > > > > +config MIRROR_UBUNTU_URL > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0string "URL of Ubuntu mi= rror" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0default "http://archive.= ubuntu.com" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0depends on MIRROR_UBUNTU > > > > + > > > > +config KAS_INCLUDE_MIRROR_UBUNTU > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0string > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0default "kas/opt/mirror-= ubuntu.yaml" > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0depends on MIRROR_UBUNTU > > > > + > > > > +endmenu > > >=20 > > > This menu looks strangely empty when selecting sid[-ports]. Maybe > > > make > > > it !depend on that or depend on supported distros? > > >=20 > >=20 > > Do you mean, hide complete menu if sid-ports/raspbian selected? >=20 > Yep. >=20 > >=20 > > I also got an idea - not about mirrors, but in general... Maybe, > > instead of always thinking on dependencies between distro and > > machine - > > we could simply replace it with multiconfig selection? > >=20 > > E.g., in one menu we could simply list all possible multiconfigs. > > And, > > even select several of them for the build simulaneously. >=20 > Also possible. Only similar case I'm aware of (for whatever reason): > https://github.com/siemens/jailhouse-images/blob/master/Kconfig >=20 > Jan >=20 Send v5 where "mirrors" menu is hidden if non-debian/ubuntu distro selected. Regarding multiconfig support. I've acutally prepared some work-in-progress solution. It allows to select several "multiconfig" items additionally to what user selected in "distro" and "machine" menus. But it currently does not enable required options depending on distro/machine. E.g., if user selected "ubuntu" as distro, only URLS related for ubuntu are shown in "mirrors" menu, even if some "debian" multiconfigs are selected. Another moment is that supporting multiconfigs makes "distro" and "machine" menus a bit redundant. We could simply remove them and even get some benefits from this: - we should not care about implementing distro/machine dependency logic in Kconfig - we simply use those multiconfigs we support in Isar - user can see all possible configurations in one place and they are not confused by missing hardware targets in the menu (if wrong distro chosen for now). So, we have several options: 1. Leave and merge it as is and don't add multiconfigs for now. 2. Add multiconfigs and keep distro/machine and all this dependency logic in menu. 3. Add multiconfigs as a replacement of distro/machine menus. =20 For me, the third looks a bit more reasonable.