[SCM] libav/experimental: Add scripts that may be helpful for doing mass rebuilds
siretart at users.alioth.debian.org
siretart at users.alioth.debian.org
Sat Aug 30 15:49:46 UTC 2014
The following commit has been merged in the experimental branch:
commit da6c8ef663de27e222ef7a8c7d572974935d5445
Author: Reinhard Tartler <siretart at tauware.de>
Date: Wed Aug 13 22:06:07 2014 -0400
Add scripts that may be helpful for doing mass rebuilds
How to use:
1. Upload the new Libav upstream release to experimental, make sure your
mirror has it available.
1. Copy this folder to a temporary directory with lots of
storage. (e.g., /srv/scratch/libav_rebuilds)
2. Identify all packages you need to rebuild either using grep-dctrl(1),
or by scraping the Debian release tracker at
https://release.debian.org/transitions/. List all packages in a file
"packages.txt"
3. Review and adjust the dependencies and chroot names in
git_experimental_source
4. Execute "./do_all_safe"
Discussion:
git_experimental_source will use the schroot chroot to download the
source package from debian/experimental in a subdirectory with the
package name. It also places a script called "build.sh" with an schroot
invocation that makes sure you have the libav packages from experimental
in your build.sh chroot avaialable. do_all_safe iterates over the
package list, download packages that have not been downloaded yet and
executes the generated $package/build.sh script.
If a build breaks, the idea is to go into that directory, and work on a
patch to fix the problem. To start over, just delete the directory and
call do_all_safe again.
diff --git a/debian/rebuild-scripts/README b/debian/rebuild-scripts/README
new file mode 100644
index 0000000..db98823
--- /dev/null
+++ b/debian/rebuild-scripts/README
@@ -0,0 +1,35 @@
+The scripts in this folder may be helpful for doing mass rebuilds.
+
+How to use:
+
+1. Upload the new Libav upstream release to experimental, make sure your
+ mirror has it available.
+
+1. Copy this folder to a temporary directory with lots of
+ storage. (e.g., /srv/scratch/libav_rebuilds)
+
+2. Identify all packages you need to rebuild either using grep-dctrl(1),
+ or by scraping the Debian release tracker at
+ https://release.debian.org/transitions/. List all packages in a file
+ "packages.txt"
+
+3. Review and adjust the dependencies and chroot names in
+ git_experimental_source
+
+4. Execute "./do_all_safe"
+
+Discussion:
+
+git_experimental_source will use the schroot chroot to download the
+source package from debian/experimental in a subdirectory with the
+package name. It also places a script called "build.sh" with an schroot
+invocation that makes sure you have the libav packages from experimental
+in your build.sh chroot avaialable. do_all_safe iterates over the
+package list, download packages that have not been downloaded yet and
+executes the generated $package/build.sh script.
+
+If a build breaks, the idea is to go into that directory, and work on a
+patch to fix the problem. To start over, just delete the directory and
+call do_all_safe again.
+
+August 2014, Reinhard Tartler <siretart at debian.org>
\ No newline at end of file
diff --git a/debian/rebuild-scripts/do_all_safe b/debian/rebuild-scripts/do_all_safe
new file mode 100755
index 0000000..954533d
--- /dev/null
+++ b/debian/rebuild-scripts/do_all_safe
@@ -0,0 +1,28 @@
+#!/bin/sh
+
+#!/bin/sh
+#
+# Copyright 2014, Reinhard Tartler <siretart at debian.org>
+#
+# These helper script is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2 of the
+# License, or (at your option) any later version.
+#
+# This script is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+
+set -ex
+
+for package in `cat packages.txt`; do
+ if [ ! -d $package ]; then
+ echo "Rebuilding $package"
+ ./git_experimental_source $package
+ ./$package/build.sh || true
+ else
+ echo "Skipping $package"
+ fi
+done
diff --git a/debian/rebuild-scripts/git_experimental_source b/debian/rebuild-scripts/git_experimental_source
new file mode 100755
index 0000000..8dc233c
--- /dev/null
+++ b/debian/rebuild-scripts/git_experimental_source
@@ -0,0 +1,51 @@
+#!/bin/sh
+#
+# Copyright 2014, Reinhard Tartler <siretart at debian.org>
+#
+# These helper script is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2 of the
+# License, or (at your option) any later version.
+#
+# This script is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+
+set -e
+
+packagename=$1
+basedir=$(readlink -f `dirname $0`)
+
+if [ -z "$packagename" ]; then
+ echo "usage $0 packagename"
+ exit 1
+fi
+
+rm -rf $basedir/$packagename
+mkdir -p $basedir/$packagename
+
+cd $basedir/$packagename
+
+schroot -c experimental-amd64-sbuild -- apt-get source -d -t experimental $packagename
+package=`ls *.dsc`
+
+cat <<EOF > build.sh
+#!/bin/sh
+
+cd $PWD
+sbuild -A -dexperimental --build-dep-resolver=aptitude \
+ --make-binNMU="rebuild against libav11" --binNMU=+42 \
+ --add-depends "libavformat-dev (>> 6:11~~)" \
+ --add-depends "libavcodec-dev (>> 6:11~~)" \
+ --add-depends "libavfilter-dev (>> 6:11~~)" \
+ --add-depends "libavresample-dev (>> 6:11~~)" \
+ --add-depends "libavdevice-dev (>> 6:11~~)" \
+ --add-depends "libswscale-dev (>> 6:11~~)" \
+ --add-depends "libavutil-dev (>> 6:11~~)" \
+ "\$@" \
+ $package
+EOF
+
+chmod +x build.sh
--
Libav/FFmpeg packaging
More information about the pkg-multimedia-commits
mailing list