From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mout.kundenserver.de ([217.72.192.74]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1i5Drh-0005De-1n for ptxdist@pengutronix.de; Tue, 03 Sep 2019 20:49:17 +0200 Received: from methusalix.home.lespocky.de ([92.117.63.0]) by mrelayeu.kundenserver.de (mreue106 [212.227.15.183]) with ESMTPSA (Nemesis) id 1MWSJJ-1hgmBc3zdj-00XwVc for ; Tue, 03 Sep 2019 20:49:16 +0200 Received: from falbala.home.lespocky.de ([192.168.243.94]) by methusalix.home.lespocky.de with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92) (envelope-from ) id 1i5Drd-0005v8-D7 for ptxdist@pengutronix.de; Tue, 03 Sep 2019 20:49:14 +0200 Date: Tue, 3 Sep 2019 20:49:12 +0200 From: Alexander Dahl Message-ID: <20190903184911.36dxo6xv7covqf6d@falbala.home.lespocky.de> References: <20190903115025.5007-1-ada@thorsis.com> <2446051.fMRPiYAuoM@ada> <20190903130808.vg6cxfnhx23kh5uw@pengutronix.de> <1795891.LWLpe0IM0S@ada> <20190903142255.hxisijxauvyb46b7@pengutronix.de> MIME-Version: 1.0 In-Reply-To: <20190903142255.hxisijxauvyb46b7@pengutronix.de> Subject: Re: [ptxdist] [RFC PATCH] doc: Add section on creating new layers List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Content-Type: multipart/mixed; boundary="===============1090527093==" Errors-To: ptxdist-bounces@pengutronix.de Sender: "ptxdist" To: ptxdist@pengutronix.de --===============1090527093== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="bzfj5o7wyh7i4ykd" Content-Disposition: inline --bzfj5o7wyh7i4ykd Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hello Michael, I tried a little more: mkdir DistroKit-rpi1 cd DistroKit-rpi1 ln -s ../DistroKit base The new layer is almost empty so far, see below. On Tue, Sep 03, 2019 at 04:22:55PM +0200, Michael Olbrich wrote: > On Tue, Sep 03, 2019 at 03:48:17PM +0200, Alexander Dahl wrote: > > Am Dienstag, 3. September 2019, 15:08:08 CEST schrieb Michael Olbrich: > > > If there is just on platform, then ptxdist will just use that on if no > > > selected_platformconfig exists. This is especially useful with layers, > > > because it will then just pick the config from the first layer that h= as > > > one. > >=20 > > So this is not different to ptxdist behaviour without layers. Maybe Dis= troKit=20 > > is no good example, because it contains more than one platform and you = must=20 > > select one to get going? >=20 > Correct. You need to select one (or run ptxdist with --platformconfig=3D.= =2E.). > Once ptxdist has crated a platformconfig for the new layer, you need to > select that one. PTXdist will complain if you forget this step. Indeed! Because there was no platformconfig in my new layer, I selected the platformconfig from the base layer: ptxdist platform base/configs/platform-rpi/platformconfig > > > It does not touch the selected_* links you might need to change those= if it > > > happens. > >=20 > > So the question remains. If there is more than one platform or config, = where=20 > > should it be selected best and how? >=20 > Only selections in the current layer are used. Anything else is ignored. > And PTXdist enforces that the selected config is from the top layer (if t= he > config exists there) or the next layer that contains it. "Enforces" does not mean it changes the platfrom selection by itself automatically, but just checks and bails out in case. For example, after selecting the platformconfig in the base layer before, I changed something in the platformconfig, which leads to ptxdist creating a platformconfig file in my new layer. Now ptxdist stops like this: alex@lemmy ~/src/DistroKit-rpi1 % p -q -j6 go ptxdist: error: The selected config file: ptxdist: error: DistroKit-rpi1/base/configs/platform-rpi/platformconfig ptxdist: error: is overwritten by: ptxdist: error: DistroKit-rpi1/configs/platform-rpi/platformconfig ptxdist: error: The config file in the outer layer must be used! error: error during generation of dependencies ptxdist: error: error in dgen The error message is clear, I have to select the platform in my upper layer now. Okay, did that. Now I changed something in my platformconfig to make it equal to the platformconfig of the lower layer again. This leads to ptxdist removing the platformconfig from the upper layer (just keeping platformconfig.old), I have a symlink 'selected_platform' to a non existent file and ptxdist bails out like this: alex@lemmy ~/src/DistroKit-rpi1 % p -q -j6 go = =20 error: 'selected_platformconfig' is missing try 'ptxdist platform ' All in all, one has to take care a little and reset the selected platform if ptxdist complains, but ptxdist either seems to build or print what's wrong, so it's not that hard to find out, which platform to select. I'll see what I can do with that information, to improve the documentation or the patch, if nobody else wants to jump in. Greets Alex --=20 /"\ ASCII RIBBON | =BBWith the first link, the chain is forged. The first \ / CAMPAIGN | speech censured, the first thought forbidden, the X AGAINST | first freedom denied, chains us all irrevocably.=AB / \ HTML MAIL | (Jean-Luc Picard, quoting Judge Aaron Satie) --bzfj5o7wyh7i4ykd Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEwo7muQJjlc+Prwj6NK3NAHIhXMYFAl1utaMACgkQNK3NAHIh XMYaWBAAn1lFSLM/7lwQ/TcfuSD4TgU3SQSA/FzjyP4RkEcvUslWd2sACxhmtI6s W2p4Q0Q3SwjrRcaDLavky9XKFL1AeeTum0GcY/J1b1lRbMJAi/iSHen5laVWbUCB xgTciBhKPsNaJh9ETwrfy4b+J4UkHHoHR+4A9kWEipOsZTg1SXragxbzC3jW2put fTgSDfCWXWpQ/fb00jiiB491KeWEvRgbCaXkhDLT27N6WJylwlKw60cB2eepyAmy oyTqr3hISaeNjtQUm8KeISikl1yCQ1ZsH0WCLj75ugfRc/0vFVePPChG07QsRpdb /NWdGISZUpm+oyiM4ywGobTOzGuVD0vE090ke8fKhqrJ11+CdxG3BIiHqduxQ9O6 CsvTViX+jVM/xHHN7e6+XcDaxlglABMSgqe6hpFAiBxeyBOKMOb8dQesztLpko4E Pr9+IYSTCSrxw6DK0LitSffZs/kX5j7al4PezIilsrjdEzZbDWlE2mE62qKwEZVu tOYqXJHwq4SnyrfsE4GYIa5Pu8ilz0Obr3q5IKiGrPNm/QKucJoHg9rnxX9whYIt Kf1pNEzNtyaY/lQXNzOz6IrUhyuUY78GEuWMYvJiUGRyRNGXVY26UP22HmaUwpzD vwMKKEoyupXfGbVSXUfaBBaPTlP483YSlGVHYtitIOi425kDB74= =IXpv -----END PGP SIGNATURE----- --bzfj5o7wyh7i4ykd-- --===============1090527093== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ptxdist mailing list ptxdist@pengutronix.de --===============1090527093==--