Eric Biggers [Wed, 22 Aug 2012 04:40:57 +0000 (23:40 -0500)]
Rewritten functions for reading and writing resources
Functions for reading and writing compressed and uncompressed resources have
been rewritten to reduce code duplication and simplify the interface to the rest
of the code.
Eric Biggers [Tue, 21 Aug 2012 22:17:36 +0000 (17:17 -0500)]
Add modified security.c from NTFS-3g
This simplifies WIM application because we can modifiy
ntfs_set_file_attributes() and ntfs_set_file_security() to take ntfs_inodes
instead of pathnodes, and we can also get rid of the SECURITY_API structure.
Eric Biggers [Sun, 19 Aug 2012 22:32:15 +0000 (17:32 -0500)]
Hard link fix
I'm noticing weird things in the Windows 7 install.wim file where WIM dentries
are marked as being in the same hard link set, but the dentries have differences
such as different file streams or different file permissions. I'm working
around the problem by splitting these offending dentries into their own hard
link groups.
Eric Biggers [Sat, 18 Aug 2012 00:46:24 +0000 (19:46 -0500)]
Some preparations for supporting NTFS capture and apply.
- Restore support for reading and writing alternate data streams (this was in
early versions of wimlib but had been removed for not actually being used...)
- Remove the --disable-security-data option. I don't think anyone would really
want this; instead we just copy the existing security data by default. New
files will be created without security data except when capturing from NTFS
(not yet implemented).
- Read and write the reparse tag field.
- Remove --verify, --config, --norpfix from imagex commands. I'm still not
planning to do anything with these, so remove them to simplify the commands.
Who knows, maybe I'll add these back later though...
- wimlib_set_link_type(), wimlib_set_verbose(), wimlib_set_output_dir() removed.
You now pass flags or the output directory to the relevant functions such as
wimlib_extract_image().
- --enable-ntfs-3g configure option
- --ntfs options on `imagex capture' and `imagex apply' (Actual operations not
yet implemented!)
Eric Biggers [Tue, 14 Aug 2012 00:20:28 +0000 (19:20 -0500)]
Test suite
This commit introduces a primitive test suite for wimlib. It consists of a
shell script that runs some tests on the 'imagex' program. Run it with `make
check'; only works with in-tree builds.
As a result of writing the test suite I also fixed two issues:
mount.c: Allow opening empty files in read-only filesystem
mount.c: Implement utimens() for WIM filesystem
Eric Biggers [Mon, 13 Aug 2012 20:54:21 +0000 (15:54 -0500)]
Various minor changes and fixes.
- Automatic newline when calling DEBUG() or ERROR()
- Use ERROR_WITH_ERRNO instead of "%m" conversion specifier
- Security data cannot be NULL anymore; just allocate one with zero entries.
- Cleaned up failure case code in some functions, also documented whether the
WIMs are valid after wimlib_add_image(), wimlib_delete_image(), and
wimlib_export_image() fails or not.
Eric Biggers [Sat, 26 May 2012 18:49:31 +0000 (13:49 -0500)]
Use public domain SHA1 code
I believe that technically I shouldn't have been using the coreutils SHA1 code
in wimlib because the coreutils code is GPLv3 while wimlib is LGPLv2.1+. So I
replaced it with public domain code.
This only applies to building SHA1 support into wimlib. I would recommend using
an external libcrypto if possible.
Eric Biggers [Sun, 20 May 2012 15:53:02 +0000 (10:53 -0500)]
Empty file fix
imagex.exe expects empty files to have a zeroed-out hash (despite the fact this
isn't actually the hash of the empty file) and no lookup table entry. This
patch makes this the case for the WIMs that wimlib writes.
Eric Biggers [Sun, 20 May 2012 15:08:20 +0000 (10:08 -0500)]
Support for copying security data
Previous versions of wimlib had preliminary support for copying security data,
before it was removed. This version reintroduces this support, enabled by
default but configurable by the configure script.
Also various documentation fixes.
Allow reading WIMs with security data total length = 0 (it defaults to 8 if it
says 0)
Eric Biggers [Sat, 19 May 2012 17:28:05 +0000 (12:28 -0500)]
Support for joining WIMs.
- join command for imagex
- wimlib_join() function
- wimlib_get_part_number() functions
- Various modifications in other files to make this possible. wimlib_open_wim()
will open a split wim given the WIMLIB_OPEN_FLAG_SPLIT_OK flag.
- Allow finish_write() to skip writing lookup table in case it is written
elsewhere (join_wims())
- Show more header flags in wimlib_print_header() (including
WIMLIB_HDR_FLAG_SPANNED)
- Allow images with no name, and when extracting them, extract to directory
named after image number rather than name