[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[5189] lzip support
From: |
karl |
Subject: |
[5189] lzip support |
Date: |
Fri, 22 Feb 2013 23:59:33 +0000 |
Revision: 5189
http://svn.sv.gnu.org/viewvc/?view=rev&root=texinfo&revision=5189
Author: karl
Date: 2013-02-22 23:59:31 +0000 (Fri, 22 Feb 2013)
Log Message:
-----------
lzip support
Modified Paths:
--------------
trunk/ChangeLog
trunk/NEWS
trunk/doc/info-stnd.texi
trunk/doc/texinfo.txi
trunk/info/filesys.c
trunk/install-info/install-info.c
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2013-02-22 23:53:54 UTC (rev 5188)
+++ trunk/ChangeLog 2013-02-22 23:59:31 UTC (rev 5189)
@@ -1,3 +1,11 @@
+2013-02-22 Antonio Diaz Diaz <address@hidden> (tiny change)
+
+ * info/filesys.c (compress_suffixes): Add .lz/lzip.
+ * install-info/install-info.c (open_possibly_compressed_file):
+ Add lzip support.
+ * doc/info-stnd.texi,
+ * doc/texinfo.txi: mention it.
+
2013-02-22 Eli Zaretskii <address@hidden>
* install-info/ginstall-info.exe.manifest: new file.
Modified: trunk/NEWS
===================================================================
--- trunk/NEWS 2013-02-22 23:53:54 UTC (rev 5188)
+++ trunk/NEWS 2013-02-22 23:59:31 UTC (rev 5189)
@@ -22,7 +22,14 @@
http://www.gnu.org/software/texinfo/manual/texinfo/html_node/Document-Permissions.html
-------------------------------------------------------------------------------
+5.1
+* info:
+ . lzip (.lz) compression supported.
+
+* install-info:
+ . lzip (.lz) compression supported.
+
5.0 (16 February 2013)
* Language:
. Texinfo commands are supported in node names.
Modified: trunk/doc/info-stnd.texi
===================================================================
--- trunk/doc/info-stnd.texi 2013-02-22 23:53:54 UTC (rev 5188)
+++ trunk/doc/info-stnd.texi 2013-02-22 23:59:31 UTC (rev 5189)
@@ -217,10 +217,11 @@
@file{.info}, @file{-info}, @file{/index}, and @file{.inf}. For every
known extension, Info looks for a compressed file, if a regular file
isn't found. Info supports files compressed with @code{gzip},
address@hidden, @code{bzip2}, @code{lzma}, @code{compress} and @code{yabba}
-programs, assumed to have @file{.z}, @file{.gz}, @file{.xz},
address@hidden, @file{.lzma}, @file{.Z}, or @file{.Y} extensions,
-possibly after one of the known Info files extensions.
address@hidden, @code{bzip2}, @code{lzip}, @code{lzma}, @code{compress} and
address@hidden programs, assumed to have @file{.z}, @file{.gz},
address@hidden, @file{.bz2}, @file{.lz}, @file{.lzma}, @file{.Z}, or
address@hidden extensions, possibly after one of the known Info files
+extensions.
On MS-DOS, Info allows for the Info extension, such as @code{.inf},
and the short compressed file extensions, such as @file{.z} and
Modified: trunk/doc/texinfo.txi
===================================================================
--- trunk/doc/texinfo.txi 2013-02-22 23:53:54 UTC (rev 5188)
+++ trunk/doc/texinfo.txi 2013-02-22 23:59:31 UTC (rev 5189)
@@ -19159,6 +19159,7 @@
@cindex Compressed dir files, reading
@cindex XZ-compressed dir files, reading
@cindex Bzipped dir files, reading
address@hidden Lzip-compressed dir files, reading
@cindex LZMA-compressed dir files, reading
@cindex Dir files, compressed
If any input file is compressed with @code{gzip} (@pxref{Top,,, gzip,
@@ -19167,8 +19168,8 @@
automatically leaves it compressed after writing any changes. If
@var{dir-file} itself does not exist, @code{install-info} tries to
open @address@hidden, @address@hidden,
address@hidden@var{dir-file}.bz2}, and @address@hidden, in that
-order.
address@hidden@var{dir-file}.bz2}, @address@hidden, and
address@hidden@var{dir-file}.lzma}, in that order.
Options:
Modified: trunk/info/filesys.c
===================================================================
--- trunk/info/filesys.c 2013-02-22 23:53:54 UTC (rev 5188)
+++ trunk/info/filesys.c 2013-02-22 23:59:31 UTC (rev 5189)
@@ -57,8 +57,10 @@
static COMPRESSION_ALIST compress_suffixes[] = {
#if STRIP_DOT_EXE
{ ".gz", "gunzip" },
+ { ".lz", "lunzip" },
#else
{ ".gz", "gzip -d" },
+ { ".lz", "lzip -d" },
#endif
{ ".xz", "unxz" },
{ ".bz2", "bunzip2" },
Modified: trunk/install-info/install-info.c
===================================================================
--- trunk/install-info/install-info.c 2013-02-22 23:53:54 UTC (rev 5188)
+++ trunk/install-info/install-info.c 2013-02-22 23:59:31 UTC (rev 5189)
@@ -425,6 +425,11 @@
len -= 4;
ret[len] = 0;
}
+ else if (len > 3 && FILENAME_CMP (ret + len - 3, ".lz") == 0)
+ {
+ len -= 3;
+ ret[len] = 0;
+ }
else if (len > 5 && FILENAME_CMP (ret + len - 5, ".lzma") == 0)
{
len -= 5;
@@ -701,6 +706,12 @@
}
if (!f)
{
+ free (*opened_filename);
+ *opened_filename = concat (filename, ".lz", "");
+ f = fopen (*opened_filename, FOPEN_RBIN);
+ }
+ if (!f)
+ {
free (*opened_filename);
*opened_filename = concat (filename, ".lzma", "");
f = fopen (*opened_filename, FOPEN_RBIN);
@@ -782,6 +793,14 @@
*compression_program = "bzip";
#endif
+ else if (data[0] == 0x4C && data[1] == 0x5A && data[2] == 0x49
+ && data[3] == 0x50 && data[4] == 1) /* "LZIP" */
+#ifndef STRIP_DOT_EXE
+ *compression_program = "lzip.exe";
+#else
+ *compression_program = "lzip";
+#endif
+
/* We (try to) match against old lzma format (which lacks proper
header, two first matches), as well as the new format (last match). */
else if ((data[9] == 0x00 && data[10] == 0x00 && data[11] == 0x00
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [5189] lzip support,
karl <=