r1877: *** empty log message ***
[ctsim.git] / make-dist.sh
index cd649b2a83ae1cd94134e7983d2cec64bc05e5a3..ece2de04ee063c37acf37ec5cb7a415b43ff1ef1 100755 (executable)
@@ -15,9 +15,9 @@ DISTDIR=${PKG}-${VERSION}
 DEBDIR=${DEBPKG}-${VERSION}
 
 TAG=upstream_version_`echo $VERSION | tr . _`
-echo "(re)tagging with release tag '$TAG'"
-cvs -q rtag -d $TAG $PKG
-cvs -q tag -F $TAG
+#echo "(re)tagging with release tag '$TAG'"
+#cvs -q rtag -d $TAG $PKG
+#cvs -q tag -F $TAG
 
 
 # build the tarball
@@ -30,38 +30,44 @@ cp -a ${TOPDIR} ${DISTDIR}
 # Remove junk from distribution dir
 find ${DISTDIR} -type f -name .cvsignore -exec rm {} \;
 find ${DISTDIR} -type d -name CVS | xargs rm -r
-find ${DISTDIR}/doc -type f -name \*.tex -or -name \*.aux -or \
-    -name \*.log -or -name \*.out -or -name \*.dvi -or \
-    -name \*~ -or -name .\#\*  -or -name \#*\# |xargs rm -f
+find ${DISTDIR} -type f -name *~ -or -name ".#*" -or -name "#*#" |xargs rm -f
+find ${DISTDIR}/doc -type f -and -name *.tex -or -name *.aux -or \
+    -name *.log -or -name *.out -or -name *.dvi | xargs rm -f
 
 # Create original distribution archives
 rm -rf ${DISTDIR}/debian
+cd ${DISTDIR}
+make distclean
+cd ..
 GZIP=-9 tar czf ${DISTDIR}.tar.gz ${DISTDIR}
 
-find ${DISTDIR} -type f -and -name \*.c -or -name \*.h -or -name \*.list -or \
-    -name \*.system -or -name Makefile -or -name ChangeLog -or \
+find ${DISTDIR} -type f -and -name *.c -or -name *.h -or -name *.list -or \
+    -name Makefile -or -name ChangeLog -or \
     -name COPYRIGHT -or -name TODO -or -name README -or -name INSTALL \
-    -or -name NEWS -or -name \*.sgml -or -name COPYING\* -or -name catalog \
+    -or -name NEWS -or -name *.sgml -or -name COPYING* -or -name catalog \
     | xargs unix2dos
 zip -rq ${DISTDIR}.zip ${DISTDIR}
 
 rm -rf ${DISTDIR}
 
 tar xzf ${DISTDIR}.tar.gz 
+cp ${DISTDIR}.tar.gz ${DEBPKG}_${VERSION}.orig.tar.gz
+
 if [ "${DISTDIR}" != "${DEBDIR}" ]; then
   mv ${DISTDIR} ${DEBDIR}
 fi
 cp -a ${TOPDIR}/debian ${DEBDIR}
 
-cd ${DEBDIR}
-dpkg-buildpackage -rfakeroot -kkevin@b9.com -a
+# dpkg-source ${DEBDIR} ${PKG}_${VERSION}.orig.tar.gz
 
+cd ${DEBDIR}
+dpkg-buildpackage -rfakeroot -kkevin@b9.com  #-tc -b
 cd ..
-rm -rf $DEBDIR}
+rm -r ${DEBDIR}
 
 lintian ${DEBPKG}_${VERSION}-*.changes
 
-mkdir -p /usr/local/share/Packages/${DEBPKG}
-mv ${DEBPKG}_${VERSION}* /usr/local/share/Packages/${DEBPKG}
+mkdir -p /usr/local/src/Packages/${DEBPKG}
+mv ${DEBPKG}_${VERSION}* /usr/local/src/Packages/${DEBPKG}
 cd ${TOPDIR}
 exit 0