From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6761340396568051712 X-Received: by 2002:ac2:4102:: with SMTP id b2mr19708033lfi.16.1574663903023; Sun, 24 Nov 2019 22:38:23 -0800 (PST) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a05:651c:289:: with SMTP id b9ls2213236ljo.10.gmail; Sun, 24 Nov 2019 22:38:22 -0800 (PST) X-Google-Smtp-Source: APXvYqwA0fl6q+rT0MbwoT5d774I4inG8/iykKlB6F2xsmn0+MtmqMNleYl5Mn4wc9o+jJDQPnOv X-Received: by 2002:a2e:478a:: with SMTP id u132mr20787776lja.181.1574663902152; Sun, 24 Nov 2019 22:38:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1574663902; cv=none; d=google.com; s=arc-20160816; b=WWrsdVSxPylHRTLorXhHEVFRGqCJPGctV3w0WA4D23OOKeKi5F0nd/Rqi1MjKz1j0a WNEVQU/CxS/nABDbLkUiAbJsI4E8ad55gRGvcPPz52/Aj6SIPPk0lOBqRTLfQHDK0okv pUzkbVHlyaR1+It7PcyqCqmj5x19PeP5wgkyNoyV2WdR9AWAnuud5WbxmwLeB9imZOA/ LngQUFG2DoFEdxIqhjdojDjn5a7mT+ev91Eah3Nqknns12UojJhP6Xn9VTeqJboaZ02X rnm1ZP99cqcfaP40sNflPNEkeV2dtFBSAiCsjDR8/wkNTzKa9zdisC2qBqOdSaKLk7cV FKaQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:content-language:in-reply-to:mime-version :user-agent:date:message-id:from:references:cc:to:subject; bh=pdU3bQCzl0qGZfQpnmAD8RiDovNqBaiKQ0HuLAlb9PM=; b=mTgoWNRTTAOQclBHYLZOVe4Ywoj+rsB65R07flRnEtNe5KOJ3FX49kjiCndHFyr4oT wVz+kAT4PjyvO0BRhzCd9ZQ8z1n5SkKauULeRere73m1xw9O3beHM8XsdurxuuiwEhRh AkKWJcO64mnA7MG3LiaUCkOVU/RzAJlUuZRvwwkeTmCNhvycmOgtWxJw4I3Hl0y4CDIx V61ARONnORijuPVcfPPQMpQibCJxvebbB475r6nZNQNsq75qIkVPOZOKXhiThitbWBrC WbUV5YXv7IH34qzlzowP4lh402Vto/jndHCle3+WYglZtdq/rO4Xl9JJO01OtzhKUk/c d3Ug== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of jan.kiszka@siemens.com designates 192.35.17.14 as permitted sender) smtp.mailfrom=jan.kiszka@siemens.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=siemens.com Return-Path: Received: from david.siemens.de (david.siemens.de. [192.35.17.14]) by gmr-mx.google.com with ESMTPS id z18si209871lfh.1.2019.11.24.22.38.21 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 Nov 2019 22:38:22 -0800 (PST) Received-SPF: pass (google.com: domain of jan.kiszka@siemens.com designates 192.35.17.14 as permitted sender) client-ip=192.35.17.14; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of jan.kiszka@siemens.com designates 192.35.17.14 as permitted sender) smtp.mailfrom=jan.kiszka@siemens.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=siemens.com Received: from mail1.sbs.de (mail1.sbs.de [192.129.41.35]) by david.siemens.de (8.15.2/8.15.2) with ESMTPS id xAP6cKfA004411 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 25 Nov 2019 07:38:21 +0100 Received: from [167.87.38.251] ([167.87.38.251]) by mail1.sbs.de (8.15.2/8.15.2) with ESMTP id xAP6cKsR004882; Mon, 25 Nov 2019 07:38:20 +0100 Subject: Re: [PATCH v2] isar-bootstrap: Clear local apt state information To: vijaikumar.kanagarajan@gmail.com, isar-users@googlegroups.com Cc: henning.schild@siemens.com, ibr@radix50.net, Vijai Kumar K References: <20191121095401.GA15048@oxygen> <20191121100532.8491-1-Vijaikumar_Kangarajan@mentor.com> From: Jan Kiszka Message-ID: Date: Mon, 25 Nov 2019 07:38:18 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.1 MIME-Version: 1.0 In-Reply-To: <20191121100532.8491-1-Vijaikumar_Kangarajan@mentor.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-TUID: aQ2pp81cjJ6B On 21.11.19 11:05, vijaikumar.kanagarajan@gmail.com wrote: > From: Vijai Kumar K > > Debootstrap's second stage switches to using the default debian mirror. > But the apt state information is renamed and used from the first stage. > This might cause apt-get update to fail with the below error when the > sources list contain both custom and upstream repos. > > | Reading package lists... > | E: Failed to fetch http://deb.debian.org/debian/dists/stretch/InRelease \ > | Unable to find expected entry 'contrib/source/Sources' in Release file \ > | (Wrong sources.list entry or malformed file) > > Clear the apt state information before apt-get update. > > Signed-off-by: Vijai Kumar K > --- > Changes in v2: > - Addressed review comments from Henning. > > meta/recipes-core/isar-bootstrap/isar-bootstrap.inc | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc b/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc > index d614d9a..9096775 100644 > --- a/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc > +++ b/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc > @@ -280,6 +280,7 @@ isar_bootstrap() { > install -v -m644 "${APTSRCS_INIT}" \ > "${ROOTFSDIR}/etc/apt/sources-list" > rm -f "${ROOTFSDIR}/etc/apt/sources.list" > + rm -rf "${ROOTFSDIR}/var/lib/apt/lists/"* Normally, you would put the wildcard inside the quotes. Jan > mkdir -p "${ROOTFSDIR}/etc/apt/apt.conf.d" > install -v -m644 "${WORKDIR}/isar-apt.conf" \ > "${ROOTFSDIR}/etc/apt/apt.conf.d/50isar.conf" > -- Siemens AG, Corporate Technology, CT RDA IOT SES-DE Corporate Competence Center Embedded Linux