[210] in athena10

home help back first fref pref prev next nref lref last post

Re: /svn/athena r22978 - trunk/debathena/scripts

daemon@ATHENA.MIT.EDU (Timothy G Abbott)
Sun May 25 03:17:16 2008

Date: Sun, 25 May 2008 03:16:32 -0400 (EDT)
From: Timothy G Abbott <tabbott@MIT.EDU>
To: athena10@mit.edu
In-Reply-To: <200805250703.DAA00172@drugstore.mit.edu>
Message-ID: <Pine.LNX.4.64L.0805250309150.28639@vinegar-pot.mit.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

Because this is using a new feature of sbuild (the result of one of the 
two patches I submitted adding the features of sbuildhack upstream), we'll 
need to backport sbuild from Lenny to Hardy for this change to work on 
linux-build-10.  I've done this and placed the result in 
/mit/debathena/packages/third/sbuild/.

The other feature of SbuildHack.pm is still waiting to be merged upstream 
because of complex issues related to how --binNMU generates changes files; 
see bugs.debian.org/475777 for details.

 	-Tim Abbott

On Sun, 25 May 2008, tabbott@MIT.EDU wrote:

> Author: tabbott
> Date: 2008-05-25 03:03:27 -0400 (Sun, 25 May 2008)
> New Revision: 22978
>
> Modified:
>   trunk/debathena/scripts/SbuildHack.pm
>   trunk/debathena/scripts/sbuildhack
> Log:
> Use the new --apt-update feature of schroot 1.20 to simplify sbuildhack.
>
>
> Modified: trunk/debathena/scripts/SbuildHack.pm
> ===================================================================
> --- trunk/debathena/scripts/SbuildHack.pm	2008-05-23 00:31:37 UTC (rev 22977)
> +++ trunk/debathena/scripts/SbuildHack.pm	2008-05-25 07:03:27 UTC (rev 22978)
> @@ -1,7 +1,6 @@
> package SbuildHack;
>
> use Sbuild qw(binNMU_version);
> -use Sbuild::Chroot qw(begin_session);
> use Fcntl qw(:flock);
>
> sub new_binNMU_version {
> @@ -12,31 +11,9 @@
>     return $v . $ENV{"NMUTAG"};
> };
>
> -*old_begin_session = \&Sbuild::Chroot::begin_session;
> -
> -sub new_begin_session {
> -    open(APTLOCK, ">/tmp/debathena-repository-lock");
> -    flock(APTLOCK, LOCK_SH);
> -    my $r = old_begin_session(@_);
> -    if (!open(PIPE, Sbuild::Chroot::get_apt_command("$conf::apt_get", "-q update", "root", 1) . " 2>&1 |")) {
> -	print PLOG "Can't open pipe to apt-get: $!\n";
> -	return 0;
> -    }
> -    while(<PIPE>) {
> -	print PLOG;
> -	print STDERR;
> -    }
> -    close(PIPE);
> -    print PLOG "apt-get update failed\n" if $?;
> -    flock(APTLOCK, LOCK_UN);
> -    close(APTLOCK);
> -    return $r;
> -}
> -
> {
>     no warnings 'redefine';
>     *Sbuild::binNMU_version = \&new_binNMU_version;
> -    *Sbuild::Chroot::begin_session = \&new_begin_session;
> }
>
> 1;
>
> Modified: trunk/debathena/scripts/sbuildhack
> ===================================================================
> --- trunk/debathena/scripts/sbuildhack	2008-05-23 00:31:37 UTC (rev 22977)
> +++ trunk/debathena/scripts/sbuildhack	2008-05-25 07:03:27 UTC (rev 22978)
> @@ -20,4 +20,4 @@
> export NMUTAG=`gettag "$dist"`
> perl -I"$(dirname "$0")" -MSbuildHack \
> 	/usr/bin/sbuild --binNMU=171717 --make-binNMU="Build with sbuild." \
> -	-d "$dist" --arch="$arch" -v "$@"
> +	-d "$dist" --arch="$arch" --apt-update -v "$@"
>
>

home help back first fref pref prev next nref lref last post