Hi Daniel!

>Updating my old CVS tree gave a number of conflicts, so I've set that
>one aside and checked out a new tree.

That would seem natural, with tons of work since then, yes.

>The credit is good, thank you! For changes like this I'd request mention
>in an AUTHORS file or the like, but as mksh doesn't have one, that's a
>moot point.

Well the sum of all people listed in (c) plus some in the manpage, but…

>> I’ve disabled the Vi editing mode for EBCDIC for now, it’s got its own
>> lookup table (although we can probably handle that with the rtt2asc()
>> macro as well, now that I think about it).
>
>I'd be happy to test that, but you'd have to tell me exactly what to
>try, as I barely know Vi.

Me either… I added the translation lookup in the meantime, but it’s
not very important, especially compared with some of the other issues.

>> I’ve not merged the huuuge “intro to EBCDIC in the comments” part, as
>> some of it is no longer entirely true after our discussion. Please
>> *do* update it and send me an appropriate patch when you have time.
>
>Could you elaborate on which parts need updating? While I know more now
>than I did then, the comment didn't discuss conversion to/from an "ASCII
>codepage."

I’m not too clear on that myself. I guess you could just check
what’s still missing, patch-wise, and resubmit that, or something.
Or not, if we’re good.

>The first command shows
>
>    ==> which compiler seems to be used... xlc
>
>but uses "cc" for everything, which doesn't work. (On z/OS, "cc" is a
>K&R-C-level compiler, only used for building ancient code.)

This is expected, this is a detection of the *type* of compiler.
I’ll change the verbose string to “which compiler type seems…”.

>If I specify CC=xlc, however, then the build works. A log of the output
>is attached.

OK, good.

>The test suite fails early with
>
>    [...]
>    Trying Perl interpreter 'perl'...
>    Errorlevel 0, running on 'os390, Perl version 5.006001'
>    => using it
>    + perl ./check.pl -p /tmp/mksh/mksh -C 
> shell:legacy-no,int:32,shell:ebcdic-yes,shell:ascii-no,shell:textmode-no,shell:binmode-yes,stdout-ed,no-stderr-ed
>  -v -s ./check.t
>    Can't locate Config.pm in @INC (@INC contains: 
> /net/mvshost/tools/lib/perl5/5.6.1 /usr/local/lib/perl5/5.6.1/os390 
> /usr/local/lib/perl5/5.6.1 /usr/local/lib/perl5/site_perl/5.6.1/os390 
> /usr/local/lib/perl5/site_perl/5.6.1 /usr/local/lib/perl5/site_perl .) at 
> ./check.pl line 174.
>    BEGIN failed--compilation aborted at ./check.pl line 174.
>
>But if I comment out the "use Config" line, then things seem to work.

It’s used later on, but it could conceivably be optional.
My perl-foo is not very good either though… I’ll try something.

>(Note: Both output files were produced with ">file.txt 2>&1", so nothing
>should have been lost.)

Thanks, good. I comment on it below.

>> The new -E option is necessary to enable EBCDIC, I chose to not rely
>> on autodetection as we will need this in the testsuite, too.
>
>I thought the autodetection could be done fairly reliably...

In Build.sh, for the build system, and in C, for the shell itself,
perhaps, but we *also* need it in the testsuite, in order to run
different tests (or same tests with different expected outputs)
in many cases, e.g. some of the ones tagged “ebcdic-special” below
are “print \x40” and expect an @ instead of a space.

This one is weird, from Perl:
unexpected stdout - first difference: line 1, char 3 (wanted 'M-�', got 'M-�'
“wanted Meta-\xCD, got Meta-\xCB”

Oh well, looks like sub format_char also needs work.


Now on to the tests themselves:

needs work      FAIL ./check.t:expand-ugly
subsequential   FAIL ./check.t:expand-unglob-unq
subsequential   FAIL ./check.t:expand-threecolons-dblq
subsequential   FAIL ./check.t:expand-threecolons-unq
needs work      FAIL ./check.t:eglob-nomatch-1
        (something puts MAGIC into the output which is not nice)
subsequential   FAIL ./check.t:eglob-match-1
!ebcdic         FAIL ./check.t:eglob-utf8-1
!ebcdic         FAIL ./check.t:glob-range-3 (ignored)
ebcdic-special  FAIL ./check.t:heredoc-10
unclear#1       FAIL ./check.t:history-ed-3-old (ignored)
ebcdic-special  FAIL ./check.t:integer-base-check-numeric-from
ebcdic-speical  FAIL ./check.t:integer-base-check-numeric-to
unclear         FAIL ./check.t:xxx-variable-syntax-2
unclear         FAIL ./check.t:xxx-variable-syntax-3
prob.subseq.    FAIL ./check.t:exit-trap-2
!ebcdic?        FAIL ./check.t:utf8bom-1
!ebcdic?        FAIL ./check.t:utf8bom-2 (ignored)
fixed in HEAD   FAIL ./check.t:utf8opt-2a (ignored)
!ebcdic         FAIL ./check.t:utf8bug-1
needs investig. FAIL ./check.t:varexpand-substr-1
needs investig. FAIL ./check.t:varexpand-substr-2
needs investig. FAIL ./check.t:varexpand-substr-3
needs investig. FAIL ./check.t:varexpand-substr-4
needs investig. FAIL ./check.t:varexpand-substr-5A
needs investig. FAIL ./check.t:varexpand-substr-5W
needs investig. FAIL ./check.t:varexpand-substr-6
ebcdic-special  FAIL ./check.t:varexpand-special-hash
?ebcdic         FAIL ./check.t:varexpand-special-quote
ebcdic-special  FAIL ./check.t:print-funny-chars
ebcdic-special  FAIL ./check.t:print-array
e.s.+subseq.    FAIL ./check.t:print-escapes
e.s.+subseq.    FAIL ./check.t:dollar-quoted-strings
ebcdic-special  FAIL ./check.t:integer-base-one-1
ebcdic-special  FAIL ./check.t:integer-base-one-2c1
ebcdic-special  FAIL ./check.t:integer-base-one-2d1
ebcdic-special  FAIL ./check.t:integer-base-one-2d2
ebcdic-special  FAIL ./check.t:integer-base-one-2d3
ebcdic-special  FAIL ./check.t:integer-base-one-3As
ebcdic-special  FAIL ./check.t:integer-base-one-3Ws
ebcdic-special  FAIL ./check.t:integer-base-one-3Ar
ebcdic-special  FAIL ./check.t:integer-base-one-3Wr
ebcdic-special  FAIL ./check.t:integer-base-one-4
ebcdic-special  FAIL ./check.t:integer-base-one-5A
ebcdic-special  FAIL ./check.t:integer-base-one-5W
need investig.  FAIL ./check.t:fd-cloexec-1 (ignored)
need investig.  FAIL ./check.t:fd-cloexec-2 (ignored)
subsequential   FAIL ./check.t:comsub-1a
ebcdic-special  FAIL ./check.t:echo-test-1
ebcdic-special  FAIL ./check.t:echo-test-3-normal
ebcdic-special  FAIL ./check.t:wcswidth-1
ebcdic-special  FAIL ./check.t:duffs-device

Key:
- needs work, unclear, fixed in HEAD should be clear
- subsequential is a follow-up error from one further above,
  prob.subseq. is maybe one
- !ebcdic is a test that must (!ebcdic?: maybe) be disabled
  on EBCDIC systems
- ebcdic-special is one that needs a different test on EBCDIC
- unclear#1 is perhaps related to the history file binary format
- needs investigation is probably clear ;)
- ?ebcdic is probably ebcdic-special with investigation
- e.s.+subseq. is ebcdic-special plus subsequential


Conclusion: I guess we’re not quite there yet, but I now have
more input to work with once I have the more pressing issues
out of my feet. Thanks!

As for ebcdic-soecial: the testsuite already contains a
“duffs-device-faux-EBCDIC” check which is used in “faux EBCDIC”
mode (basically ASCII system running with most of the EBCDIC
codepaths enabled), just so you can see how they can differ;
I’m fairly sure the “got” output for duffs-device in your
testsuite log can be copy/pasted into a “duffs-device-EBCDIC”
expected-stdout, as it looks correct. So you can play around
with the tests if you want (otherwise I’ll just do them in
batch, after fixing the more obvious bugs like why the hell
there are ^L and ^G in the shell output).


Thanks,
//mirabilos
-- 
21:12⎜<Vutral> sogar bei opensolaris haben die von der community so
ziemlich jeden mist eingebaut │ man sollte unices nich so machen das
desktopuser zuviel intresse kriegen │ das macht die code base kaputt
21:13⎜<Vutral:#MirBSD> linux war früher auch mal besser :D

Reply via email to