mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: zzs213@126.com
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH] Do not rm the path from pbl-y target
Date: Mon, 27 Jun 2016 09:01:07 +0200	[thread overview]
Message-ID: <20160627070107.GW20657@pengutronix.de> (raw)
In-Reply-To: <1466825759-22867-1-git-send-email-zzs213@126.com>

On Sat, Jun 25, 2016 at 11:35:59AM +0800, zzs213@126.com wrote:
> From: 张忠山 <zzs213@126.com>
> 
> Whan add some obj in a subdir to lwl-y or pbl-y, like this:
> 
>     lwl-y += subdir/test.o other.o
> 
> the make process failed:
> 
>     make[2]: *** No rule to make target 'arch/arm/boards/boardname/test.o', \
>         needed by 'arch/arm/boards/boardname/built-in-pbl.o'.  Stop.
> 
> Note, there are not the part "subdir" in the path of the test.o.
> 
> this patch fix this
> 
> Signed-off-by: 张忠山 <zzs213@126.com>
> ---
>  scripts/Makefile.lib | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)

Applied, thanks

Sascha

> 
> diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
> index 27365d8..73b9c57 100644
> --- a/scripts/Makefile.lib
> +++ b/scripts/Makefile.lib
> @@ -39,10 +39,9 @@ endif
>  obj-y		+= $(obj-pbl-y)
>  pbl-y		+= $(obj-pbl-y)
>  
> -# for non dirs add pbl- prefix to the target
> -# so we recompile the source with custom flags and custom quiet
> -__pbl-y		:= $(notdir $(pbl-y))
> -pbl-y		:= $(patsubst %.o,pbl-%.o,$(__pbl-y))
> +# add pbl- prefix to the target
> +pbl-y		:= $(shell echo $(pbl-y) | sed -e 's%\(\([^ \t]\+/\)*\)\([^ \t]*.o\)%\2pbl-\3%g')
> +
>  # add subdir from $(obj-y) too so we do not need to have the dir define in
>  # both $(obj-y) and $(pbl-y)
>  __pbl-y		:= $(filter-out $(pbl-y), $(filter %/, $(obj-y)))
> -- 
> 1.9.1
> 
> 
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox

-- 
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 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2016-06-27  7:01 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-25  3:35 zzs213
2016-06-27  7:01 ` Sascha Hauer [this message]
2016-06-28  5:57 ` Sascha Hauer
2016-06-28  8:27   ` 张忠山
2016-06-29  5:41     ` Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160627070107.GW20657@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=zzs213@126.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox