tags 330805 + patch thanks Attached is a patch for cdbs-edit-patch, roughly extracted from dpatch-edit-patch, adding automatic support for debian-only directories, as commonly used with svn-buildpackage and cvs-buildpackage. Hope to see it integrated soon, and would be glad to do so myself if that helps. ;-)
cheers, Charles -- Holler Half a pound for Half a dollar Oh boy! Shaving joy Complexion save Burma-Shave http://burma-shave.org/jingles/1928/holler
--- /home/cfry/cdbs-edit-patch 2006-01-04 17:03:45.818606000 -0500
+++ /usr/bin/cdbs-edit-patch 2005-07-10 12:13:58.000000000 -0400
@@ -19,40 +19,8 @@
ORIGDIR=$(basename $(pwd))
NEWDIR=$ORIGDIR.new
-# unpack upstream tarball if debianonly
-# roughly extracted from dpatch-edit-patch by Charles Fry
-if [ "$(find . -maxdepth 1 -mindepth 1 -print | egrep -v './(CVS|.svn)')" =
'./debian' ]; then
- echo "* debian/-only layout selected"
- PACKAGENAME="$(dpkg-parsechangelog | sed -n
'/^Source:/{s/^Source:[[:space:]]\+\(.*\)/\1/;p;q}')"
- UPSTREAMVERSION="$(dpkg-parsechangelog | sed -n
'/^Version:/{s/^Version:[[:space:]]\+\([^-]\+\).*/\1/;p;q}')"
- ORIGTARGZ="${PACKAGENAME}_${UPSTREAMVERSION}.orig.tar.gz"
- for dir in '..' '../tarballs'; do
- if [ -f "$dir/$ORIGTARGZ" ]; then
- ORIGTARGZ="$(readlink -f "$dir/$ORIGTARGZ")"
- break
- fi
- done
- if [ ! -f "$ORIGTARGZ" ]; then
- echo "unable to obtain upstream tarball, $ORIGTARGZ failed"
- exit 1
- fi
- cd $TMP
- echo "* unpacking $ORIGTARGZ"
- tar --extract --gzip --file $ORIGTARGZ
- # this heuristic is stolen from dpkg-source
- if [ "$(find . -maxdepth 1 -mindepth 1 -type d -print | wc -l)" -eq 1 ];
then
- if [ "$(readlink -f "$(find . -maxdepth 1 -mindepth 1 -type d -print)")"
!= "$(readlink -f "$(basename "$ORIGDIR")")" ]; then
- mv "$(find . -maxdepth 1 -mindepth 1 -type d -print)" "$(basename
"$ORIGDIR")"
- fi
- else
- mkdir "$(basename "$ORIGDIR")"
- find . -maxdepth 1 -mindepth 1 -type d -name "$(basename "$ORIGDIR")"
-prune -o -print0 | \
- xargs --null mv --target-directory="$(basename "$ORIGDIR")"
- fi
-fi
-
# create clean source package in temporary dir
-cp -a SRCDIR $TMP/$ORIGDIR
+cp -a . $TMP/$ORIGDIR
cd $TMP/$ORIGDIR
debclean
signature.asc
Description: Digital signature

