Différences entre versions de « Backport Git »

De Cliss XXI
Sauter à la navigation Sauter à la recherche
imported>SylvainBeucler
m (fix pbuilder initial setup (some slight mistkaes))
imported>SylvainBeucler
m
 
(6 versions intermédiaires par le même utilisateur non affichées)
Ligne 4 : Ligne 4 :
 
mkdir -p /usr/src/backports/lenny/debs
 
mkdir -p /usr/src/backports/lenny/debs
 
(cd /usr/src/backports/lenny/debs && apt-ftparchive packages . | gzip > Packages.gz)
 
(cd /usr/src/backports/lenny/debs && apt-ftparchive packages . | gzip > Packages.gz)
pbuilder --create --basetgz /var/cache/pbuilder/base-lenny.tar.gz --distribution lenny \
+
pbuilder --create --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --distribution lenny \
 
   --othermirror "deb file:///usr/src/backports/lenny/debs ./" --bindmounts /usr/src/backports/lenny/debs
 
   --othermirror "deb file:///usr/src/backports/lenny/debs ./" --bindmounts /usr/src/backports/lenny/debs
# to upgrade: pbuilder --update --basetgz /var/cache/pbuilder/base-lenny.tar.gz --bindmounts /usr/src/backports/lenny/debs
+
# to upgrade: pbuilder --update --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs
  
pbuilder --login --basetgz /var/cache/pbuilder/base-lenny.tar.gz --bindmounts /usr/src/backports/lenny/debs --save-after-login
+
pbuilder --login --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs --save-after-login
 
echo "deb http://network/mirrors/debian-backports.org lenny-backports main" > /etc/apt/sources.list.d/bpo.list
 
echo "deb http://network/mirrors/debian-backports.org lenny-backports main" > /etc/apt/sources.list.d/bpo.list
apt-get --assume-yes install debian-backports-keyring
 
 
apt-get update
 
apt-get update
 +
apt-get --assume-yes --force-yes install debian-backports-keyring
 +
apt-get update
 +
exit
  
 
# TODO: --pbuildersatisfydepends doesn't work, why?
 
# TODO: --pbuildersatisfydepends doesn't work, why?
 
#pdebuild --pbuilder cowbuilder --pbuildersatisfydepends /usr/lib/pbuilder/pbuilder-satisfydepends-experimental
 
#pdebuild --pbuilder cowbuilder --pbuildersatisfydepends /usr/lib/pbuilder/pbuilder-satisfydepends-experimental
 
# Meanwhile we edit /etc/pbuilderrc manually
 
# Meanwhile we edit /etc/pbuilderrc manually
PBUILDERSATISFYDEPENDSCMD="/usr/lib/pbuilder/pbuilder-satisfydepends-experimental
+
PBUILDERSATISFYDEPENDSCMD=/usr/lib/pbuilder/pbuilder-satisfydepends-experimental
 +
 
 +
# TODO: add security.debian.org in sources.list
 
</pre>
 
</pre>
  
 
source packages location:
 
source packages location:
 
<pre>
 
<pre>
cat <<EOF > /etc/apt/sources.list.d/squeeze-src
+
cat <<EOF > /etc/apt/sources.list.d/squeeze-src.list
deb-src http://ftp.fr.debian.org/debian/ lenny main
+
deb-src http://ftp.fr.debian.org/debian/ squeeze main
 
EOF
 
EOF
 
apt-get update
 
apt-get update
Ligne 38 : Ligne 42 :
 
apt-get source git-core
 
apt-get source git-core
 
pushd git-core-*
 
pushd git-core-*
 +
#sed -i -e "s/Uploaders:\(.*\)/Uploaders:\1, $DEBFULLNAME <$DEBEMAIL>/" debian/control
 
# debian/control: add new field
 
# debian/control: add new field
 
# Uploaders: Sylvain Beucler <beuc@beuc.net>
 
# Uploaders: Sylvain Beucler <beuc@beuc.net>
yes | dch -D lenny-backports \
+
dch --bpo
  --newversion $(dpkg-parsechangelog | sed -ne 's,^Version: ,,p')~bpo50+1 \
+
sudo pbuilder --update --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs
  --force-bad-version -- \
 
  "Rebuild for Debian Backports <http://www.backports.org/>"
 
#sed -i -e "s/Uploaders:\(.*\)/Uploaders:\1, $DEBFULLNAME <$DEBEMAIL>/" debian/control
 
 
pdebuild --debbuildopts '-sa' --buildresult /usr/src/backports/lenny/debs \
 
pdebuild --debbuildopts '-sa' --buildresult /usr/src/backports/lenny/debs \
   -- --basetgz /var/cache/pbuilder/base-lenny.tar.gz --bindmounts /usr/src/backports/lenny/debs
+
   -- --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs
 
# Takes around 1/2h
 
# Takes around 1/2h
 
popd
 
popd

Version actuelle datée du 9 mars 2010 à 13:37

pbuilder initial Lenny setup:

apt-get install pbuilder cdebootstrap
mkdir -p /usr/src/backports/lenny/debs
(cd /usr/src/backports/lenny/debs && apt-ftparchive packages . | gzip > Packages.gz)
pbuilder --create --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --distribution lenny \
  --othermirror "deb file:///usr/src/backports/lenny/debs ./" --bindmounts /usr/src/backports/lenny/debs
# to upgrade: pbuilder --update --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs

pbuilder --login --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs --save-after-login
echo "deb http://network/mirrors/debian-backports.org lenny-backports main" > /etc/apt/sources.list.d/bpo.list
apt-get update
apt-get --assume-yes --force-yes install debian-backports-keyring
apt-get update
exit

# TODO: --pbuildersatisfydepends doesn't work, why?
#pdebuild --pbuilder cowbuilder --pbuildersatisfydepends /usr/lib/pbuilder/pbuilder-satisfydepends-experimental
# Meanwhile we edit /etc/pbuilderrc manually
PBUILDERSATISFYDEPENDSCMD=/usr/lib/pbuilder/pbuilder-satisfydepends-experimental

# TODO: add security.debian.org in sources.list

source packages location:

cat <<EOF > /etc/apt/sources.list.d/squeeze-src.list
deb-src http://ftp.fr.debian.org/debian/ squeeze main
EOF
apt-get update

shell variables:

export DEBEMAIL="beuc@beuc.net" 
export DEBFULLNAME="Sylvain Beucler"
export EDITOR="emacs"

git-core:

apt-get source git-core
pushd git-core-*
#sed -i -e "s/Uploaders:\(.*\)/Uploaders:\1, $DEBFULLNAME <$DEBEMAIL>/" debian/control
# debian/control: add new field
# Uploaders: Sylvain Beucler <beuc@beuc.net>
dch --bpo
sudo pbuilder --update --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs
pdebuild --debbuildopts '-sa' --buildresult /usr/src/backports/lenny/debs \
  -- --basetgz /var/cache/pbuilder/base-lenny-bpo.tar.gz --bindmounts /usr/src/backports/lenny/debs
# Takes around 1/2h
popd

(cd /usr/src/backports/lenny/debs && apt-ftparchive packages . | gzip > Packages.gz)