@@ -22,7 +22,11 @@ sourcetree=`cd $1 && pwd`
22
22
23
23
buildtree=` cd${2:- ' .' } && pwd`
24
24
25
- for item in ` find" $sourcetree " -type d\( \( -name CVS -prune\) -o\( -name .git -prune\) -o -print\) ` ; do
25
+ # We must not auto-create the subdirectories holding built documentation.
26
+ # If we did, it would interfere with installation of prebuilt docs from
27
+ # the source tree, if a VPATH build is done from a distribution tarball.
28
+ # See bug #5595.
29
+ for item in ` find" $sourcetree " -type d\( \( -name CVS -prune\) -o\( -name .git -prune\) -o\( -path" $sourcetree /doc/src/sgml/*" -prune\) -o -print\) ` ; do
26
30
subdir=` expr" $item " : " $sourcetree \(.*\)" `
27
31
if test ! -d" $buildtree /$subdir " ; then
28
32
mkdir -p" $buildtree /$subdir " || exit 1
@@ -38,13 +42,4 @@ for item in `find "$sourcetree" -name Makefile -print -o -name GNUmakefile -prin
38
42
fi
39
43
done
40
44
41
- # We must not auto-create the subdirectories holding built documentation.
42
- # If we did, it would interfere with installation of prebuilt docs from
43
- # the source tree, if a VPATH build is done from a distribution tarball.
44
- # See bug #5595.
45
- rmdir" $buildtree /doc/src/sgml/html" 2> /dev/null
46
- rmdir" $buildtree /doc/src/sgml/man1" 2> /dev/null
47
- rmdir" $buildtree /doc/src/sgml/man3" 2> /dev/null
48
- rmdir" $buildtree /doc/src/sgml/man7" 2> /dev/null
49
-
50
45
exit 0