From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6931066459248394240 X-Received: by 2002:adf:fe09:: with SMTP id n9mr27645908wrr.104.1614779372559; Wed, 03 Mar 2021 05:49:32 -0800 (PST) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a05:600c:2292:: with SMTP id 18ls1250820wmf.0.canary-gmail; Wed, 03 Mar 2021 05:49:31 -0800 (PST) X-Google-Smtp-Source: ABdhPJxO/m7c0yjbhPeDRQqLfHmwHh6AMzboGgz9RfmrNRIsHUBLMTFMiqjoULQOPHLSxSipJLQD X-Received: by 2002:a05:600c:2512:: with SMTP id d18mr9020144wma.55.1614779371606; Wed, 03 Mar 2021 05:49:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614779371; cv=none; d=google.com; s=arc-20160816; b=gpW98iohnPNIMEP0BDQhOZYtZKZ3ye5rkAv3E0f0XWec6aFP/OA5TIuUNQS4JPCUk0 W3OKqx067ky2TrhdajgHvJfN+RtWZQh4YjF/503ENMUj67ACk9yGFd11/Cks9DG0Cldn zOXrPfbGveNo4LIAOKkpjw06FzLUg7S4jXkTdxv4qRRQP8YWH/rvbLjJy+LfxiFINfhs O6VXeUbbq6alhRajc7SuiopAaS76WHeEr6x2ZsAJLU9iD4S3iCz/7uTNnFSWAUENyhX3 FutAZ3BYokp1rTs3kbjHUI9FE4JvjZOrrWYK9CZvBAuEz7BRsSRAgMICwp6I0SjMV+sE ZqVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:content-transfer-encoding:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:ironport-sdr:ironport-sdr; bh=g9EfQ1FN76D1noQp/dTBu33AvIFAL2TSuvgs45zKCpo=; b=h3ClrbdWyb7AyylAD2Gtl5swYIoJeMADYtrDH0qRpdSCQ8Oc0mZeUFqftFzc+IF/XT YtZ3yBY+kjHHhUeKMEVcwrmvIdJuCyAirZ+GNREAwGo8IqY4cRcgjKMzHD5e5l65xFYC Npo3hlPdlN6HX8tAuCVaXG4vM3UTu1Ie1Df8h8jDsUMK6MECyaB+ODrmwxC05wLd4uQG dZyddUtuTKqAytTQ2AjKJWOVy73N/ewZm7p5xFRpDE2rVtvQ2OYbJ9MLraHYapaBAU5T NZRNc6J54NG73oU30V416h6y/GRxn2RxNI/RxcprN0rXYfZFNa+08zh+hlzk/KV6RG8u LN3Q== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of vijaikumar_kanagarajan@mentor.com designates 68.232.137.180 as permitted sender) smtp.mailfrom=Vijaikumar_Kanagarajan@mentor.com Return-Path: Received: from esa3.mentor.iphmx.com (esa3.mentor.iphmx.com. [68.232.137.180]) by gmr-mx.google.com with ESMTPS id i22si377970wml.2.2021.03.03.05.49.30 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 03 Mar 2021 05:49:31 -0800 (PST) Received-SPF: pass (google.com: domain of vijaikumar_kanagarajan@mentor.com designates 68.232.137.180 as permitted sender) client-ip=68.232.137.180; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of vijaikumar_kanagarajan@mentor.com designates 68.232.137.180 as permitted sender) smtp.mailfrom=Vijaikumar_Kanagarajan@mentor.com IronPort-SDR: VEAOx4SyMT9q4Ujb5xBwXqj04daxCB05zVzhHMqexHUBtKD2O2PZ6BjomPqb8tQwztfu3zr4AG yuidX/ecRa0734ggIdO1I36sy56tgboKQeCRi65/NrqnUjxtjBwIhhkWUkSIW1jIguP6YF/UBG a1yEqB7jdqzY6DehHCyCwgkcW8r5h8971UdJtsTG6Q+mwohPbYejSRh1VJHBLkOfiZZkVm9Dk5 yZ4k9YsEwWNdh84iabX5GLAv7qxQ3Emf95FyOy2inTBFFNaKSd+mIoUoij6PRNMTHBd6Owc3sM E0k= X-IronPort-AV: E=Sophos;i="5.81,220,1610438400"; d="scan'208";a="58706500" Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa3.mentor.iphmx.com with ESMTP; 03 Mar 2021 05:49:29 -0800 IronPort-SDR: L3Fh4C+4Kf57f/FQB+lWKYeYEpsKl+jpsWp9+1hIl+gSXxJGDnviNNeItxr0Gw9CGvYEFSOar8 7+w4b3c6XfTPN3rCRLwYihlSIWPSoiabUoG8ZHU1dsDlNC+QqGRc+/oB+L8jvtMKlQpUrADadx SQZ1oFC7rBPL1Bcc4Zk2xs+zIbApq4GVa+jv0nJvlgePuoIpxx1ccieJfxILXs0OSiTWocH4Of yEv1ECqRqyt9e+GFE6NVFipeAYYAetX6WO8BL0SFbwLOwODjleWUuEmCwJtAXAY+INMECjEyT3 Upc= From: "Kanagarajan, Vijaikumar" To: Henning Schild , vijai kumar CC: isar-users , "ibr@radix10.net" , Silvano Cirujano Cuesta Subject: RE: [RFC PATCH 1/2] dpkg-base: Handle custom source directory in do_apt_fetch Thread-Topic: [RFC PATCH 1/2] dpkg-base: Handle custom source directory in do_apt_fetch Thread-Index: AQHXBvl9/6J/AVG/S0W4YxF2PUC/y6phNwwAgAMVCwCADoNKAP//ipGA Date: Wed, 3 Mar 2021 13:49:26 +0000 Message-ID: References: <20210219195719.29037-1-Vijaikumar_Kanagarajan@mentor.com> <20210219195719.29037-2-Vijaikumar_Kanagarajan@mentor.com> <20210220090734.60a591c2@md1za8fc.ad001.siemens.net> <20210303134912.4093145b@md1za8fc.ad001.siemens.net> In-Reply-To: <20210303134912.4093145b@md1za8fc.ad001.siemens.net> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [147.34.91.1] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-TUID: GIaGpQPAUDXp -----Original Message----- From: Henning Schild [mailto:henning.schild@siemens.com]=20 Sent: 03 March 2021 18:19 To: vijai kumar Cc: Kanagarajan, Vijaikumar ; isar-users= ; ibr@radix10.net; Silvano Cirujano Cuesta Subject: Re: [RFC PATCH 1/2] dpkg-base: Handle custom source directory in d= o_apt_fetch Can we please get this one stand-alone on the fast-path? Just ran into exac= tly the problem and now have to work around. Sure Henning. Will take this out and send a v2 tonight. regards, Henning Am Mon, 22 Feb 2021 12:41:40 +0530 schrieb vijai kumar : > On Sat, Feb 20, 2021 at 1:47 PM Henning Schild=20 > wrote: > > > > Am Sat, 20 Feb 2021 01:27:18 +0530 > > schrieb Vijai Kumar K : > > =20 > > > With the current do_apt_fetch implementation, it is not possible=20 > > > to use a custom source directory(${S}). > > > > > > apt-get source by default extracts the contents of the debian=20 > > > source into folder with name _. > > > > > > Add provision for specifying a custom source directory. =20 > > > > I think this one is indeed worth being discussed seperately. > > > > Could you go into detail why a custom S is required in the first=20 > > place? My guess is that we might not know PV and need to wait for=20 > > that apt-unpack to finish so we can find it in the changelog. >=20 > Exactly. In some cases we might not know PV, we might need to wait for=20 > apt to see what version it is fetching. Change the APT sources and or=20 > preferences and you might get a completely new version of the package.=20 > We cannot effectively know ${S} for manipulating the source code from=20 > the recipe. >=20 > > =20 > > > Signed-off-by: Vijai Kumar K > > > --- > > > meta/classes/dpkg-base.bbclass | 7 ++++++- > > > 1 file changed, 6 insertions(+), 1 deletion(-) > > > > > > diff --git a/meta/classes/dpkg-base.bbclass=20 > > > b/meta/classes/dpkg-base.bbclass index 5c7bddc..1b94b76 100644 > > > --- a/meta/classes/dpkg-base.bbclass > > > +++ b/meta/classes/dpkg-base.bbclass > > > @@ -70,7 +70,12 @@ do_apt_fetch() { > > > sudo -E chroot --userspec=3D$( id -u ):$( id -g )=20 > > > ${BUILDCHROOT_DIR} \ sh -c 'mkdir -p /downloads/deb-src/"$1"/"$2" > > > && cd /downloads/deb-src/"$1"/"$2" && apt-get -y --download-only=20 > > > --only-source source "$2"' my_script "${DISTRO}" "${uri}" sudo -E=20 > > > chroot --userspec=3D$( id -u ):$( id -g ) ${BUILDCHROOT_DIR} \ > > > - sh -c 'cp /downloads/deb-src/"$1"/"$2"/* ${PP} && cd > > > ${PP} && apt-get -y --only-source source "$2"' my_script=20 > > > "${DISTRO}" "${uri}" > > > + sh -c ' \ > > > + dscfile=3D"$(apt-get -y -qq --print-uris source > > > "${2}" | cut -d " " -f2 | grep -E "*.dsc")" > > > + cd ${PP} > > > + cp /downloads/deb-src/"${1}"/"${2}"/* ${PP} > > > + dpkg-source -x "${dscfile}" "${PPS}"' \ > > > + my_script "${DISTRO}" "${uri}" =20 > > > > You removed the && chaining, please try a "false" in there, i guess=20 > > that sh might need a -e now >=20 > Yes. Will add that in v2. >=20 > > > > I wonder if we can just symlink debians choice to PPS, or mv, or=20 > > even "cp -a" >=20 > Wondering whether it brings in any added advantage? >=20 > > And make that a new task we call apt_unpack >=20 > I thought about this too. We could definitely have something like=20 > apt_unpack that makes things clear. When I first started looking=20 > around, I didn't expect the unpacking to happen in fetch. >=20 > Thanks, > Vijai Kumar K >=20 > > > > Henning > > =20 > > > done > > > > > > dpkg_undo_mounts > > > > -- > > You received this message because you are subscribed to the Google=20 > > Groups "isar-users" group. To unsubscribe from this group and stop=20 > > receiving emails from it, send an email to > > isar-users+unsubscribe@googlegroups.com. To view this discussion on > > the web visit > > https://groups.google.com/d/msgid/isar-users/20210220090734.60a591c2%40= md1za8fc.ad001.siemens.net. > > =20 >=20