On Mon, Jul 06, 1998 at 04:14:53PM -0700, Luiz Otavio L. Zorzella wrote:
> Paul, were you able to unpack the tuner_300d_products_enus.bin file
> usin iBCS or something or you just happen to have a Solaris box were
> you did that?
>
> Any suggestion for someone who does not have a solaris box?
>
this worked for 2.0 .bin packages,
i didn't test it on tuner 3.0 yet
Regards
Luca
--
Luca Berra -- [EMAIL PROTECTED]
System and Network Manager - CoMedia s.r.l.
#!/usr/bin/perl
# pkgrextract - extracts Marimba .bin files
# No Copyright 1997 Luca Berra <[EMAIL PROTECTED]>
#
# This program is free software; you can do anything you want
# with it, I don't give a damn.
# By using this piece of crap you agree that I (Luca Berra)
# cannot be held responsable for any damage that it may cause.
#
# Note: it would also be trivial to make it actually
# extract in the correct directory, run the script, and
# do any cleanup.
$oldfdh=select(STDOUT);$|=1;select($oldfdh);
$oldfdh=select(STDERR);$|=1;select($oldfdh);
sub usage {
$prgname=$0;
$prgname =~ s,.*/,,;
print("Usage: $prgname file.bin\n");
print("\tIt will extract the package in the current directory\n");
print("\tand overwrite anything witout asking, so beware\n");
exit(pop(@_));
}
usage(-1)
if (!defined($ARGV[0]) || defined($ARGV[1]));
SKIP_EXE:
while (<>) {
last SKIP_EXE
if (/^#-%SCTN /);
}
while (/^#-%SCTN (.*?) (\d*)$/) {
$filename=$1;
$filesize=$2;
print("$filename ($filesize bytes)\n");
open(OUTPUT,">$filename");
select(OUTPUT);
DUMP_FILE:
while (<>) {
last DUMP_FILE
if (/^#-%SCTN /);
print;
}
select(STDOUT);
close(OUTPUT);
}