From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from ptx.hi.pengutronix.de ([2001:6f8:1178:2:5054:ff:fec0:8e10] ident=Debian-exim) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1Wuc3K-0005Sb-81 for ptxdist@pengutronix.de; Wed, 11 Jun 2014 08:30:30 +0200 Received: from mol by ptx.hi.pengutronix.de with local (Exim 4.80) (envelope-from ) id 1Wuc3K-0002HV-6W for ptxdist@pengutronix.de; Wed, 11 Jun 2014 08:30:30 +0200 Date: Wed, 11 Jun 2014 08:30:30 +0200 From: Michael Olbrich Message-ID: <20140611063030.GN4904@pengutronix.de> References: <1400145009-4662-1-git-send-email-t.gamez@phytec.de> <1400145009-4662-2-git-send-email-t.gamez@phytec.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1400145009-4662-2-git-send-email-t.gamez@phytec.de> Subject: Re: [ptxdist] [PATCH v2 2/2] barebox_mlo: use images/barebox-*-mlo.img as images Reply-To: ptxdist@pengutronix.de List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Sender: ptxdist-bounces@pengutronix.de Errors-To: ptxdist-bounces@pengutronix.de To: ptxdist@pengutronix.de On Thu, May 15, 2014 at 11:10:09AM +0200, Teresa G=E1mez wrote: > New barebox versions may create multiple MLO images. > Adapted barebox_mlo rule to handle this. > = > Signed-off-by: Teresa G=E1mez Thanks, applied. Michael > --- > Changes in v2: > - Reworked second if statement > - Added tick marks > = > rules/barebox_mlo.make | 15 ++++++++++++--- > 1 files changed, 12 insertions(+), 3 deletions(-) > = > diff --git a/rules/barebox_mlo.make b/rules/barebox_mlo.make > index 3c53575..f90955c 100644 > --- a/rules/barebox_mlo.make > +++ b/rules/barebox_mlo.make > @@ -76,9 +76,18 @@ $(STATEDIR)/barebox_mlo.install: > $(STATEDIR)/barebox_mlo.targetinstall: > @$(call targetinfo) > # #barebox renamed barebox.bin.ift to MLO, so fall back to barebox.bin.i= ft > - @ptxd_get_path "$(BAREBOX_MLO_DIR)/MLO" \ > - "$(BAREBOX_MLO_DIR)/barebox.bin.ift" && \ > - install -D -m644 "$${ptxd_reply}" "$(IMAGEDIR)/MLO" > + @rm -f $(IMAGEDIR)/MLO > + @for image in `ls $(BAREBOX_MLO_DIR)/images/barebox-*-mlo.img`; do \ > + install -D -m644 $$image $(IMAGEDIR)/`basename $$image`; \ > + if [ ! -e "$(IMAGEDIR)/MLO" ]; then \ > + ln -sf `basename $$image` $(IMAGEDIR)/MLO; \ > + fi; \ > + done > + @if [ ! -e "$(IMAGEDIR)/MLO" ]; then \ > + ptxd_get_path "$(BAREBOX_MLO_DIR)/MLO" \ > + "$(BAREBOX_MLO_DIR)/barebox.bin.ift" && \ > + install -D -m644 "$${ptxd_reply}" "$(IMAGEDIR)/MLO"; \ > + fi > = > @$(call touch) > = > -- = > 1.7.0.4 > = > = > -- = > ptxdist mailing list > ptxdist@pengutronix.de -- = Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | -- = ptxdist mailing list ptxdist@pengutronix.de