r1964: *** empty log message ***
[uffi.git] / cvsbp-prepare
index cd9155b844c54320b0adc384bb6748c429b0138f..8e70e0a6f1587f9d248ebb4f1e905acdefaf3a50 100755 (executable)
@@ -1,25 +1,20 @@
 #!/bin/bash
 
-# Clean checked out CVS directory
-rm -f upload.sh make-dist.sh make-doc.sh cvsbp-prepare
-rm -f `find . -type f -name .cvsignore`
+set -e  # abort on error
 
-# Try to copy documentation from Work dir
-CWD=`pwd`
-BASENAME=`basename ${CWD}`
-BASEDIR=`echo ${BASENAME} | sed -n 's/-[0-9].*$//p'`
-DOCDIR=/usr/local/src/Work/${BASEDIR}/doc
+# Make documentation to put in debian package 
+# This must match prebuilt upstream documentation
 
-if [ -d ${DOCDIR} -a -d doc ]; then
-  echo "Copying documentation"
-  cp -a ${DOCDIR}/html ${DOCDIR}/*pdf doc/.
-  echo "Unable to copy documentation"
+if [ -f doc/Makefile ]; then
+  cd doc
+  make all
+  cd ..
+else
+  echo "Unable to build documentation for CVS checked out package"
+  exit 1
 fi
 
-# Try to build documentation 
-# Not used because PDF created at difference times or places will not match
-#if [ -f doc/Makefile ]; then
-#  pushd doc > /dev/null
-#  make
-#  popd > /dev/null
-#fi
+# Clean checked out CVS directory
+rm -f upload.sh make-dist.sh make-doc.sh make-upstream.sh make-debian.sh
+rm -f `find . -type f -name .cvsignore`
+rm -f cvsbp-prepare