[pkg-bioc] svn commit r324 r324 - in /trunk/tools-ng: pkgbioc.pm r_pkg_ordering.pl r_pkg_prepare.sh r_pkg_update.pl

psychedelys-guest at users.alioth.debian.org psychedelys-guest at users.alioth.debian.org
Wed Sep 26 14:08:32 UTC 2007


Author: psychedelys-guest
Date: Wed Sep 26 14:08:32 2007
New Revision: 324

URL: http://svn.debian.org/wsvn/pkg-bioc/?sc=1&rev=324
Log:
created a web sirectory for storing the repport and a switch for not removing failed build dir

Modified:
    trunk/tools-ng/pkgbioc.pm
    trunk/tools-ng/r_pkg_ordering.pl
    trunk/tools-ng/r_pkg_prepare.sh
    trunk/tools-ng/r_pkg_update.pl

Modified: trunk/tools-ng/pkgbioc.pm
URL: http://svn.debian.org/wsvn/pkg-bioc/trunk/tools-ng/pkgbioc.pm?rev=324&op=diff
==============================================================================
--- trunk/tools-ng/pkgbioc.pm (original)
+++ trunk/tools-ng/pkgbioc.pm Wed Sep 26 14:08:32 2007
@@ -101,9 +101,9 @@ sub MarkedPackageUnbuildable ($$$$) {
     push( @{ $global->{cannotbuild}->{$package} }, $msg );
 
     # remove the $packagehashref->{BuildDir} if the directory is here....
-    if ( -d $packagehashref->{BuildDir} ) {
-
-        # system("rm -rf $packagehashref->{BuildDir}");
+	# if it's failing, the next call of r_pkg_update, will clean it.
+    if (( ! $main::inspectfailedbuild ) && ( -d $packagehashref->{BuildDir} )) {
+        system("rm -rf $packagehashref->{BuildDir}");
     }
 
     # print "\n";

Modified: trunk/tools-ng/r_pkg_ordering.pl
URL: http://svn.debian.org/wsvn/pkg-bioc/trunk/tools-ng/r_pkg_ordering.pl?rev=324&op=diff
==============================================================================
--- trunk/tools-ng/r_pkg_ordering.pl (original)
+++ trunk/tools-ng/r_pkg_ordering.pl Wed Sep 26 14:08:32 2007
@@ -86,6 +86,10 @@ This script will be executed under Debia
 
 	desactive the QA check: lintian & linda 
 
+=item --inspectfailedbuild
+
+	do not remove directory if the build is failing.
+
 # TODO option not yet implemented 
 # --builddebian
 # --dryrun
@@ -107,7 +111,7 @@ use Cwd;
 use vars qw($help $man $debug $verbose $dryrun $VERSION);
 
 #the specific variables
-use vars qw($rebuildall $noQAcheck $builddebian);
+use vars qw($rebuildall $noQAcheck $builddebian $inspectfailedbuild);
 
 my $origpath = cwd;
 
@@ -151,13 +155,12 @@ use debtag;
 # unbuffered output:
 $| = 1;
 
-# TODO update it to make it working with SVN....
 my $revision = ' $Rev$ ';
 my $name;
 $revision =~ / ([\d\.]*) /;
 $VERSION = $1;
 ($name = $0) =~ s|.*/||;
-print("$name $VERSION\n");
+print("$name rev:$VERSION\n");
 
 my %options = (
     "help"        => \$help,
@@ -168,6 +171,7 @@ my %options = (
     "rebuildall"  => \$rebuildall,
     "noQAcheck"   => \$noQAcheck,
     "builddebian" => \$builddebian,
+	"inspectfailedbuild" => \$inspectfailedbuild,
 );
 
 help() if !GetOptions(%options) or $help or $man;
@@ -187,7 +191,7 @@ use vars qw(
 
   $RepositoryListFlat $bioccurrent $listdirectory $maxsize
   $Lang $sources $builds $installMethods $binarch $maintainermail
-  $patchessourcedir
+  $patchessourcedir $webdir
 
   $AptSourcesList $AptStateDir $AptDpkgDir $AptCacheDir $AptParams
   $AptAliothSourcesList $AptAliothStateDir $AptAliothDpkgDir
@@ -823,11 +827,15 @@ foreach my $package (@nodes) {
     if ( !$noQAcheck ) {
         doQAcheck( $debfile, $qalogfile );
     }
+    if ( -d $packagehashref->{BuildDir} ) {
+        system("rm -rf $packagehashref->{BuildDir}");
+    }
+
 
 }
 
 # printing the duplicated packages
-open( HTML, ">duplicated.html" )
+open( HTML, ">$webdir/duplicated.html" )
   || die "Cannot open for writting duplicated.html !\n";
 print HTML "\n----------------------------------\n";
 print HTML "The list of duplicated package are:\n";
@@ -843,7 +851,7 @@ print HTML "\n";
 HTML->close;
 
 # printing the unbuildable packages
-open( HTML, ">cannotbuild.html" )
+open( HTML, ">$webdir/cannotbuild.html" )
   || die "Cannot open for writting cannotbuild.html !\n";
 
 print HTML "\n----------------------------------\n";

Modified: trunk/tools-ng/r_pkg_prepare.sh
URL: http://svn.debian.org/wsvn/pkg-bioc/trunk/tools-ng/r_pkg_prepare.sh?rev=324&op=diff
==============================================================================
--- trunk/tools-ng/r_pkg_prepare.sh (original)
+++ trunk/tools-ng/r_pkg_prepare.sh Wed Sep 26 14:08:32 2007
@@ -108,6 +108,9 @@ patchessourcedir="../${toolsdirectory}/p
 #List of the repository to build
 RepositoryList=""
 
+# Directory where we are storing the web stuff
+webdir="../web"
+
 Lang=""
 ### END - STUFF that we export - END ###
 
@@ -220,6 +223,13 @@ do 
     done
 done
 
+echo
+echo "creating the web directory for storing repport"
+echo
+
+if [ ! -d "${webdir}" ]; then
+	 mkdir -p "${webdir}"
+fi
 
 echo
 echo "creating all directories for using apt 'magic'"
@@ -503,6 +513,10 @@ echo -n "\$maxsize = '" >> ${AUTOVARS}
 echo -n ${maxsize} >> ${AUTOVARS}
 echo "';" >> ${AUTOVARS} 
 
+echo -n "\$webdir = '" >> ${AUTOVARS}
+echo -n ${webdir} >> ${AUTOVARS}
+echo "';" >> ${AUTOVARS} 
+
 echo -n "\$listdirectory = '" >> ${AUTOVARS}
 echo -n ${listdirectory} >> ${AUTOVARS}
 echo "';" >> ${AUTOVARS} 

Modified: trunk/tools-ng/r_pkg_update.pl
URL: http://svn.debian.org/wsvn/pkg-bioc/trunk/tools-ng/r_pkg_update.pl?rev=324&op=diff
==============================================================================
--- trunk/tools-ng/r_pkg_update.pl (original)
+++ trunk/tools-ng/r_pkg_update.pl Wed Sep 26 14:08:32 2007
@@ -152,13 +152,12 @@ use debtag;
 # unbuffered output:
 $| = 1;
 
-# TODO update it to make it working with SVN....
 my $revision = ' $Rev$ ';
 my $name;
 $revision =~ / ([\d\.]*) /;
 $VERSION = $1;
 ($name = $0) =~ s|.*/||;
-print("$name $VERSION\n");
+print("$name rev:$VERSION\n");
 
 my %options = (
     "help"            => \$help,
@@ -188,7 +187,7 @@ use vars qw(
 
   $RepositoryListFlat $bioccurrent $listdirectory $maxsize
   $Lang $sources $builds $installMethods $binarch $maintainermail
-  $patchessourcedir
+  $patchessourcedir $webdir
 
   $AptSourcesList $AptStateDir $AptDpkgDir $AptCacheDir $AptParams
   $AptAliothSourcesList $AptAliothStateDir $AptAliothDpkgDir




More information about the pkg-bioc-devel mailing list