From: Detlev Zundel <dzu@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] U-boot env variables parsing
Date: Thu, 01 Apr 2010 16:56:40 +0200 [thread overview]
Message-ID: <m2k4srkyqf.fsf@ohwell.denx.de> (raw)
In-Reply-To: <OF9AE54728.53EC14CE-ONC12576F8.004804BE-C12576F8.00486EC2@transmode.se> (Joakim Tjernlund's message of "Thu, 1 Apr 2010 15:11:09 +0200")
Hi Jocke,
>> > > Hm... will this not make escaping impossible? Assume you want to pass
>> > >
>> > > arg=${name}
>> > >
>> > > to Linux. How would you escape this so it does NOT get expanded if
>> > > you run process_macros() arbitrarily often?
>> >
>> > Possibly, I never needed that though.
>> > One would probably need to add an escape char for that. Something
>> > like arg=\${name}
>>
>> Woudn't this then just cause another cycle through process_macros(),
>> where it then gets substitured anyway? [Guess I gotta try this out.]
>
> I am not sure what will happen, it was so man years ago.
> But I would guess that if you really want to pass arg=$(name)
> to the kernel you will probably need to do some adjustment.
To me it looks like the new code would indeed do a "greedy" substitution
only stopping when no more substitutions can be done. This is very
un-unixy and thus not something I'd like to see as a default behaviour.
When we want to move in this direction, then we should implement
something with finer control over the substitution rounds.
Cheers and happy easter all around
Detlev
--
Q: What does FAQ stand for?
A: We are Frequently Asked this Question, and we have no idea.
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de
next prev parent reply other threads:[~2010-04-01 14:56 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-01 5:27 [U-Boot] U-boot env variables parsing Nitin Mahajan
2010-04-01 12:15 ` Detlev Zundel
2010-04-01 12:31 ` Joakim Tjernlund
2010-04-01 12:47 ` Wolfgang Denk
2010-04-01 12:56 ` Joakim Tjernlund
2010-04-01 13:05 ` Wolfgang Denk
2010-04-01 13:11 ` Joakim Tjernlund
2010-04-01 14:56 ` Detlev Zundel [this message]
2010-04-01 17:13 ` Joakim Tjernlund
2010-04-01 18:27 ` Wolfgang Denk
2010-04-01 20:08 ` Joakim Tjernlund
2010-04-08 10:00 ` Detlev Zundel
2010-04-08 15:41 ` Joakim Tjernlund
2010-04-08 16:06 ` Detlev Zundel
2010-04-08 17:49 ` Joakim Tjernlund
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=m2k4srkyqf.fsf@ohwell.denx.de \
--to=dzu@denx.de \
--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