diff options
-rw-r--r-- | backport_all.sh | 4 | ||||
-rw-r--r-- | edit_changelog_etch.py | 28 | ||||
-rw-r--r-- | r-base/README | 7 | ||||
-rw-r--r-- | r-base/build-r-base.sh | 83 |
4 files changed, 85 insertions, 37 deletions
diff --git a/backport_all.sh b/backport_all.sh index 7ec27bb..0221e99 100644 --- a/backport_all.sh +++ b/backport_all.sh @@ -9,14 +9,14 @@ #DEBFULLNAME="Johannes Ranke" text="Recompiled on etch for CRAN" -for i in littler rkward; do +for i in lattice; do #for i in boot cluster codetools foreign kernsmooth lattice mgcv nlme rpart survival vr littler rkward; do cd $i rm -rf $i* rm *.deb apt-get source -t unstable $i cd $i-* - version=`dpkg-parsechangelog | grep ^Version | cut -f2 -d " "`~etchcran.2.6.2 + version=`dpkg-parsechangelog | grep ^Version | cut -f2 -d " "`~etchcran.2.7.0 dch -b -v $version -D etch-cran $text fakeroot dpkg-buildpackage -sa cd ../.. diff --git a/edit_changelog_etch.py b/edit_changelog_etch.py deleted file mode 100644 index 63f2666..0000000 --- a/edit_changelog_etch.py +++ /dev/null @@ -1,28 +0,0 @@ -#!/usr/bin/python -# SVN: $Id: edit_changelog.py 5 2006-12-20 14:08:52Z ranke $ -# Author: Johannes Ranke <jranke@uni-bremen.de> -# Last Change: 2007 Mai 01 - -from time import strftime -from debian_bundle.changelog import Changelog, Version - -author = 'Johannes Ranke <jranke@uni-bremen.de>' - -chlg = "debian/changelog" -content = file(chlg).read() -changelog = Changelog(content) -newVersion = changelog.upstream_version() + "-" + changelog.debian_version() + "~etchcran.1" - -changelog.new_block(package=changelog.package(), - version=Version(newVersion), - distributions='etch-cran', - urgency='low', - author=author, - date=strftime("%a, %e %b %Y %H:%M:%S %z"), - ) - -changelog.add_change(''); -changelog.add_change(' * Recompiled on etch for CRAN'); -changelog.add_change(''); - -file(chlg,"w").write(str(changelog)) diff --git a/r-base/README b/r-base/README deleted file mode 100644 index 7380d34..0000000 --- a/r-base/README +++ /dev/null @@ -1,7 +0,0 @@ -The command used for building the packages is -fakeroot dpkg-buildpackage > ../build_log_r-base_i386 2> ../build_errors_r-base_i386 - -and for the amd64 build -fakeroot dpkg-buildpackage -B > ../build_log_r-base_amd64 2> ../build_errors_r-base_amd64 - -Didn't figure out how to do this with tee yet... diff --git a/r-base/build-r-base.sh b/r-base/build-r-base.sh new file mode 100644 index 0000000..94192fe --- /dev/null +++ b/r-base/build-r-base.sh @@ -0,0 +1,83 @@ +#!/bin/bash + +# Script to automate building of r-base and r-recommended packages for +# the Ubuntu release specified in file /etc/lsb-release. This script +# should be run as root, in one way or another. + +# Author: Vincent Goulet <vincent.goulet@act.ulaval.ca> +# Modified for backporting to Debian etch by +# Johannes Ranke <jranke@uni-bremen.de> +# Last Change: 2008 Apr 24 + +export DEBEMAIL="Johannes Ranke <jranke@uni-bremen.de>" + +rm -rf r-base* + +apt-get update +apt-get source -t unstable r-base +cd r-base-* + +# Old version +oldversion=`dpkg-parsechangelog | grep ^Version | cut -f2 -d " "` +cranversion=$oldversion"~etchcran.0" + +# Add new version to changelog +dch -v "${cranversion}" -D etch-cran -b "Backport form Debian unstable to Debian etch" + +# Reverts for etch: +# +# 1. Starting with Debian packages for R 2.6.1-2, the build dependency +# to 'refblas3-dev|atlas3-base-dev' is changed to 'libblas-dev' to +# use the new gfortran-built BLAS libraries. From R 2.7.0, the +# dependency is on 'libblas-dev | libatlas-base-dev' for +# r-base-dev. + +sed -i '/^Build-Depends/s/libblas-dev/refblas3-dev|atlas3-base-dev/' debian/control +sed -i '/^Depends/s/libblas-dev | libatlas-base-dev/refblas3-dev|atlas3-base-dev/' debian/control +dch -a "debian/control: revert Build-Depends: to 'refblas3-dev|atlas3-base-dev' and Depends: to 'refblas3-dev|atlas3-base-dev' since etch does not have the new gfortran-built BLAS libraries" + +# 2. Starting with Debian packages for R 2.6.2, new build dependency +# on liblapack-dev to switch back to using Debian's Lapack rather +# than the version supplied by R. From R 2.7.0, the dependency is +# on 'liblapack-dev (>= 3.1.1)' for r-base and 'liblapack-dev | +# libatlas-base-dev' for r-base-dev. + +sed -i '/^Build-Depends/s/liblapack-dev (>= 3.1.1), //' debian/control +sed -i '/^Depends/s/liblapack-dev | libatlas-base-dev, //' debian/control + dch -a "debian/control: revert Build-Depends: and Depends: fields since we use the Lapack supplied with R" + sed -i '/^lapack/{ +s/lapack/\#lapack/ +a\ +# jr 24 Apr 2008 Set to =no for Debian etch +a\lapack = --with-lapack=no +}' debian/rules + dch -a "debian/rules: Accordingly, do not configure --with-lapack" + +# 3. Requirement for tk8.4 >= 8.4.16-2 introduced in r-base 2.6.0-4 to +# circumvent a breakage with 8.4.16-1. The version in etch is 8.4.12-1etch2. + +rm debian/shlibs.local +dch -a "delete debian/shlibs.local since the dependency on tk8.4 is not an issue for Debian etch" + +# 4. The TeX distribution in etch is tetex + +sed -i '/^Build-Depends/s/texlive-base, texlive-latex-base, texlive-generic-recommended, texlive-fonts-recommended, texlive-extra-utils, texlive-latex-recommended, texlive-latex-extra, texinfo, texi2html/tetex-bin, tetex-extra/' debian/control +dch -a "debian/control: revert Build-Depends: to 'tetex-bin, tetex-extra' since etch does not have texlive" + +# Build package showing all messages and separating output to build and error logs +(dpkg-buildpackage -tc | tee ../build_log_r-base_i386) 3>&1 1>&2 2>&3 | tee ../build_errors_r-base_i386 +if [ $? -ne 0 ]; then + exit 1 +fi + +cd .. + +# Create diff to Debian unstable +interdiff -z *.diff.gz > interdiff_to_debian_sid + +# Sign logs and interdiff +for i in interdiff_to_debian_sid build_log_r-base_i386 build_errors_r-base_i386 +do + gpg --clearsign $i + mv $i.asc $i +done |