Initial cut of make-firmware-image, a simple script to create .tar.gz

and .zip files containing non-free firmware and microcode packages.
This commit is contained in:
Steve McIntyre 2008-06-23 21:55:36 +00:00
parent 62737f3232
commit 3a29fb0a8b
2 changed files with 34 additions and 0 deletions

4
debian/changelog vendored
View File

@ -52,6 +52,10 @@ debian-cd (3.0.5) UNRELEASED; urgency=low
* Update isolinux to version 3.63+dfsg-2 (featuring 'menu default64'
support).
[ Steve McIntyre ]
* tools/make-firmware-image: Simple script to create .tar.gz and
.zip files containing non-free firmware and microcode packages.
-- Frans Pop <fjp@debian.org> Fri, 06 Jun 2008 22:32:06 +0200
debian-cd (3.0.4) unstable; urgency=low

30
tools/make-firmware-image Executable file
View File

@ -0,0 +1,30 @@
#!/bin/sh
set -e
MIRROR=$1
SUITE=$2
TMPDIR=$3
export LC_ALL=C
if [ "$MIRROR"x = ""x ] || [ "$SUITE"x = ""x ] || [ "$TMPDIR"x = ""x ] ; then
echo "$0: Need parameters"
exit 1
fi
rm -rf $TMPDIR/firmware
mkdir -p $TMPDIR/firmware
FILES=`zcat $MIRROR/dists/$SUITE/non-free/binary-*/Packages.gz | \
awk '
/^Filename:.*firmware/ {print $2}
/^Filename:.*microcode/ {print $2}
' | sort -u`
for file in $FILES; do
cp $MIRROR/$file $TMPDIR/firmware/
done
cd $TMPDIR/firmware
tar czf ../firmware.tar.gz .
zip -9r ../firmware.zip .