2008-04-22 06:21:50 +04:00
|
|
|
README
|
2008-04-24 23:40:13 +04:00
|
|
|
======
|
2008-04-22 06:21:50 +04:00
|
|
|
|
|
|
|
This project was first conceived to manipulate Apple's software restore
|
|
|
|
packages (IPSWs) and hence much of it is geared specifically toward that
|
|
|
|
format. Useful tools to read and manipulate the internal data structures of
|
|
|
|
those files have been created to that end, and with minor changes, more
|
|
|
|
generality can be achieved in the general utility. An inexhaustive list of
|
|
|
|
such changes would be selectively enabling folder counts in HFS+, switching
|
|
|
|
between case sensitivity and non-sensitivity, and more fine-grained control
|
|
|
|
over the layout of created dmgs.
|
|
|
|
|
2008-04-24 23:40:13 +04:00
|
|
|
**THE CODE HEREIN SHOULD BE CONSIDERED HIGHLY EXPERIMENTAL**
|
2008-04-22 06:21:50 +04:00
|
|
|
|
|
|
|
Extensive testing have not been done, but comparatively simple tasks like
|
|
|
|
adding and removing files from a mostly contiguous filesystem are well
|
|
|
|
proven.
|
|
|
|
|
2008-04-26 17:43:50 +04:00
|
|
|
Please note that these tools and routines are currently only suitable to be
|
|
|
|
accessed by other programs that know what they're doing. I.e., doing
|
|
|
|
something you "shouldn't" be able to do, like removing non-existent files is
|
|
|
|
probably not a very good idea.
|
|
|
|
|
2008-04-22 06:21:50 +04:00
|
|
|
LICENSE
|
|
|
|
-------
|
|
|
|
|
2008-05-17 00:11:30 +04:00
|
|
|
This work is released under the terms of the GNU General Public License,
|
|
|
|
version 3. The full text of the license can be found in the LICENSE file.
|
2008-04-22 06:21:50 +04:00
|
|
|
|
2008-04-27 18:36:00 +04:00
|
|
|
DEPENDENCIES
|
|
|
|
------------
|
|
|
|
|
|
|
|
The HFS portion will work on any platform that supports GNU C and POSIX
|
|
|
|
conventions. The dmg portion has dependencies on zlib (which is included) and
|
|
|
|
libcrypto from openssl (which is not). If libcrypto is not available, remove
|
|
|
|
the -DHAVE_CRYPT flags from the CFLAGS of the makefiles. All FileVault
|
|
|
|
related actions will fail, but everything else should still work. I imagine
|
|
|
|
most places have libcrypto, and probably statically compiled zlib was a dumb
|
|
|
|
idea too.
|
|
|
|
|
2008-04-22 06:21:50 +04:00
|
|
|
USING
|
|
|
|
-----
|
|
|
|
|
2008-04-27 18:25:00 +04:00
|
|
|
The targets of the current repository are three command-line utilities that
|
2008-04-22 06:21:50 +04:00
|
|
|
demonstrate the usage of the library functions (except cmd_grow, which really
|
|
|
|
ought to be moved to catalog.c). To make compilation simpler, a complete,
|
|
|
|
unmodified copy of the zlib distribution is included. The dmg portion of the
|
2008-04-27 18:25:00 +04:00
|
|
|
code has dependencies on the HFS+ portion of the code. The "hdutil" section
|
|
|
|
contains a version of the HFS+ utility that supports directly reading from
|
|
|
|
dmgs. It is separate from the HFS+ utility in order that the hfs directory
|
|
|
|
does not have dependencies on the dmg directory.
|
2008-04-22 06:21:50 +04:00
|
|
|
|
2008-04-27 18:25:00 +04:00
|
|
|
The makefile in the root folder will make all utilities.
|
2015-03-19 21:46:40 +03:00
|
|
|
|
|
|
|
mkdir build && cd build
|
|
|
|
cmake ..
|
|
|
|
make # Or only make hfs / make dmg / ...
|
2015-03-19 23:25:02 +03:00
|
|
|
sudo make install
|
2008-04-26 22:39:53 +04:00
|
|
|
|
2008-04-24 23:40:13 +04:00
|
|
|
### HFS+
|
2008-04-24 23:46:15 +04:00
|
|
|
|
|
|
|
cd hfs
|
|
|
|
make
|
2008-04-22 06:21:50 +04:00
|
|
|
|
2008-04-24 23:40:13 +04:00
|
|
|
### DMG
|
2008-04-24 23:46:15 +04:00
|
|
|
|
|
|
|
cd dmg/zlib-1.2.3
|
|
|
|
./configure
|
|
|
|
make
|
|
|
|
cd ..
|
|
|
|
make
|
2008-04-26 22:39:53 +04:00
|
|
|
|
2008-04-27 18:25:00 +04:00
|
|
|
### hdutil
|
|
|
|
cd hdiutil
|
|
|
|
make
|