Re: [Freedos-user] 7zip in pure dos?

2013-08-30 Thread Rugxulo
Hi,

On Fri, Aug 30, 2013 at 12:19 AM, Mateusz Viste
 wrote:
>
> On 08/30/2013 06:42 AM, Rugxulo wrote:
>
>> IIRC, the default mode of 7za is -mx5 and .7z format using LZMA [or
>> LZMA2 in newer alphas] method, which means (among other things) 16 MB
>> dictionary, aka 2^24, aka LZMA:24 (but you can adjust that).
>
> This is right. But "bigger dictionary" doesn't necessarily mean
> 'better'. well, sure, it means 'potentially better compression ratio',
> because we can seek back redundant data in wider spans, but it also
> means 'tremendously higher memory requirements'. This is why I don't
> create FDNPKG packages using LZMA (unless for pure experimentation),
> even though it's 5-15% smaller than DEFLATE. Trying to uncompress an
> LZMA file on a <16MB RAM machine is hell (or simply impossible if no
> virtual memory is available).

While some compressors use a minimum dictionary size regardless of the
file size (e.g. bzip2 defaults to 900k unless explicitly told
otherwise), 7-Zip is apparently smarter. At least, my one-floppy DJGPP
.7z file only uses "6m" (6 MB, roughly the size of all files
unpacked), so I did correctly decompress it (years ago), without
swapping or slowdown, on a 486 with 7 MB of extended RAM. This was not
possible with UHarc, which needed approx. 24 MB (by default with
"-mx", I think).

And like I said, you can make the dictionary bigger or smaller,
depending on need. I don't remember the limits, perhaps 1 GB is max.

And BTW, just for more arcane useless trivia, CWSDPMI won't allocate
the total RAM size requested for its swapfile unless it is actually
used (unlike Causeway), which is of course a more efficient way of
doing things.

>> Even .ZIP format can officially support Bzip2 or even LZMA
>> method (or others).
>
> That's exactly what FDNPKG supports - LZMA-compressed files inside ZIP
> 'slots'. This allows using the cool ZIP structure for handling files
> (and extracting only these we need - eg. without SOURCES), but still
> benefiting from the LZMA compression ratio.

IIRC, zip 3.0 and unzip 6.00 both optionally support bzip2's
compression method via libbz2 (or whatever it's called) at compile
time (see "unzip -v" and "zip -Z bzip2"). E.g. my native Windows
versions here do and don't support it (but Cygwin zip does). Though I
don't know why there was never an official build of zip 3.0 for DOS.
(I vaguely recall some tmpfile bug, but it wasn't pressing enough for
me to care. I presume that others were similarly less interested, as
always.)

> indeed, .gz is designed to compress only a single file. No 'directory
> storage' capabilities there. Still, for 'single file' compression I'd
> use gzip over zip anytime. It's fits better, because it provides all we
> need, without any additional garbage (mostly limited to filename + CRC32
> + a few flags).

Well, as usual, things are as complicated as you make them. Yes, .ZIP
has some minor overhead, but like I said, it's not technically true
that it's always smaller to use .gz (or even .bz2) instead of .zip.

Some tools don't handle both .gz and .tar.gz, e.g. DJGPP's djtar only
handles the latter (and also .tar.bz2 in "beta" djdev204.zip ... and
of course plain .tar and .zip). GNU gzip can unpack a .zip if it only
has one file inside, but I don't think the *BSD equivalent has that
feature. Yeah, I know, minor stuff, but it's somewhat annoying when
your options are limited (e.g. no network connection or no compiler or
similar trivial problem).

>> "Usually" but not always. 7-Zip provides its own "improved" Deflate,
>> which is slightly better
>
> On a side note: some decompressors have troubles handling the 7zip
> 'deflated zip' files sometimes. For example kunzip crashes on some zip
> files created by 7za, while it doesn't crash on any other files created
> with 'classic' zippers.

There are literally dozens of decompressors for .zip files. It would
be impossible, even with "standard" appnote.txt, for them all to fully
comply. I've not seen any huge problems, but it's always possible. If
you (or yours) use kunzip much, maybe that's a concern, but since I
(naively?) don't consider that a widely-used implementation, I'm not
too worried.

I mean, Ubuntu has unzip by default, last I checked, and of course
Windows Explorer supports unzipping since I don't know when (ME? XP?).
Even *BSD has a partial implementation of unzip too (libarchive?). In
other words, I don't personally see a huge need for kunzip, but the
more the merrier!   :-)

> Well, adding is easy (you just strip the directory from the end, append
> your file and recreate the directory).
> Deleting is trickier, indeed.. (need to move all data around to cover
> the empy hole left by the deleted file, and recalculate all data offsets
> in both the central directory and per-file headers...).

I'm not sure how well most tools handle this. The naive approach would
be to temporarily duplicate the entire file, which may be unfeasible
with very large sizes.


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Mateusz Viste
Hi,

Just my $0.02. Mostly I totally agree with Rugxulo, who evidently knows 
much more about stuff than he modestly pretends ;)

This have not much to do with the initial OP's question, but 
nevertheless, archiving is an interesting topic :) - for me especially, 
since I had to do much work with zip/gzip/deflate/lzma for FDNPKG.

On 08/30/2013 06:42 AM, Rugxulo wrote:
> IIRC, the default mode of 7za is -mx5 and .7z format using LZMA [or
> LZMA2 in newer alphas] method, which means (among other things) 16 MB
> dictionary, aka 2^24, aka LZMA:24 (but you can adjust that, e.g.
> "-ms=32m -m0d=32m" [LZMA:25] seems to compress slightly better, if the
> file is bigger than 16 MB).

This is right. But "bigger dictionary" doesn't necessarily mean 
'better'. well, sure, it means 'potentially better compression ratio', 
because we can seek back redundant data in wider spans, but it also 
means 'tremendously higher memory requirements'. This is why I don't 
create FDNPKG packages using LZMA (unless for pure experimentation), 
even though it's 5-15% smaller than DEFLATE. Trying to uncompress an 
LZMA file on a <16MB RAM machine is hell (or simply impossible if no 
virtual memory is available).

> Even .ZIP format can officially support Bzip2 or even LZMA
> method (or others).

That's exactly what FDNPKG supports - LZMA-compressed files inside ZIP 
'slots'. This allows using the cool ZIP structure for handling files 
(and extracting only these we need - eg. without SOURCES), but still 
benefiting from the LZMA compression ratio.

> .gz seems mostly to be meant for streaming as it doesn't really
> support anything beyond a very minimal header. Though of course I
> think? you can concat several .gz files, and it will still decompress
> them all correctly, but that's rare (in my limited experience).

indeed, .gz is designed to compress only a single file. No 'directory 
storage' capabilities there. Still, for 'single file' compression I'd 
use gzip over zip anytime. It's fits better, because it provides all we 
need, without any additional garbage (mostly limited to filename + CRC32 
+ a few flags). BTW, in a future version, FDNPKG will support 
gz-compressed index files (provides integrity and faster refreshing time 
of online repositories!)

> "Usually" but not always. 7-Zip provides its own "improved" Deflate,
> which is slightly better (tries harder, gives up less easily) than the
> algorithm typically used in such encoders.

True again. And actually, I use 7za myself to create all FDNPKG packages 
(as zip files, with deflate), because as you say, it provides a (small) 
improvement over eg. info-zip. like 5-8% or so.

On a side note: some decompressors have troubles handling the 7zip 
'deflated zip' files sometimes. For example kunzip crashes on some zip 
files created by 7za, while it doesn't crash on any other files created 
with 'classic' zippers.

> It's easy but not totally super duper simple to add or remove because
> you still have to disassemble and reassemble the archive if you insert
> or delete anything, not to mention updating the (overall) central
> directory structure (CDS) at the end. And potential .ZIP comments make
> that even slightly harder.

Well, adding is easy (you just strip the directory from the end, append 
your file and recreate the directory).
Deleting is trickier, indeed.. (need to move all data around to cover 
the empy hole left by the deleted file, and recalculate all data offsets 
in both the central directory and per-file headers...).

regards,
Mateusz


--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Rugxulo
Hi,

On Thu, Aug 29, 2013 at 3:07 PM, Karen Lewellen
 wrote:
>
> Let me table this discussion where my question is concerned.
> there is another copy of this program zipped using regular pk zip for dos
> and as  a strict dos port.

p7z458c.zip is what I see at the link you gave. Honestly, it may work,
but that's a fairly older version (e.g. no LZMA2), and it's overkill
if all you need is to decompress. The previous link I gave to iBiblio
(also pointed to by FreeDOS Software list) is more current. At least,
I can't personally think of any reason why someone would prefer 4.58
over 4.61 or 4.65 or (better) 9.04, 9.13, or (latest) 9.20.1.

Again, I say, you're probably better off browsing iBiblio for what you
want (presumably p7zip 9.20.1 or 7zdecode 9.22):

http://ftp.ibiblio.org/pub/micro/pc-stuff/freedos/files/util/file/7zip/

> It is on the same site where I referenced a long time ago the dos ports of
> mplayer and other  dos related desires.

Probably inertia, presumably it works well enough for average use, but
that old version is definitely not maintained nor recommended. The
only people who (AFAIK) have bothered attempting to officially rebuild
p7zip with DJGPP are (in order) Blair, Khusraw, and myself. Oops,
forgot Mik, but I think even his build had some flaws.

> You will find a .ZIP of 7ZA for DOS on the same website:
> http://www.ausreg.com/dos_ports/index.htm
>
> Thanks for the other answers, but this option should meet my needs.

Well, it's almost like you missed my email entirely! Oh well,
"whatever works" is good enough, but I don't recommend older versions
without an explicit reason, esp. when I have some (minor) reasons to
not prefer them (a few bugs, a few lacks).

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Rugxulo
Hi,
   BTW, this is just random ramblings from me, I don't claim to be any
sort of expert (esp. compression programming), more like a "power
user" (if even that).

On Thu, Aug 29, 2013 at 4:23 PM, Eric Auer  wrote:
>
> [Tom]
>>> the very idea of 7zip is to tar first (internally), then compress.
>
> [Bojan]
>> Very idea of 7zip is a specific compression algorithm, not a way
>> the compressing utilites work. :)
>
> Actually you are BOTH right. As Rugxulo already mentioned, there is
> a difference between archives where each file inside is compressed
> separately and "compact" archives. The latter put all files in one
> big block of data and compress that. The default mode of 7ZIP is
> to make a COMPACT archive with a SPECIFIC compression algorithm.

IIRC, the default mode of 7za is -mx5 and .7z format using LZMA [or
LZMA2 in newer alphas] method, which means (among other things) 16 MB
dictionary, aka 2^24, aka LZMA:24 (but you can adjust that, e.g.
"-ms=32m -m0d=32m" [LZMA:25] seems to compress slightly better, if the
file is bigger than 16 MB).

Bzip2 is BWT method with blocksize 100k up to 900k only. Gzip is
Deflate with 32 kb dictionary. Zip has had various methods, but the
default has been Deflate for a very long time.

Just to clarify, .7z format can have Bzip2 or Deflate methods (or Ppmd
or others). Even .ZIP format can officially support Bzip2 or even LZMA
method (or others).

> ZIP is non-compact and otherwise comparable to TAR.GZ in strength
> of algorithm.

Yes, hence .ZIP is slightly worse compression overall but provides
some file separation which can (in limited use) make it easier to
recover some files from a corrupted archive. Though normally (some of
the fancier) archivers add some minimal redundancy data instead
(though even that is limited and not really a good replacement for
full backups).

.gz seems mostly to be meant for streaming as it doesn't really
support anything beyond a very minimal header. Though of course I
think? you can concat several .gz files, and it will still decompress
them all correctly, but that's rare (in my limited experience).

Of course, only .tar saves *nix permissions info, as .ZIP was less
friendly (by default) since it was DOS-oriented. Yes, you can kludge
it with your own workarounds (and who knows what can optionally be
saved in "extra fields", better check appnote.txt), but due to that, I
think, most people on *nix still don't use .ZIP very much.

.gz (LZ77?) was actually just meant to be a patent-free replacement
for "compress" .Z, which used (IIRC,  now unpatented) LZW.

> So if you compress many similar files, TAR.GZ gives you the smaller archive.

"Usually" but not always. 7-Zip provides its own "improved" Deflate,
which is slightly better (tries harder, gives up less easily) than the
algorithm typically used in such encoders. I'm not sure of the details
(no EOS markers?). Long story short: .ZIP has bigger internal headers
but it's very minor difference (overall), so it's still technically
possible to use (for instance) 7-Zip to create a .ZIP that is actually
smaller than a (normal) "GNU gzip"-produced .gz file (for the same
input).

> More modern algorithms like BZIP2 will
> often compress data better, but will spend much more RAM and CPU
> time in doing that. So TAR.BZ2 is smaller than TAR.GZ which uses
> GZIP.

"Usually" smaller. And yes, Bzip2 wasn't really ever ported (AFAIK) to
anything less than 32-bit machines, not the least reason of which is
the 900 kb max blocksize (versus 32 kb) and of course its slower speed
overall. At risk of stating the obvious, there's always a tradeoff
between compressed output size and (de)compression speed and RAM
usage.

At risk of sounding snobbish (unintentionally), I think Gzip (Deflate)
is very weak. For very large files, it's inefficient, and thus I
wouldn't recommend it directly these days. Though a 35 MB file vs. 50
MB is (at least to most "modern" people) not a difference worth
worrying about (sadly). These days you can't do anything without a
fast network connection and tons of RAM and tons of disk space.

> You do not usually have to make a TAR and GZIP or BZIP2 it
> separately with a pipeline: Both functions are usually combined
> behind one command, in particular in DOS where pipelines are not
> efficient to use. In Linux or Windows, it could happen that the
> modules internally communicate via pipes without you noticing:

Dunno, honestly! It's complicated. But GNU tar does allegedly support
extracting only certain files. Of course, I'm not a big *nix (nor tar)
user, so I never use that feature. Well, DJGPP's "djtar -x -o
blah/readme.txt -p blah.tgz" is sometimes useful (decompresses and
unarchives all at once).   :-)

> In both scenarios, you do not need to have the big, uncompressed
> "throw all files in one TAR" file lying around on your harddisk
> while processing a TAR.GZ (TGZ) or TAR.BZ2 (TBZ) file, luckily!

We're way beyond the point of "most" people caring. How big is latest
Linux kernel sources 

Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Eric Auer

Hi Bojan,

[Tom]
>> the very idea of 7zip is to tar first (internally), then compress.

[Bojan]
> Very idea of 7zip is a specific compression algorithm, not a way
> the compressing utilites work. :) 

Actually you are BOTH right. As Rugxulo already mentioned, there is
a difference between archives where each file inside is compressed
separately and "compact" archives. The latter put all files in one
big block of data and compress that. The default mode of 7ZIP is
to make a COMPACT archive with a SPECIFIC compression algorithm.

ZIP is non-compact and otherwise comparable to TAR.GZ in strength
of algorithm. So if you compress many similar files, TAR.GZ gives
you the smaller archive. More modern algorithms like BZIP2 will
often compress data better, but will spend much more RAM and CPU
time in doing that. So TAR.BZ2 is smaller than TAR.GZ which uses
GZIP. You do not usually have to make a TAR and GZIP or BZIP2 it
separately with a pipeline: Both functions are usually combined
behind one command, in particular in DOS where pipelines are not
efficient to use. In Linux or Windows, it could happen that the
modules internally communicate via pipes without you noticing:

In both scenarios, you do not need to have the big, uncompressed
"throw all files in one TAR" file lying around on your harddisk
while processing a TAR.GZ (TGZ) or TAR.BZ2 (TBZ) file, luckily!

However, compact archives also have disadvantages: You cannot
remove files from them without recompressing the whole thing.
Adding files might also work less well than for "uncompact"
formats. Each of multiple files archived in a ZIP exists in
a separate area of the ZIP, so it is easy to add or remove a
file from a ZIP or unpack a single file without having to go
through the whole ZIP and unpack all data to find it.

As Rugxulo mentions, 7ZIP also supports "less compact" ways of
archiving. That could mean storing information about contents
in a more accessible way and compressing the big, compact blob
of data in not-so-big chunks. This could allow you to unpack
only the 10 MB of your 100 MB BIGSTUFF.7Z file where you have
that 5 MB COOLDOC.TXT that you want to extract, thanks to some
sort of table of contents in the file and thanks to having an
uncompression start point every few MB. Note: I simplify here!

Regards, Eric

PS: Note that the 7ZIP tool HAS an option "delete file from
archive" but you will see that this is ONLY happy when used
for ZIP files. When used on 7Z or TGZ, it will work worse.



--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Bojan Popovic
Hey Tom,

> the very idea of 7zip is to tar first (internally), then compress.
>

Very idea of 7zip is a specific compression algorithm, not a way
the compressing utilites work. :) 

> this is a DOS mailing list. 

Yep, and that was an advice that might be useful in both DOS and Linux
(you mentioned Puppy Linux).

Take it easy man. Didn't mean to insult you. NHF intended.

Bojan.

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Karen Lewellen
Let me table this discussion where my question is concerned.
there is another copy of this program zipped using regular pk zip for dos 
and as  a strict dos port.
It is on the same site where I referenced a long time ago the dos ports of 
mplayer and other  dos related desires.


You will find a .ZIP of 7ZA for DOS on the same website:
http://www.ausreg.com/dos_ports/index.htm


Thanks for the other answers, but this option should meet my needs.
Karen

On Thu, 29 Aug 2013, Bojan Popovic wrote:

> Hi.
>
> On Thu, 29 Aug 2013 11:34:14 -0400
> dmccunney  wrote:
>
>> The problem with tar. files is you must first uncompress the
>> tar file, then extract what you want (and possibly then remove the
>> uncompressed tar file.)
>
> Not really. If you use tar for decompression (and not 7za) it will
> automatically "pipe" the output of tar to appropriate decompression
> program. DJGPP ports of GNU tar should have this option too, but I
> think this will work much better under native Linux (actually any
> modern Unix with a recent version of GNU or BSD tar).
>
> Just type 'tar -xf archive.tar.xz' and you're ok. Of course, you will
> need to have gzip, bzip2 or xz installed (Should be installed by
> default in puppy. DOS ports are available from DJGGP file repository).
>
> Bojan.
>
> --
> Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
> Discover the easy way to master current and previous Microsoft technologies
> and advance your career. Get an incredible 1,500+ hours of step-by-step
> tutorial videos with LearnDevNow. Subscribe today and save!
> http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
> ___
> Freedos-user mailing list
> Freedos-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/freedos-user
>
>

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Tom Ehlert
>> The problem with tar. files is you must first uncompress the
>> tar file, then extract what you want (and possibly then remove the
>> uncompressed tar file.) 

> Not really. If you use tar for decompression (and not 7za) it will
> automatically "pipe" the output of tar to appropriate decompression
> program.
when compressing, *nobody* compresses first, then tar

the very idea of 7zip is to tar first (internally), then compress.


> DJGPP ports of GNU tar should have this option too, but I
> think this will work much better under native Linux (actually any
> modern Unix with a recent version of GNU or BSD tar).

this is a DOS mailing list. piping works different in DOS.


> Just type 'tar -xf archive.tar.xz' and you're ok. Of course, you will
> need to have gzip, bzip2 or xz installed (Should be installed by
> default in puppy. DOS ports are available from DJGGP file repository).

> Bojan.

Tom


--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread Bojan Popovic
Hi.

On Thu, 29 Aug 2013 11:34:14 -0400
dmccunney  wrote:

> The problem with tar. files is you must first uncompress the
> tar file, then extract what you want (and possibly then remove the
> uncompressed tar file.) 

Not really. If you use tar for decompression (and not 7za) it will
automatically "pipe" the output of tar to appropriate decompression
program. DJGPP ports of GNU tar should have this option too, but I
think this will work much better under native Linux (actually any
modern Unix with a recent version of GNU or BSD tar).

Just type 'tar -xf archive.tar.xz' and you're ok. Of course, you will
need to have gzip, bzip2 or xz installed (Should be installed by
default in puppy. DOS ports are available from DJGGP file repository). 

Bojan.

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-29 Thread dmccunney
On Thu, Aug 29, 2013 at 1:47 AM, Rugxulo  wrote:
>> I prefer to just make a 7z archive, instead of a bz2'd tar file.  The
>> latter requires you to uncompress the tar file then extract it.  What
>> if you just want one file in the archive?  And 7z archives made with
>> max compression are comparable in size to bz2 files.

<...>

> The main problem is that everyone's needs are different, so there are
> many competing archiving formats, even using same LZMA compression
> method (although both LZMA and LZMA2 exist nowadays), e.g XZ or Lzip.
> By default, .7z files don't preserve *nix permissions, so they don't
> usually use that there, usually .tar.lz or .tar.xz :

The problem with tar. files is you must first uncompress the
tar file, then extract what you want (and possibly then remove the
uncompressed tar file.)  I ran into that with Puppy Linux, where one
of the Puppy forum folks had created a ginormous tar,bz2 file of
libraries built for Puppy, to help resolve dependency problems when
the app you installed wanted a library you didn't have.  I didn't have
enough space in the file system to uncompress and then extract.  I
converted it to a 7zip archive where I could open it and extract the
libraries I needed without  having to first decompress the entire tar
file.  I could always adjust permissions after the file was in place
if that was needed.
__
Dennis
https://plus.google.com/u/0/105128793974319004519

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-28 Thread Rugxulo
Hi,

On Wed, Aug 28, 2013 at 10:09 PM, dmccunney  wrote:
> On Wed, Aug 28, 2013 at 9:52 PM, Karen Lewellen
>  wrote:
>
>> Is this different from the pzip utility I found referenced when I googled
>> 7zip in dos?
>
> I don't believe so.  DJ Delorie's DJGPP build of p7zip is the only one
> I'm aware of for DOS

p7zip (where "p" is for POSIX), in our case, was compiled with DJGPP,
which is officially a DOS (32-bit DPMI, partial POSIX) compiler. Just
for clarity, I'm not aware of any "pzip" archiver.

Since p7zip is a very POSIX-heavy port of the original 7-Zip (7za?)
cmdline tool, it's not perfectly easy to port for DOS. So it's a
little buggy, but overall it seems to "mostly" work.

>> I am not using freedos, but ms dos 7.1  will it make a difference?
>
> It shouldn't.

I don't know without trying, but I'm not personally aware of any
design decisions that should cause any (extra) problems.

>> I had to laugh as the pzip package requires bz2 for the unzipping, which
>> is something pzip does.

The sources are .tar.bz2, if that's what you meant. You don't need
that file. The latest (imperfect) unofficial DJGPP compile is 9.20.1 :

http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/util/file/7zip/9.20.1/testing/p7z9201-latest.zip

That's my own (wimpy) build, mostly using same everything (e.g. FSU
Pthreads lib) as Khusraw's 9.13 build. It should hopefully work
slightly better with backslashes in paths, as per DOS custom, but
there are some other minor irritations due to POSIX assumptions /
limitations (that haven't been fixed due to tedious complexity).

In short, it may? actually be more comfortable to use the official
native Win32 console 7ZA.EXE (7za920.zip) under Japheth's HX in DOS.

http://sourceforge.net/projects/sevenzip/files/7-Zip/9.20/7za920.zip/download
http://www.japheth.de/HX.html

> I prefer to just make a 7z archive, instead of a bz2'd tar file.  The
> latter requires you to uncompress the tar file then extract it.  What
> if you just want one file in the archive?  And 7z archives made with
> max compression are comparable in size to bz2 files.

The max (and default) blocksize for .bz2 files is 900 kb, but 7-Zip
(LZMA) can go much higher, hence better compression. Plus, you don't
have to compress the whole file as solid compression, you can even do
semi-solid, to keep decompression RAM usage down.

The main problem is that everyone's needs are different, so there are
many competing archiving formats, even using same LZMA compression
method (although both LZMA and LZMA2 exist nowadays), e.g XZ or Lzip.
By default, .7z files don't preserve *nix permissions, so they don't
usually use that there, usually .tar.lz or .tar.xz :

http://ftpmirror.gnu.org/emacs/

emacs-24.3.tar.gz   11-Mar-2013 02:31   50M
emacs-24.3.tar.xz   11-Mar-2013 02:15   34M

P.S. If all you need to do is decompress a .7z file, try 7zdecode,
it's much smaller:

http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/util/file/7zip/7zdecode/7zdec922.zip

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-28 Thread dmccunney
On Wed, Aug 28, 2013 at 9:52 PM, Karen Lewellen
 wrote:
> Is this different from the pzip utility I found referenced when I googled
> 7zip in dos?

I don't believe so.  DJ Delorie's DJGPP build of p7zip is the only one
I'm aware of for DOS

> I am not using freedos, but ms dos 7.1  will it make a difference?

It shouldn't.  FreeDOS does its best to be MS-DOS compatible.  An open
source OS that *is* MS-DOS compatible is the point odf developing
FreeDOS to begin with.

> I had to laugh as the pzip package requires bz2 for the unzipping, which
> is something pzip does.

I prefer to just make a 7z archive, instead of a bz2'd tar file.  The
latter requires you to uncompress the tar file then extract it.  What
if you just want one file in the archive?  And 7z archives made with
max compression are comparable in size to bz2 files.

> Thanks,
> Karen
__
Dennis
https://plus.google.com/u/0/105128793974319004519

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-28 Thread Karen Lewellen
Is this different from the pzip utility I found referenced when I googled 
7zip in dos?
I am not using freedos, but ms dos 7.1  will it make a difference?
I had to laugh as the pzip package requires bz2 for the unzipping, which 
is something pzip does.
Thanks,
Karen

On Wed, 28 Aug 2013, dmccunney wrote:

> On Wed, Aug 28, 2013 at 7:39 PM, Karen Lewellen
>  wrote:
>> Hi folks,
>> Can anyone direct me to a pure dos package of 7zip?  I need to unzip a
>> file compressed with it.
>
> The's a DJGPP build as part of FreeDOS, here:
> http://www.freedos.org/software/?prog=7-zip
>
>> Thanks,
>> Karen
> __
> Dennis
> https://plus.google.com/u/0/105128793974319004519
>
> --
> Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
> Discover the easy way to master current and previous Microsoft technologies
> and advance your career. Get an incredible 1,500+ hours of step-by-step
> tutorial videos with LearnDevNow. Subscribe today and save!
> http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
> ___
> Freedos-user mailing list
> Freedos-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/freedos-user
>
>

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] 7zip in pure dos?

2013-08-28 Thread dmccunney
On Wed, Aug 28, 2013 at 7:39 PM, Karen Lewellen
 wrote:
> Hi folks,
> Can anyone direct me to a pure dos package of 7zip?  I need to unzip a
> file compressed with it.

The's a DJGPP build as part of FreeDOS, here:
http://www.freedos.org/software/?prog=7-zip

> Thanks,
> Karen
__
Dennis
https://plus.google.com/u/0/105128793974319004519

--
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user