Initial import

This commit is contained in:
Stephen Nelson 2013-08-20 23:04:15 -07:00
commit 3c2245dbec
21 changed files with 5564 additions and 0 deletions

248
COPYING Normal file
View File

@ -0,0 +1,248 @@
GNU GENERAL PUBLIC LICENSE
Version 1, February 1989
Copyright (C) 1989 Free Software Foundation, Inc.
675 Mass Ave, Cambridge, MA 02139, USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The license agreements of most software companies try to keep users
at the mercy of those companies. By contrast, our General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. The
General Public License applies to the Free Software Foundation's
software and to any other program whose authors commit to using it.
You can use it for your programs, too.
When we speak of free software, we are referring to freedom, not
price. Specifically, the General Public License is designed to make
sure that you have the freedom to give away or sell copies of free
software, that you receive source code or can get it if you want it,
that you can change the software or use pieces of it in new free
programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of a such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must tell them their rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any program or other work which
contains a notice placed by the copyright holder saying it may be
distributed under the terms of this General Public License. The
"Program", below, refers to any such program or work, and a "work based
on the Program" means either the Program or any work containing the
Program or a portion of it, either verbatim or with modifications. Each
licensee is addressed as "you".
1. You may copy and distribute verbatim copies of the Program's source
code as you receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice and
disclaimer of warranty; keep intact all the notices that refer to this
General Public License and to the absence of any warranty; and give any
other recipients of the Program a copy of this General Public License
along with the Program. You may charge a fee for the physical act of
transferring a copy.
2. You may modify your copy or copies of the Program or any portion of
it, and copy and distribute such modifications under the terms of Paragraph
1 above, provided that you also do the following:
a) cause the modified files to carry prominent notices stating that
you changed the files and the date of any change; and
b) cause the whole of any work that you distribute or publish, that
in whole or in part contains the Program or any part thereof, either
with or without modifications, to be licensed at no charge to all
third parties under the terms of this General Public License (except
that you may choose to grant warranty protection to some or all
third parties, at your option).
c) If the modified program normally reads commands interactively when
run, you must cause it, when started running for such interactive use
in the simplest and most usual way, to print or display an
announcement including an appropriate copyright notice and a notice
that there is no warranty (or else, saying that you provide a
warranty) and that users may redistribute the program under these
conditions, and telling the user how to view a copy of this General
Public License.
d) You may charge a fee for the physical act of transferring a
copy, and you may at your option offer warranty protection in
exchange for a fee.
Mere aggregation of another independent work with the Program (or its
derivative) on a volume of a storage or distribution medium does not bring
the other work under the scope of these terms.
3. You may copy and distribute the Program (or a portion or derivative of
it, under Paragraph 2) in object code or executable form under the terms of
Paragraphs 1 and 2 above provided that you also do one of the following:
a) accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of
Paragraphs 1 and 2 above; or,
b) accompany it with a written offer, valid for at least three
years, to give any third party free (except for a nominal charge
for the cost of distribution) a complete machine-readable copy of the
corresponding source code, to be distributed under the terms of
Paragraphs 1 and 2 above; or,
c) accompany it with the information you received as to where the
corresponding source code may be obtained. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form alone.)
Source code for a work means the preferred form of the work for making
modifications to it. For an executable file, complete source code means
all the source code for all modules it contains; but, as a special
exception, it need not include source code for modules which are standard
libraries that accompany the operating system on which the executable
file runs, or for standard header files or definitions files that
accompany that operating system.
4. You may not copy, modify, sublicense, distribute or transfer the
Program except as expressly provided under this General Public License.
Any attempt otherwise to copy, modify, sublicense, distribute or transfer
the Program is void, and will automatically terminate your rights to use
the Program under this License. However, parties who have received
copies, or rights to use copies, from you under this General Public
License will not have their licenses terminated so long as such parties
remain in full compliance.
5. By copying, distributing or modifying the Program (or any work based
on the Program) you indicate your acceptance of this license to do so,
and all its terms and conditions.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the original
licensor to copy, distribute or modify the Program subject to these
terms and conditions. You may not impose any further restrictions on the
recipients' exercise of the rights granted herein.
7. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of the license which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
the license, you may choose any version ever published by the Free Software
Foundation.
8. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
9. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
10. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
Appendix: How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to humanity, the best way to achieve this is to make it
free software which everyone can redistribute and change under these
terms.
To do so, attach the following notices to the program. It is safest to
attach them to the start of each source file to most effectively convey
the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) 19yy <name of author>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 1, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) 19xx name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the
appropriate parts of the General Public License. Of course, the
commands you use may be called something other than `show w' and `show
c'; they could even be mouse-clicks or menu items--whatever suits your
program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
program `Gnomovision' (a program to direct compilers to make passes
at assemblers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
That's all there is to it!

21
MANIFEST Normal file
View File

@ -0,0 +1,21 @@
COPYING
MANIFEST
Makefile.PL
README
README-TOO
bin/binhex.pl
bin/debinhex.pl
docs/Convert/BinHex.pm.html
docs/Convert/BinHex/hqxred.gif
docs/Convert/BinHex/redapple-sm.gif
docs/Convert/BinHex/redapple-tiny.gif
docs/Convert/BinHex/redapple.gif
lib/Convert/BinHex.pm
t/Checker.pm
t/comp2bin.t
test/hexbin
testin/eyeball.gif
testin/eyeball.gif.hqx
testin/hands_m.eps.hqx
testin/pbs_mac.eps.hqx
testout/README

20
Makefile.PL Normal file
View File

@ -0,0 +1,20 @@
#!/usr/bin/perl
use ExtUtils::MakeMaker;
#------------------------------------------------------------
# Makefile:
#------------------------------------------------------------
# Write the Makefile:
WriteMakefile(
NAME => 'Convert::BinHex',
VERSION_FROM => "./lib/Convert/BinHex.pm",
DISTNAME => "Convert-BinHex",
EXE_FILES => [@EXES],
'dist' => {
PREOP => "cd docs ; make",
COMPRESS => 'gzip',
SUFFIX => 'gz',
}
);

93
README Normal file
View File

@ -0,0 +1,93 @@
NAME
Convert::BinHex - extract data from Macintosh BinHex files
*ALPHA WARNING: this code is currently in its Alpha release. Things may
change drastically until the interface is hammered out: if you have
suggestions or objections, please speak up now!*
SYNOPSIS
Simple functions:
use Convert::BinHex qw(binhex_crc macbinary_crc);
# Compute HQX7-style CRC for data, pumping in old CRC if desired:
$crc = binhex_crc($data, $crc);
# Compute the MacBinary-II-style CRC for the data:
$crc = macbinary_crc($data, $crc);
Hex to bin, low-level interface. Conversion is actually done via an
object (the section on "Convert::BinHex::Hex2Bin") which keeps internal
conversion state:
# Create and use a "translator" object:
my $H2B = Convert::BinHex->hex2bin; # get a converter object
while (<STDIN>) {
print $STDOUT $H2B->next($_); # convert some more input
}
print $STDOUT $H2B->done; # no more input: finish up
Hex to bin, OO interface. The following operations *must* be done in the
order shown!
# Read data in piecemeal:
$HQX = Convert::BinHex->open(FH=>\*STDIN) || die "open: $!";
$HQX->read_header; # read header info
@data = $HQX->read_data; # read in all the data
@rsrc = $HQX->read_resource; # read in all the resource
Bin to hex, low-level interface. Conversion is actually done via an
object (the section on "Convert::BinHex::Bin2Hex") which keeps internal
conversion state:
# Create and use a "translator" object:
my $B2H = Convert::BinHex->bin2hex; # get a converter object
while (<STDIN>) {
print $STDOUT $B2H->next($_); # convert some more input
}
print $STDOUT $B2H->done; # no more input: finish up
Bin to hex, file interface. Yes, you can convert *to* BinHex as well as
from it!
# Create new, empty object:
my $HQX = Convert::BinHex->new;
# Set header attributes:
$HQX->filename("logo.gif");
$HQX->type("GIFA");
$HQX->creator("CNVS");
# Give it the data and resource forks (either can be absent):
$HQX->data(Path => "/path/to/data"); # here, data is on disk
$HQX->resource(Data => $resourcefork); # here, resource is in core
# Output as a BinHex stream, complete with leading comment:
$HQX->encode(\*STDOUT);
PLANNED!!!! Bin to hex, "CAP" interface. *Thanks to Ken Lunde for
suggesting this*.
# Create new, empty object from CAP tree:
my $HQX = Convert::BinHex->from_cap("/path/to/root/file");
$HQX->encode(\*STDOUT);
DESCRIPTION
BinHex is a format used by Macintosh for transporting Mac files safely
through electronic mail, as short-lined, 7-bit, semi-compressed data
streams. Ths module provides a means of converting those data streams
back into into binary data.
CHANGES
Version 1.118
Ready to go public (with Paul's version, patched for native Mac
support)! Warnings have been suppressed in a few places where undefined
values appear.

13
README-TOO Normal file
View File

@ -0,0 +1,13 @@
In this toolkit are the modules:
Convert::BinHex (in ./lib)
And the sample programs:
binhex.pl (in ./bin)
debinhex.pl (in ./bin)
Knock yourself out.

169
bin/binhex.pl Normal file
View File

@ -0,0 +1,169 @@
#!/usr/bin/perl -w
=head1 NAME
binhex.pl - use Convert::BinHex to encode files as BinHex
=head1 USAGE
Usage:
binhex.pl [options] file ... file
Where the options are:
-o dir Output in given directory (default outputs in file's directory)
-v Verbose output (normally just one line per file is shown)
=head1 DESCRIPTION
Each file is converted to file.hqx.
=head1 WARNINGS
Largely untested.
=head1 AUTHOR
Paul J. Schinder (NASA/GSFC) mostly, though Eryq can't seem to keep
his grubby paws off anything...
=cut
use lib "./lib";
use Getopt::Std;
use Convert::BinHex;
use POSIX;
use Fcntl;
use File::Basename;
use Carp;
require Mac::Files if (($^O||'') eq "MacOS");
use strict;
use vars qw(
$opt_o
$opt_v
);
my $DEBUG = 0;
#------------------------------------------------------------
# main
#------------------------------------------------------------
sub main {
# What usage?
@ARGV or usage();
getopts('o:v');
$DEBUG = $opt_v;
# Process files:
my $file;
foreach $file (@ARGV) {
binhex($file);
}
}
exit(&main ? 0 : -1);
#------------------------------------------------------------
# usage
#------------------------------------------------------------
# Get usage from me.
sub usage {
my $msg = shift || '';
my $usage = '';
if (open(USAGE, "<$0")) {
while ($_ = <USAGE> and !/^=head1 USAGE/) {};
while ($_ = <USAGE> and !/^=head1/) {$usage .= $_};
close USAGE;
}
else {
$usage = "Usage unavailable; please see the script itself.";
}
print STDERR "\n$msg$usage";
exit -1;
}
#------------------------------------------------------------
# binhex FILE
#------------------------------------------------------------
# Encode the given FILE.
#
sub binhex {
my $inpath = shift || die "No filename given $!";
local *BHEX;
my ($has, $dlength, $rlength, $finfo, $flags);
# Create new BinHex interface:
my $hqx = Convert::BinHex->new;
# Get input directory/filename:
my ($inname, $indir) = fileparse($inpath);
die "filename $inname too long!" if ((length($inname)+4) > 31);
$hqx->filename($inname);
# Set up output directory/filename:
my $outname = "$inname.hqx";
my $outdir = $opt_o || $indir;
my $outpath = "$outdir/$outname"; $outpath =~ s{/+}{/}g;
# If we're on a Mac, we can get the real resource info:
if ($^O||'' eq "MacOS") {
# Get and set up type, creator, flags:
$has = Mac::Files::FSpGetCatInfo($inpath);
$finfo = $has->{ioFlFndrInfo};
$dlength = $has->{ioFlLgLen};
$rlength = $has->{ioFlRLgLen};
$hqx->type($finfo->{fdType});
$hqx->creator($finfo->{fdCreator});
$hqx->flags($finfo->{fdFlags} & 0xfeff); # turn off inited bit
# Set up data fork:
$hqx->data(Path=>$inpath);
$hqx->data->length($dlength);
# Set up resource fork:
$hqx->resource(Path=>$inpath, Fork => "RSRC");
$hqx->resource->length($rlength);
}
else { # not a Mac: fake it...
# Set up data fork:
$hqx->data(Path => $inpath);
$dlength = (-s $inpath);
# Set up resource fork:
if (-e "$inpath.rsrc") {
$hqx->resource(Path => "$inpath.rsrc");
$rlength = (-s "$inpath.rsrc");
}
else {
$hqx->resource(Data => '');
$rlength = 0;
}
}
# Ready!
print "BinHexing: $inpath\n";
if ($DEBUG) {
print " Resource size: $rlength\n" if defined($rlength);
print " Data size: $dlength\n" if defined($dlength);
}
open BHEX, ">$outpath" or croak("Unable to open $outpath");
$hqx->encode(\*BHEX);
close BHEX;
print "Wrote: $outpath\n";
}
#------------------------------------------------------------
1;

211
bin/debinhex.pl Normal file
View File

@ -0,0 +1,211 @@
#!/usr/bin/perl -w
=head1 NAME
debinhex.pl - use Convert::BinHex to decode BinHex files
=head1 USAGE
Usage:
debinhex.pl [options] file ... file
Where the options are:
-o dir Output in given directory (default outputs in file's directory)
-v Verbose output (normally just one line per file is shown)
=head1 DESCRIPTION
Each file is expected to be a BinHex file. By default, the output file is
given the name that the BinHex file dictates, regardless of the name of
the BinHex file.
=head1 WARNINGS
Largely untested.
=head1 AUTHOR
Paul J. Schinder (NASA/GSFC) mostly, though Eryq can't seem to keep
his grubby paws off anything...
=cut
use lib "./lib";
use Getopt::Std;
use Convert::BinHex;
use POSIX;
use Fcntl;
use File::Basename;
use Carp;
require Mac::Files if ($^O||'' eq "MacOS");
use strict;
use vars qw(
$opt_o
$opt_v
);
my $DEBUG = 0;
#------------------------------------------------------------
# main
#------------------------------------------------------------
sub main {
# What usage?
@ARGV or usage();
getopts('o:v');
$DEBUG = $opt_v;
# Process files:
my $file;
foreach $file (@ARGV) {
debinhex($file);
}
}
exit(&main ? 0 : -1);
#------------------------------------------------------------
# usage
#------------------------------------------------------------
# Get usage from me.
sub usage {
my $msg = shift || '';
my $usage = '';
if (open(USAGE, "<$0")) {
while ($_ = <USAGE> and !/^=head1 USAGE/) {};
while ($_ = <USAGE> and !/^=head1/) {$usage .= $_};
close USAGE;
}
else {
$usage = "Usage unavailable; please see the script itself.";
}
print STDERR "\n$msg$usage";
exit -1;
}
#------------------------------------------------------------
# debinhex FILE
#------------------------------------------------------------
# Decode the given FILE.
#
sub debinhex {
my $inpath = shift || croak("No filename given $!");
local *BHEX;
my ($data, $testlength, $length, $fd);
print "DeBinHexing: $inpath\n";
# Open BinHex file:
open(BHEX,"<$inpath") || croak("Unable to open $inpath: $!");
# Create converter interface on stream:
my $hqx = Convert::BinHex->open(FH => \*BHEX);
# Read header, and output as string if debugging:
$hqx->read_header;
print $hqx->header_as_string if $DEBUG;
# Get output directory/filename:
my ($inname, $indir) = fileparse($inpath);
my $outname = $hqx->filename || 'NONAME';
my $outdir = $opt_o || $indir;
my $outpath = "$outdir/$outname"; $outpath =~ s{/+}{/}g;
# Create Mac file:
if ($^O||'' eq "MacOS") {
Mac::Files::FSpCreate($outpath, $hqx->creator, $hqx->type)
or croak("Unable to create Mac file $outpath");
}
# Get lengths of forks:
my $dlength = $hqx->data_length;
my $rlength = $hqx->resource_length;
# Write data fork:
print "Writing: $outpath\n";
$fd = POSIX::open($outpath, (&POSIX::O_WRONLY | &POSIX::O_CREAT), 0755);
$testlength = 0;
while (defined($data = $hqx->read_data)) {
$length = length($data);
POSIX::write($fd, $data, $length)
or croak("couldn't write $length bytes: $!");
$testlength += $length;
}
POSIX::close($fd) or croak "Unable to close $outpath";
croak("Data fork length mismatch: ".
"expected $dlength, wrote $testlength")
if $dlength != $testlength;
# Write resource fork?
if ($rlength) {
# Determine how to open fork file appropriately:
my ($rpath, $rflags);
if (($^O||'') eq "MacOS") {
$rpath = $outpath;
$rflags = (&POSIX::O_WRONLY | &POSIX::O_CREAT | &Fcntl::O_RSRC);
}
else {
$rpath = "$outpath.rsrc";
$rflags = (&POSIX::O_WRONLY | &POSIX::O_CREAT);
}
# Write resource fork...
$fd = POSIX::open($rpath, $rflags, 0755);
$testlength = 0;
while (defined($data = $hqx->read_resource)) {
$length = length($data);
POSIX::write($fd,$data,$length)
or croak "Couldn't write $length bytes: $!";
$testlength += $length;
}
POSIX::close($fd) or croak "Unable to close $rpath";
croak("Resource fork length mismatch: ".
"expected $rlength, wrote $testlength")
if $testlength != $rlength;
}
# Set Mac attributes:
if (($^O||'') eq "MacOS") {
my $has = Mac::Files::FSpGetCatInfo($outpath);
my $finfo = $has->{ioFlFndrInfo};
$finfo->{fdFlags} = $hqx->flags & 0xfeff; #turn off inited bit
$finfo->{fdType} = $hqx->type || "????";
$finfo->{fdCreator} = $hqx->creator || "????";
# Turn on the bundle bit if it's an application:
### $finfo->{fdFlags} |= 0x2000 if $finfo->{fdType} eq "APPL";
if ($DEBUG) {
printf("%x\n",$finfo->{fdFlags});
printf("%s\n",$finfo->{fdType});
printf("%s\n",$finfo->{fdCreator});
}
$has->{ioFlFndrInfo} = $finfo;
Mac::Files::FSpSetCatInfo($outpath, $has)
or croak "Unable to set catalog info $^E";
if ($DEBUG) {
$has = Mac::Files::FSpGetCatInfo ($outpath);
printf("%x\n",$has->{ioFlFndrInfo}->{fdFlags});
printf("%s\n",$has->{ioFlFndrInfo}->{fdType});
printf("%s\n",$has->{ioFlFndrInfo}->{fdCreator});
}
}
1;
}
#------------------------------------------------------------
1;

1059
docs/Convert/BinHex.pm.html Normal file

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 149 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 982 B

1741
lib/Convert/BinHex.pm Normal file

File diff suppressed because it is too large Load Diff

33
t/Checker.pm Normal file
View File

@ -0,0 +1,33 @@
package Checker;
@ISA = qw(Exporter);
@EXPORT = qw($CHECK okay_if note check filter_warnings);
$Checker::OUTPUT = 1;
$Checker::CHECK = 0;
# Only lets through warnings that originate outside our toolkit:
sub filter_warnings {
$SIG{'__WARN__'} = sub {
print STDERR $_[0] if ($_[0] !~ /^MIME:/);
};
}
sub okay_if {
print( ($_[0] ? "ok\n" : "not ok\n"))
}
sub note {
print STDOUT " ## ", @_, "\n" if $OUTPUT;
}
sub check {
++$CHECK;
my ($ok, $note) = @_;
$note = ($note ? ": $note" : '');
my $stat = ($ok ? 'OK ' : 'ERR');
printf STDOUT " Test %2d$note\n", $CHECK if $OUTPUT;
print(($ok ? "ok $CHECK\n" : "not ok $CHECK\n"));
}
1;

85
t/comp2bin.t Normal file
View File

@ -0,0 +1,85 @@
use lib "./blib/lib", "./lib", "./t";
use Checker;
use Convert::BinHex;
%TEST = (
PIVOT_3 => {
COMP => ["90 00 01 02 03 04 00",
"90 00 03"],
BIN => "90 01 02 03 04 00 90 03",
},
PIVOT_2 => {
COMP => ["90 00 01 02 03 04 00 90",
"00 03"],
BIN => "90 01 02 03 04 00 90 03",
},
PIVOT_1 => {
COMP => ["90 00 01 02 03 04 00 90 00",
"03"],
BIN => "90 01 02 03 04 00 90 03",
},
CHOPPY => {
COMP => ["90",
"00",
"01 02 03 04",
"00",
"90",
"00",
"03"],
BIN => "90 01 02 03 04 00 90 03",
},
FOUR_FIVES => {
COMP => ["01 02 03 04 05 90 04"],
BIN => "01 02 03 04 05 05 05 05",
},
FOUR_FIVES_AND_A_SIX => {
COMP => ["01 02 03 04 05 90 04 06"],
BIN => "01 02 03 04 05 05 05 05 06",
},
FOUR_MARKS => {
COMP => ["01 02 03 04 90 00 90 04"],
BIN => "01 02 03 04 90 90 90 90",
},
FOUR_MARKS_AND_A_SIX => {
COMP => ["01 02 03 04 90 00 90 04 06"],
BIN => "01 02 03 04 90 90 90 90 06",
},
FIVE_ONES_AND_TWOS => {
COMP => ["01 90 05 02 90 05"],
BIN => "01 01 01 01 01 02 02 02 02 02",
},
);
sub str2hex {
my $str = shift;
eval '"\x' . join('\x', split(/\s+/,$str)) . '"';
}
#------------------------------------------------------------
# BEGIN
#------------------------------------------------------------
print "1..9\n";
my $TESTKEY;
foreach $TESTKEY (sort keys %TEST) {
my $test = $TEST{$TESTKEY};
my @comps = map { str2hex($_) } @{$test->{COMP}};
my $bin = str2hex($test->{BIN});
my $comp;
my $rbin = '';
my $H2B = Convert::BinHex->hex2bin;
foreach $comp (@comps) {
$rbin .= $H2B->comp2bin_next($comp);
}
check(($rbin eq $bin), "test $TESTKEY");
}
1;

81
test/hexbin Normal file
View File

@ -0,0 +1,81 @@
#!/usr/bin/perl
use lib "./lib";
use Convert::BinHex;
use Getopt::Std;
my $bytes;
@ARGV or usage();
# Get options:
getopts("vhn:o:");
my $dir = $opt_o ||= ".";
# Process files:
my $infile;
my $nfiles = int(@ARGV);
my $file_i = 0;
foreach $infile (@ARGV) {
++$file_i;
# Read header:
print STDERR "\nReading $infile\n";
my $HQX = Convert::BinHex->open(Expr=>"<$infile")
|| die "open $ARGV[0]: ";
$HQX->read_header;
print STDERR $HQX->header_as_string if ($opt_v or $opt_h);
next if $opt_h;
# Get output filename:
my $name;
if ($opt_n) {
$name = $opt_n . (($nfiles > 1) ? "-$file_i" : '');
}
else {
($name = $HQX->filename) =~ s/[^A-Za-z0-9_\.-]/_/g;
}
my $fname;
# Output data fork:
$fname = "$dir/$name";
print STDERR "Writing $fname (data fork)\n";
printf STDERR "Expecting: %6d bytes\n", $HQX->data_length if $opt_v;
open DATA, ">$fname" or die "open $fname: $!";
while ($bytes = $HQX->read_data) {
print DATA $bytes;
}
close DATA;
printf STDERR "Wrote: %6d bytes\n", (-s $fname) if $opt_v;
# Output resource fork:
$fname = "$dir/$name.rsrc";
print STDERR "Writing $fname (resource fork)\n";
printf STDERR "Expecting: %6d bytes\n", $HQX->resource_length if $opt_v;
open RESOURCE, ">$fname" or die "open $fname: $!";
while ($bytes = $HQX->read_resource) {
print RESOURCE $bytes;
}
close RESOURCE;
printf STDERR "Wrote: %6d bytes\n", (-s $fname) if $opt_v;
1;
}
exit(0);
sub usage {
print STDERR <<EOF;
Usage: hexbin [opts] [-] file.hqx
-h output header information only; don't convert
-n name name output files (default taken from .hqx)
-o dir output directory
-v verbose output
EOF
exit(-1);
}
__END__
1;

BIN
testin/eyeball.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

60
testin/eyeball.gif.hqx Normal file
View File

@ -0,0 +1,60 @@
(This file must be converted with BinHex 4.0)
:#f9jC@*KE'`ZCfPQ!$mr2cmr2cmr!!!!!!V$!!!!!'Q'4dP'1$PK2!!k!2Ir!!J
)#"!3%"JB'#%K)5NT+6%a-6Nj18*#3NT+5P*58PTD@Q0MBh0cFi5%K)b-M*58P*b
FR+@PTDfYVE@eYEfp[FE'aXl1cYE@eYlHhZIRjqr[lrIhpml'aVfeYDfPTE@YVFD
p[C5-M*b8P+@FR,fYVFDeYFkp[E@PT@0D@UfFR*b-M+@8P%T#3T5%K)alHi4cFlf
PTFDYVAYVDl@FR+f8P*b%K)acFkf-M"J3%'0#3PSj13J!!%)3#$N)!'-j-9)T)8)
B%'Y+3PSj-9)a+@0#1BacDi4VBh0D8QY55Q0+3NSB#%)3!(YM@PSa)8)B#$N3!&)
T'%SK%+@8M)alFi4cDfYD8N)a+9Sj+9)a)8SB!*b-K(YVBf0#-8ST'*5%Hh0M@M%
K'%)B!(0D5PSa'&)T%%SK#&T#-9)K!'Y+-9)a'&Sa%&)T#%SK!-DpYD@FP-DeTBa
lDh0D3N)a)5%3!0E1aV@YTCb8M*5-K*b-Hh0M8RYM5QY51@Y++4J3#'0#)9Sj'&)
a%%ST#&Sa#"!)!&)T!-l'[DfPR)b%Hf0#'&)a#%ST!&Sa!)alBhYM3R0D1@Y5-@0
++6NK!)4c@Q0#%&Sj#&)a!(YV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hands_m.eps.hqx Normal file

File diff suppressed because it is too large Load Diff

208
testin/pbs_mac.eps.hqx Normal file
View File

@ -0,0 +1,208 @@
(This file must be converted with BinHex 4.0)
:#e"#8epYB@-ZCA"c!%938dC"8P4C!!!!!"cF!!!*Ma+D*5&38be"C'pLC5db,M!
J49"64Lda,M)0*59$FQ9KG'pb1N&NEf*P)%PXE(9cG(*KG'pb+&40+5!a,M%0*59
'Eh)k)#K$Efe`GA4PFL"6CA*fD@0PFbNJ+&"#8bN0*598DA4XC6SJ+&"#8b"XEfG
[,QeKBbN0*59$FQ9KG'P[EN4KG'8k)#Ja-5ma-bmj0LNJ+$3k-6)J8%dT$58P4'p
MG@ePER43FQpMCA0c3fpXEh*c1L"#E'&MD`dP*84[Bh9YC@jd8(*[Be0PG(-k)%&
NEf*PAdPXE(9cG(*KG'pbAc%Z-5!`)$!0*59%Ef0eE@9ZG&0eF("XD@9N8(*[Be0
PG(-k)%&NEf*PAdPXE(9cG(*KG'pbAc%Z-5!`)$!0*59#Eh9ZC'PZCd*[H$Sb0$F
J-cFd)$-`05!d0$F0*59$Efa[FP9cB@GP1L"#E'&MDbCAD'PdC3dP*94PEA"XBA4
P3Qpi1M)i1#!c0M!J-MJi)$-f-!dP*94TE'9#EhJk)$%b)#dc)$8f0#!h-M80*59
%Ef0eE@9ZG&"bCACTCAFk)%eKBfPZG'pcD&p3D@-0*59&EQ4$EfeYC@jdF`dP*8*
PCfPZ8(*[Be0PG$T"C'pLC9p*E'aeFh4bBA4[FPma,M%J-#!`$5p"C'pLC9p*E'a
eFh4bBA4[FPma,M%JC(9`)$%`-#"ND@0d)'4PCL"XEf&N)'*PCfPZ$5p@CA*cD@p
Z)$!JC'9Q$5p5CACTFfP[EL!`)'4PCJd[BQ4PCL"lBQPZC#"NC@Cp)'*TEQ3JC'9
Q$5pXC'9Q)(YXEf&N)'4PCRdJBQ4PCJd[H'4PCL"lCAKMD#"NC@Cp)'*NC@B0,ep
,)(Xc)'PZC'9i)'&NC#"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