1 fixupOutputHooks
+=('if [ -z "${dontGzipMan-}" ]; then compressManPages "$prefix"; fi')
6 if [ -L "$dir"/share
] ||
[ -L "$dir"/share
/man
] ||
[ ! -d "$dir/share/man" ]
9 echo "gzipping man pages under $dir/share/man/"
11 # Compress all uncompressed manpages. Don't follow symlinks, etc.
12 find "$dir"/share
/man
/ -type f
-a '!' -regex '.*\.\(bz2\|gz\|xz\)$' -print0 \
13 |
while IFS
= read -r -d $
'\0' f
15 if gzip -c -n "$f" > "$f".gz
; then
22 # Point symlinks to compressed manpages.
23 find "$dir"/share
/man
/ -type l
-a '!' -regex '.*\.\(bz2\|gz\|xz\)$' -print0 \
25 |
while IFS
= read -r -d $
'\0' f
28 target
="$(readlink -f "$f")"
29 if [ -f "$target".gz
]; then
30 ln -sf "$target".gz
"$f".gz
&& rm "$f"