Commit Graph

10 Commits

Author SHA1 Message Date
Greg Beaver
9c62ef1124 add externally parsed files to temporary manifest (this will be made
optional and must be explicitly enabled per-phar)
2008-02-18 03:37:51 +00:00
Steph Fox
6acac494ab Fix ZTS build 2008-02-18 00:46:07 +00:00
Greg Beaver
54ff8c3a8f begin work on ability to mount files from external locations as if they were inside of a phar archive 2008-02-15 05:01:40 +00:00
Greg Beaver
f72ce59e95 remove refcount hack to workaround zlib memleak fixed in zlib
intercepted file functions now fall through if the file is not found in the phar, this allows access to external libraries
actually use include_path for locating files for inclusion and in file_get_contents/fopen when include_path is requested.
This allows applications like Zend Framework MVC implementation to function properly
2008-02-13 15:00:31 +00:00
Greg Beaver
592635d0c0 fix TSRM build 2008-02-12 05:38:01 +00:00
Greg Beaver
2f1ec934af fix some of the failing tests due to non-reopened phar fp 2008-02-12 05:16:53 +00:00
Greg Beaver
d388ec586f move creation of phar archive to the point at which it is committed to disk, instead of
at the moment it is attempted access. (making some real progress now, all tests pass on unix)
2008-02-11 06:53:56 +00:00
Antony Dovgal
e493059f55 check for empty/null path
still some leaks are left
2008-02-01 11:36:45 +00:00
Greg Beaver
f4e4ad0cd1 fix PharFileInfo->setAlias (was wildly broken)
fix directory creation in zip archives
update zip tests to use phar to create the zip, and then copy to a new file
2008-01-28 20:18:15 +00:00
Greg Beaver
6cdabede4c remove ext/zip dependency entirely, write better native zip support
re-organize, create util.c, move entry_info/archive_data/entry_data access methods to this file
refactor entry->fp, now this is abstracted with phar_get_efp() and phar_seek_efp(), fixes all weird dependency issues
permanently solve the "millions of file pointers" issue for read access.  All compressed files are read into a single
temporary stream, and their constraints are controlled by the entry->fp abstraction

Improvements in this zip implementation over ext/zip:
 * full read/write support for bzip2 compressed files
 * much more efficient access for accessing only a few files within large zip files, as crc/header validation is
   done just-in-time
 * full stream support for opendir/rename/rmdir/mkdir as well as all of the other stream funcs
 * full support for setting file perms via Phar::chmod(), stored as zip-standard extra field
 * no problem with large zips and many open file pointers

# TODO: add big-endian system support for tar/zip file format headers, otherwise the implementation is complete
# TODO: test on windows and fix any windows-specific issues
# TODO: verify zips created work with unzip/winzip/windows explorer and so on
2008-01-28 08:52:08 +00:00