From: Mike Frysinger <vapier@gentoo.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 2/3] Makefile: simplify handling of build target names
Date: Wed, 19 May 2010 19:40:42 -0400 [thread overview]
Message-ID: <201005191940.43513.vapier@gentoo.org> (raw)
In-Reply-To: <1273970133-10228-3-git-send-email-wd@denx.de>
On Saturday 15 May 2010 20:35:32 Wolfgang Denk wrote:
> --- a/mkconfig
> +++ b/mkconfig
> @@ -22,7 +22,7 @@ while [ $# -gt 0 ] ; do
> esac
> done
>
> -[ "${BOARD_NAME}" ] || BOARD_NAME="$1"
> +[ "${BOARD_NAME}" ] || BOARD_NAME="${1%%_config}"
>
> [ $# -lt 4 ] && exit 1
> [ $# -gt 6 ] && exit 1
> @@ -102,7 +102,7 @@ done
> cat << EOF >> config.h
> #define CONFIG_BOARDDIR board/$BOARDDIR
> #include <config_defaults.h>
> -#include <configs/$1.h>
> +#include <configs/${1%%_config}.h>
> #include <asm/config.h>
> EOF
it isnt harmful, but using %% when there are no glob patterns doesnt make
sense. so typically the code would be ${1%_config}. or even better, create a
new variable up front set to ${1%_config} and use that later on instead of
duplicating the same replacement construct multiple times.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20100519/66cf19f3/attachment.pgp
next prev parent reply other threads:[~2010-05-19 23:40 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-16 0:35 [U-Boot] [PATCH 0/3] Makefile: rework / cleanup Wolfgang Denk
2010-05-16 0:35 ` [U-Boot] [PATCH 1/3] Fix printing of make targets, simplify Makefile Wolfgang Denk
2010-05-16 0:35 ` [U-Boot] [PATCH 2/3] Makefile: simplify handling of build target names Wolfgang Denk
2010-05-19 23:40 ` Mike Frysinger [this message]
2010-05-16 0:35 ` [U-Boot] [PATCH 3/3] Makefile: simplify handling of common board configurations Wolfgang Denk
2010-05-18 9:05 ` [U-Boot] [PATCH 0/3] Makefile: rework / cleanup Detlev Zundel
2010-05-27 21:18 ` [U-Boot] [PATCH 0/4 v2] " Wolfgang Denk
2010-05-28 1:38 ` Thomas Chou
2010-05-28 12:19 ` Wolfgang Denk
2010-05-28 13:00 ` Scott McNutt
2010-05-28 14:16 ` Thomas Chou
2010-05-28 14:34 ` Thomas Chou
2010-05-27 21:18 ` [U-Boot] [PATCH 1/4 v2] Fix printing of make targets, simplify Makefile Wolfgang Denk
2010-06-13 16:08 ` Wolfgang Denk
2010-05-27 21:18 ` [U-Boot] [PATCH 2/4 v2] Makefile: simplify handling of build target names Wolfgang Denk
2010-06-13 16:08 ` Wolfgang Denk
2010-05-27 21:18 ` [U-Boot] [PATCH 3/4 v2] Makefile: simplify handling of common board configurations Wolfgang Denk
2010-06-13 16:09 ` Wolfgang Denk
2010-05-27 21:18 ` [U-Boot] [PATCH 4/4 v2] Makefile/mkconfig: read simple board configurations from boards.cfg Wolfgang Denk
2010-05-28 5:13 ` Peter Tyser
2010-05-28 5:32 ` Peter Tyser
2010-06-13 16:10 ` Wolfgang Denk
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=201005191940.43513.vapier@gentoo.org \
--to=vapier@gentoo.org \
--cc=u-boot@lists.denx.de \
/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