From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from dude02.hi.pengutronix.de ([2001:67c:670:100:1d::28] helo=dude02.lab.pengutronix.de) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jHoyR-0002SA-4b for ptxdist@pengutronix.de; Fri, 27 Mar 2020 14:24:35 +0100 Received: from mol by dude02.lab.pengutronix.de with local (Exim 4.92) (envelope-from ) id 1jHoyQ-0005c5-SN for ptxdist@pengutronix.de; Fri, 27 Mar 2020 14:24:34 +0100 Date: Fri, 27 Mar 2020 14:24:34 +0100 From: Michael Olbrich Message-ID: <20200327132434.GA32583@pengutronix.de> References: <20200227144449.29660-1-ada@thorsis.com> <20200227144449.29660-2-ada@thorsis.com> <20200320113105.GA7533@pengutronix.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20200320113105.GA7533@pengutronix.de> Subject: Re: [ptxdist] [PATCH 1/3] opkg: Regenerate config after input variable changes List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ptxdist-bounces@pengutronix.de Sender: "ptxdist" To: ptxdist@pengutronix.de On Fri, Mar 20, 2020 at 12:31:05PM +0100, Michael Olbrich wrote: > On Thu, Feb 27, 2020 at 03:44:47PM +0100, Alexander Dahl wrote: > > Some values in `/etc/opkg/opkg.conf` are replaced by 'install_replace' > > in targetinstall stage. Especially PTXCONF_OPKG_OPKG_CONF_URL can > > contain other variables which might change frequently when developing. > > Right, this is a problem for other packages as well. The more general fix > ist to hash the evaluated PTXCONF_* variables instead. I've implemented > this here. It should hit master once all my test have passed. But maybe > only for the April release. FYI, master should handle this correctly now. Michael > > The default for example contains PTXCONF_PROJECT_VERSION which changes > > with every git commit. The place where opkg packages are put to on the > > dev host would differ then from the opkg.conf on the target. Trigger a > > rebuild of the targetinstall stage keeps that in sync. > > > > Signed-off-by: Alexander Dahl > > --- > > rules/opkg.make | 14 ++++++++++++++ > > 1 file changed, 14 insertions(+) > > > > diff --git a/rules/opkg.make b/rules/opkg.make > > index 23390ce0f..2396853fe 100644 > > --- a/rules/opkg.make > > +++ b/rules/opkg.make > > @@ -53,6 +53,17 @@ OPKG_CONF_OPT := \ > > # Target-Install > > # ---------------------------------------------------------------------------- > > > > +ifdef PTXCONF_OPKG_OPKG_CONF > > +OPKG_STAMP := $(call remove_quotes, \ > > + $(PTXCONF_OPKG_OPKG_CONF_URL) \ > > + $(PTXDIST_IPKG_ARCH_STRING) \ > > + $(PTXCONF_OPKG_OPKG_CONF_CHECKSIG)) > > + > > +ifneq ($(strip $(OPKG_STAMP)),$(strip $(call ptx/force-sh cat $(STATEDIR)/opkg.stamp 2>/dev/null))) > > +PHONY += $(STATEDIR)/opkg.targetinstall > > +endif > > +endif > > + > > $(STATEDIR)/opkg.targetinstall: > > @$(call targetinfo) > > > > @@ -104,6 +115,9 @@ endif > > > > @$(call install_finish, opkg) > > > > +ifdef PTXCONF_OPKG_OPKG_CONF > > + @echo "$(OPKG_STAMP)" > $(STATEDIR)/opkg.stamp > > +endif > > @$(call touch) > > > > # vim: syntax=make > > -- > > 2.20.1 > > > > > > _______________________________________________ > > ptxdist mailing list > > ptxdist@pengutronix.de > > > > -- > Pengutronix e.K. | | > Steuerwalder Str. 21 | http://www.pengutronix.de/ | > 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | > Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | > > _______________________________________________ > ptxdist mailing list > ptxdist@pengutronix.de > -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ ptxdist mailing list ptxdist@pengutronix.de