Changeset 672 in MondoRescue for trunk/tools


Ignore:
Timestamp:
Jun 12, 2006, 9:55:14 AM (18 years ago)
Author:
bcornec
Message:

merge -r651:671 $SVN_M/branches/stable

Location:
trunk/tools
Files:
7 edited
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/tools/build2pkg

    r600 r672  
    6767        pkg="$pkg $pkg1"
    6868
    69         log=/tmp/$p-rpm.log
     69        log=$TMP/$p-rpm.log
    7070
    7171        if [ "$dfam" = "mandriva" ]; then
     
    9090        cd ..
    9191    elif [  _"$dtype" = _"ebuild" ]; then
    92         log=/tmp/$p-gentoo.log
     92        log=$TMP/$p-gentoo.log
    9393        ln -sf $src .
    9494        tar xfz $src $pv/distributions/${ddir}-$dver/$p-${VER}-r$TAG.ebuild
     
    124124        fi
    125125    elif [  _"$dtype" = _"deb" ]; then
    126         log=/tmp/$p-deb.log
     126        log=$TMP/$p-deb.log
    127127        cd $TOPBUILDDIR
    128128        tar xfz $src
    129129        cd ${pv}*
    130         ln -s distributions/debian debian
    131         # update debian/changelog
    132         pkg-buildpackage -us -uc -rfakeroot
     130        # point to the right debian conf
     131        ln -s distributions/${ddir}-$dver debian
     132        dpkg-buildpackage -us -uc -rfakeroot
    133133        # Et voila !
    134134    else
     
    138138echo "Packages handled : $pkg"
    139139
     140rm -rf $TMP
     141
    140142if [ $status = 0 ]; then
    141143    if [  _"$dtype" = _"rpm" ]; then
  • trunk/tools/distro-env

    r600 r672  
    124124    fi
    125125    mkdir -p ${TOPBUILDDIR}/{RPMS,SRPMS,SPECS,SOURCES,BUILD}
     126elif [ _"$dtype" = _"deb" ]; then
     127    export TOPBUILDDIR=${BASE}/build
     128    mkdir -p ${TOPBUILDDIR}
    126129elif [ _"$dtype" = _"ebuild" ]; then
    127130    export TOPBUILDDIR=${BASE}/build
  • trunk/tools/livwww

    r588 r672  
    9292ln -sf /var/www/html/admin .
    9393
     94# Compute News
     95$TOOLHOME/mknewshtml.pl $LOCALDIR
     96
    9497if [ _"$1" == _"" ]; then
    9598        exit 0
  • trunk/tools/mkannounce

    r652 r672  
    6464rm -f $TMP/mindi.ann $TMP/mondo.ann
    6565
     66vi $TMP/announce.tmp
    6667# Store it in DB for Web pages generation
    6768$TOOLHOME/mkannounce.pl $TMP/announce.tmp
    6869# Then deliver it on the Web
    69 #$TOOLHOME/livwww www
     70$TOOLHOME/livwww www
     71cat > $TMP/announce.hdr << EOF
     72<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/x html1/DTD/xhtml1-strict.dtd">
     73
     74<html xmlns="http://www.w3.org/1999/xhtml" dir="ltr" xml:lang="en" lang="en">
     75  <head>
     76  </head>
     77  <body>
     78  <p>
     79EOF
     80cat > $TMP/announce.ftr << EOF
     81</body>
     82</html>
     83EOF
     84# Mail it to mr ML
     85cat $TMP/announce.hdr $TMP/announce.tmp $TMP/announce.ftr | w3m -dump -T text/html > $TMP/mondo.ann.txt
     86export EMAIL="bruno@mondorescue.org"
     87export TMPDIR=$TMP
     88cat $TMP/mondo.ann.txt | mutt -s "`head -1 $TMP/mondo.ann.txt`" mondo-devel@lists.sourceforge.net -c mondorescue-announce@lists.berlios.de
     89rm -rf $TMP
  • trunk/tools/mkannounce.pl

    r652 r672  
    2828    }
    2929
    30 my $db="$TOOLHOME/../website/announces.sql";
     30my $db="$TOOLHOME/../website/announces3.sql";
    3131
    3232my $dbh = DBI->connect("dbi:SQLite:dbname=$db","","",
     
    4040open(ANNOUNCE,$ARGV[0]) || die "Unable to open $ARGV[0] (read)";
    4141my $announce = <ANNOUNCE>;
    42 $announce =~ s/\"/\"\"/g;
     42#$announce =~ s/\"/\"\"/g;
     43#$announce =~ s/!//g;
    4344close(ANNOUNCE);
    4445
    4546print "INSERT INTO announces VALUES (NULL, $date, $announce)\n";
    46 #$dbh->do("INSERT INTO announces VALUES (NULL, $date, $announce)")
     47my $sth = $dbh->prepare(qq{INSERT INTO announces VALUES (NULL,?,?)})
     48        || die "Unable to insert into $db";
     49$sth->execute($date, $announce);
     50#$dbh->do(qq(INSERT INTO announces VALUES (NULL, '$date', '$announce')))
    4751#|| die "Unable to insert into $db";
     52
    4853$dbh->disconnect;
  • trunk/tools/mkchangelog.pl

    r652 r672  
    2020my $chglog = "";
    2121my $ndate = "";
     22my $n2date = "";
    2223my $tmp = "";
    2324my $ver = "";
     
    7980    #print "**$date**\n";
    8081    $ndate = UnixDate($date,"%a", "%b", "%d", "%Y");
     82    $n2date = &UnixDate($date,"%a, %d %b %Y %H:%M:%S %z");
    8183    #print "**$ndate**\n";
    8284    if ($dtype eq "rpm") {
     
    8486        print OUTPUT "- Updated to $ver\n";
    8587        }
     88    if ($dtype eq "deb") {
     89        print OUTPUT "$pkg ($ver) unstable; urgency=low\n";
     90        print OUTPUT "\n";
     91        }
    8692
    8793    $tmp = <INPUT>;
    8894    while ($tmp !~ /^$/) {
    89         print OUTPUT $tmp;
     95        if ($dtype eq "deb") {
     96            print OUTPUT "  * $tmp";
     97        }
     98        else {
     99            print OUTPUT "$tmp";
     100        }
    90101        last if (eof(INPUT));
    91102        $tmp = <INPUT>;
    92103    }
    93104    print OUTPUT "\n";
     105
     106    if ($dtype eq "deb") {
     107        print OUTPUT " -- Bruno Cornec <bruno\@mondorescue.org>  $n2date\n\n";
     108        print OUTPUT "\n";
     109        }
     110
    94111    last if (eof(INPUT));
    95112    last if ($dtype eq "announce");
  • trunk/tools/svn2build

    r652 r672  
    8585        elif [ "$dtype" = "deb" ]; then
    8686            # To be developped
    87             m4 $TMP/mondorescue.mc $dest/distributions/$dfam/$p > /dev/null
     87            #m4 $TMP/mondorescue.mc $dest/distributions/$dfam/$p > /dev/null
     88            cp -a $dest/distributions/$ddir/* $dest/distributions/${ddir}-$dver
     89            $TOOLHOME/mkchangelog.pl $dtype $p $dest/distributions/${ddir}-$dver/changelog
     90            if [ $? -ne 0 ]; then
     91                echo "Unable to create changelog for ${ddir}-$dver/changelog"
     92                exit -1
     93            fi
    8894        else
    8995            echo "Unknown Build"
     
    134140done
    135141
    136 rm -f $TMP/mondorescue.mc
     142rm -rf $TMP
    137143
    138144echo "Version delivered :"
Note: See TracChangeset for help on using the changeset viewer.