summaryrefslogtreecommitdiffstats
path: root/historic/makehole.8
blob: 5b5c63be6c6fb5d5642c5cd36d9bb08517c6e48f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
.\" Copyright 1992 Rickard E. Faith (faith@cs.unc.edu)
.\" May be distributed under the GNU General Public License
.TH MAKEHOLE 8 "20 November 1993" "Linux 0.99" "Linux Programmer's Manual"
.SH NAME
makehole \- a program to make filesystem "holes" in pure executables
.SH SYNOPSIS
.B makehole
Imagefile
.SH DESCRIPTION
.B makehole
copies the
.IR Imagefile ,
using
.BR lseek (2)
to skip over sections of the file which contain all zeros.  If the file
system is smart enough to recognize this use of
.BR lseek (2),
then it will store the file in a more efficient fashion.

The logical length of the file will
.I not
be changed, only the way it is stored in the filesystem.  This can save a
lot of space if the file contains large blocks of zeros.
.BR cp (3)
will not similar "hole creation," but it does not seem to be as extensive
(see the GNU source code for details).
.BR dd (3)
will
.I not
create holes, and should be used when holes are not desired (i.e., for the
.BR shoelace (8)
boot image).
.SH "SEE ALSO"
.BR lseek (2),
.BR cp (3),
.BR dd (3)
.SH BUGS
Must be root to run.
.br
The
.I Imagefile
must be a pure exectuable.
.SH AUTHOR
HJ Lu