Skip to content

Improve makerel EBCDIC handling#24444

Open
khwilliamson wants to merge 7 commits into
Perl:bleadfrom
khwilliamson:makerel
Open

Improve makerel EBCDIC handling#24444
khwilliamson wants to merge 7 commits into
Perl:bleadfrom
khwilliamson:makerel

Conversation

@khwilliamson
Copy link
Copy Markdown
Contributor

This adds the ability to generate a tarball for CP 037, besides previously just CP1047, suppresses messages about known outlier files, and adds special handling for files known to be encoded in a format that shouldn't be translated to EBCDIC, such as Japanese

  • This set of changes does not require a perldelta entry.

There is nothing besides the -c for that option
This is in preparation for a future commit which will need the extra
flexibility
We only want to translate Latin1/UTF-8/UTF-16 files to EBCDIC in that
mode.  Other encodings should be left alone.  This commit looks for
=encoding lines indicating such alien encoded files.

Some of these previously showed up as binary files.  But look for
=encoding first to give the proper message.
Some files aren't translatable to EBCDIC, like binary files (.gz for
example) or files that are known to be in a non-Latin1 encoding (like
Cyrillic).  This adds lists of those, and suppresses mention of them.
Then should a file newly start to have a message, it will be more
noticeable.
Besides 1047, Perl also has tables to handle CP 037, though we have no
known active systems using that.  (There were protests last time we
considered removing them.)

I believe the core has improved enough that we could handle any code
page which is isomorphic to Latin1 just by adding a table.  (If not
isomorphic to Latin1, that would be a big big deal to add and not worth
doing.)

Anyway, this commit adds the ability to specify CP 037 as the output of
this command, and it would be trivial to add any other CP that we were
to add tables for.
@khwilliamson khwilliamson added the defer-next-dev This PR should not be merged yet, but await the next development cycle label May 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

defer-next-dev This PR should not be merged yet, but await the next development cycle

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant