[Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Tom Edwards
In scons, string defines cannot contain spaces. The entire value is wrapped in quote marks even if it has already been escape-quoted. env['RCFLAGS'].append("-DTEST=\"a space\"") env['RCFLAGS'].append("-DTEST=\"nospace\"") Gives: windres "-DTEST="a space"" -DTEST="nospace" And the first is, of

[Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Sergey Kurdakov
Hi Lars, >> env['RCFLAGS'].append("-DTEST=\"a space\"") >> env['RCFLAGS'].append("-DTEST=\"nospace\"") >> >> Gives: >> >> windres "-DTEST="a space"" -DTEST="nospace" among scons docs there is a phrase: string surrounded by double quotation marks is interpreted as a single argument, regardless

[Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Sergey Kurdakov
Hi Tom, I'm very sorry for mistake, but then http://docs.python.org/reference/lexical_analysis.html there are also triple-quoted strings maybe they will go? Regards Sergey ___ Bf-committers mailing list Bf-committers@blender.org http://lists.blend

[Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Sergey Kurdakov
Hi Tom, and escape sequence with \oooCharacter with octal value ooo \xhhCharacter with hex value hh where space is Octal 40or Hex 20 does not help too? Regards Sergey ___ Bf-committers mailing list Bf-committers@blende

[Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Sergey Kurdakov
Hi Tom then, though it looks not nice - but instead of space to use a special ( maybe unicode ) character, then replace this character with space as a last step of appending vars to env['RCFLAGS']? Regards Sergey ___ Bf-committers mailing list Bf-commit

Re: [Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Lars Krueger
> In scons, string defines cannot contain spaces. The entire value is > wrapped in quote marks even if it has already been escape-quoted. > > env['RCFLAGS'].append("-DTEST=\"a space\"") > env['RCFLAGS'].append("-DTEST=\"nospace\"") > > Gives: > > windres "-DTEST="a space"" -DTEST="nospace" > >

Re: [Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Tom Edwards
I didn't know that...but alas it doesn't help. On 26/01/2011 7:34, Lars Krueger wrote: >> In scons, string defines cannot contain spaces. The entire value is >> wrapped in quote marks even if it has already been escape-quoted. >> >> env['RCFLAGS'].append("-DTEST=\"a space\"") >> env['RCFLAGS'].app

Re: [Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Tom Edwards
It's me, not Lars. That line gives "SyntaxError: unexpected character after line continuation character" because double quotes means a zero-character string, and so everything following it is interpreted by Python. On 26/01/2011 8:01, Sergey Kurdakov wrote: > Hi Lars, > >>> env['RCFLAGS'].appe

Re: [Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Tom Edwards
Unfortunately not. It isn't a syntax error, but the extra quotes are still added. On 26/01/2011 8:55, Sergey Kurdakov wrote: > Hi Tom, > > I'm very sorry for mistake, > > but then > > http://docs.python.org/reference/lexical_analysis.html > > there are also > > triple-quoted strings > > maybe t

Re: [Bf-committers] Scons can't define strings with spaces

2011-01-26 Thread Tom Edwards
I don't quite believe it, but no! On 26/01/2011 9:18, Sergey Kurdakov wrote: > Hi Tom, > > and escape sequence with > > \ooo Character with octal value ooo > \xhh Character with hex value hh > > where space is > Octal 40 or Hex 20 > > does not help too? > > Regards > Sergey >

Re: [Bf-committers] Scons can't define strings with spaces

2011-01-27 Thread Nathan Letwory
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 26.1.2011 17:30, Tom Edwards wrote: > In scons, string defines cannot contain spaces. The entire value is > wrapped in quote marks even if it has already been escape-quoted. > > env['RCFLAGS'].append("-DTEST=\"a space\"") > env['RCFLAGS'].append("