Long sed commands

Kelly O'Hair kelly.ohair at oracle.com
Fri Jul 13 10:13:47 PDT 2012


On Jul 12, 2012, at 9:26 AM, Mike Duigou wrote:

> Does anyone have an explanation about why just these conversions are applied and a general translation similar to :
> 
> \\u00\([0-9a-fA-F]{2,2}\)  => \x\1
> 
> can't be applied? Why can't the source file just be modified?

I wondered about that too. The sources probably require the /u (property files), but we need \x if we want to process the
text with Unix utilities?  I'm just getting started understanding this stuff in detail.
I may look into this further for more refinement, but my main focus as to start looking at possible fixes
that might make the windows builds more reliable, doing the least damage as possible ;^)
Long command lines can cause issues, as well too many pipes in a command.

Windows/CYGWIN is somewhat brittle when it comes to shell commands, and with plans to move to Windows 7 X64
where CYGWIN/X64 issues and CYGWIN/Windows7 issues might make things worse, I need this as solid as we can get.
Tim is looking into MinGW/MSYS as a better solution, but until then.....

-kto

> 
> Mike
> 
> On Jul 11 2012, at 16:41 , Kelly O'Hair wrote:
> 
>> 
>> I'm seeing some really long sed commands when I look at the log file, I'm wondering if we could just create a
>> file to deal with this (appears to be) unicode to \x conversion  unicode2x.sed and run   sed -f unicode2x.sed?
>> I see 2 places where this happens.   Could also be related to some of our Windows failures, maybe long command line issues?
>> 
>> Any objection to that?  The following looks really ugly in the log files...
>> 
>> /usr/bin/sed -e 's/\\u0020/\x20/g' -e 's/\\u003A/\x3A/g' -e 's/\\u006B/\x6B/g' -e 's/\\u0075/\x75/g' -e 's/\\u00A0/\xA0/g' -e 's/\\u00A3/\xA3/g' -e 's/\\u00B0/\xB0/g' -e 's/\\u00B7/\xB7/g' -e 's/\\u00BA/\xBA/g' -e 's/\\u00BF/\xBF/g' -e 's/\\u00C0/\xC0/g' -e 's/\\u00C1/\xC1/g' -e 's/\\u00C2/\xC2/g' -e 's/\\u00C4/\xC4/g' -e 's/\\u00C5/\xC5/g' -e 's/\\u00C8/\xC8/g' -e 's/\\u00C9/\xC9/g' -e 's/\\u00CA/\xCA/g' -e 's/\\u00CD/\xCD/g' -e 's/\\u00CE/\xCE/g' -e 's/\\u00D3/\xD3/g' -e 's/\\u00D4/\xD4/g' -e 's/\\u00D6/\xD6/g' -e 's/\\u00DA/\xDA/g' -e 's/\\u00DC/\xDC/g' -e 's/\\u00DD/\xDD/g' -e 's/\\u00DF/\xDF/g' -e 's/\\u00E0/\xE0/g' -e 's/\\u00E1/\xE1/g' -e 's/\\u00E2/\xE2/g' -e 's/\\u00E3/\xE3/g' -e 's/\\u00E4/\xE4/g' -e 's/\\u00E5/\xE5/g' -e 's/\\u00E6/\xE6/g' -e 's/\\u00E7/\xE7/g' -e 's/\\u00E8/\xE8/g' -e 's/\\u00E9/\xE9/g' -e 's/\\u00EA/\xEA/g' -e 's/\\u00EB/\xEB/g' -e 's/\\u00EC/\xEC/g' -e 's/\\u00ED/\xED/g' -e 's/\\u00EE/\xEE/g' -e 's/\\u00EF/\xEF/g' -e 's/\\u00F1/\xF1/g' -e 's/\\u00F2/\xF2/g' -e 's/\\u00F3/\xF3/g' -e 's/\\u00F4/\xF4/g' -e 's/\\u00F5/\xF5/g' -e 's/\\u00F6/\xF6/g' -e 's/\\u00F9/\xF9/g' -e 's/\\u00FA/\xFA/g' -e 's/\\u00FC/\xFC/g' -e 's/\\u0020/\x20/g' -e 's/\\u003f/\x3f/g' -e 's/\\u006f/\x6f/g' -e 's/\\u0075/\x75/g' -e 's/\\u00a0/\xa0/g' -e 's/\\u00a3/\xa3/g' -e 's/\\u00b0/\xb0/g' -e 's/\\u00ba/\xba/g' -e 's/\\u00bf/\xbf/g' -e 's/\\u00c1/\xc1/g' -e 's/\\u00c4/\xc4/g' -e 's/\\u00c5/\xc5/g' -e 's/\\u00c8/\xc8/g' -e 's/\\u00c9/\xc9/g' -e 's/\\u00ca/\xca/g' -e 's/\\u00cd/\xcd/g' -e 's/\\u00d6/\xd6/g' -e 's/\\u00dc/\xdc/g' -e 's/\\u00dd/\xdd/g' -e 's/\\u00df/\xdf/g' -e 's/\\u00e0/\xe0/g' -e 's/\\u00e1/\xe1/g' -e 's/\\u00e2/\xe2/g' -e 's/\\u00e3/\xe3/g' -e 's/\\u00e4/\xe4/g' -e 's/\\u00e5/\xe5/g' -e 's/\\u00e7/\xe7/g' -e 's/\\u00e8/\xe8/g' -e 's/\\u00e9/\xe9/g' -e 's/\\u00ea/\xea/g' -e 's/\\u00eb/\xeb/g' -e 's/\\u00ec/\xec/g' -e 's/\\u00ed/\xed/g' -e 's/\\u00ee/\xee/g' -e 's/\\u00ef/\xef/g' -e 's/\\u00f0/\xf0/g' -e 's/\\u00f1/\xf1/g' -e 's/\\u00f2/\xf2/g' -e 's/\\u00f3/\xf3/g' -e 's/\\u00f4/\xf4/g' -e 's/\\u00f5/\xf5/g' -e 's/\\u00f6/\xf6/g' -e 's/\\u00f7/\xf7/g' -e 's/\\u00f8/\xf8/g' -e 's/\\u00f9/\xf9/g' -e 's/\\u00fa/\xfa/g' -e 's/\\u00fc/\xfc/g' -e 's/\\u00ff/\xff/g'
>> 
>> Maybe:
>> 
>>  http://cr.openjdk.java.net/~ohair/openjdk8/build-infra-sed/webrev/
>> 
>> -kto
>> 
> 




More information about the build-infra-dev mailing list