diff --git a/debian/changelog b/debian/changelog index b9667e66..be577b2d 100644 --- a/debian/changelog +++ b/debian/changelog @@ -13,6 +13,9 @@ debian-cd (2.2.23) unstable; UNRELEASED - Made list2cds more verbose - Added tools/sarge/upgrade-hppa.sh and tools/sarge/upgrade-sparc.sh to install the upgrade-kernel bits on CD#1 + - Added tools/dedicated_source: simple script used to add extra + source packages onto _binary_ CDs. Used for the amd64 sarge release + so far. debian-cd (2.2.22) unstable; urgency=critical diff --git a/tools/dedicated_source b/tools/dedicated_source new file mode 100755 index 00000000..94657866 --- /dev/null +++ b/tools/dedicated_source @@ -0,0 +1,39 @@ +#!/bin/sh +# +# Quick hack - add extra sources for this arch onto the last *binary* CD +# Initially written for the unofficial amd64 CDs in sarge... +# + +set -e + +BDIR=$1 +ARCH=$2 +BASEDIR=$3 +CODENAME=$4 +MIRROR=$5 + +SOURCE_LIST=$BASEDIR/data/$CODENAME/$ARCH/extra-sources +DISKNUM=`ls -l $BDIR/?.packages $BDIR/??.packages | wc -l | tr -d " "` +SOURCES=`ls -1 $MIRROR/dists/$CODENAME/*/source/Sources.gz` + +echo "dedicated_source: Need to add the following sources to $ARCH CD#$DISKNUM:" + +mkdir $BDIR/CD$DISKNUM/extra-sources +for SRC in `grep -v ^# $SOURCE_LIST` +do + echo "$SRC:" + FILES=`zcat $SOURCES | awk -v SOURCE=$SRC ' + /^Package:/ { if ($2 == SOURCE) { found=1 } } + /^Directory:/ { DIR=$2 } + /^ / { if (found) { printf(" %s/%s\n",DIR,$3) }} + /^$/ {found=0} +'` + for FILE in $FILES + do + echo " $FILE" + cp -al $MIRROR/$FILE $BDIR/CD$DISKNUM/extra-sources + done +done + +exit 0 +