Changeset 448 in ProjectBuilder for devel/pb/bin/pb


Ignore:
Timestamp:
May 26, 2008, 10:41:45 AM (16 years ago)
Author:
Bruno Cornec
Message:
  • Fake Changelog for test version
  • setupvm improved with init level 3 by default
  • still issue for pb on Debian with the devel version name, and the mixed cases for modules unallowed
File:
1 edited

Legend:

Unmodified
Added
Removed
  • devel/pb/bin/pb

    r444 r448  
    488488        my $chglog;
    489489
    490         if ((defined $testver) && (defined $testver->{$ENV{'PBPROJ'}}) && ($testver->{$ENV{'PBPROJ'}} =~ /true/i)) {
    491             if (! -f "$dest/NEWS") {
    492                 open(NEWS,"> $dest/NEWS") || die "Unable to create $dest/NEWS";
    493                 close(NEWS);
    494             }
    495             open(CL,"> $dest/ChangeLog") || die "Unable to create $dest/ChangeLog";
    496             close(CL);
    497             open(CL,"> $dest/$ENV{'PBCMSLOGFILE'}") || die "Unable to create $dest/$ENV{'PBCMSLOGFILE'}";
    498             close(CL);
    499             $chglog = undef;
    500         } else {
    501 
    502             # Get project info on authors and log file
    503             $chglog = "$ENV{'PBROOTDIR'}/$pbpkg/pbcl";
    504             $chglog = "$ENV{'PBROOTDIR'}/pbcl" if (! -f $chglog);
    505             $chglog = undef if (! -f $chglog);
    506 
    507             my $authors = "$ENV{'PBROOTDIR'}/$pbpkg/pbauthors";
    508             $authors = "$ENV{'PBROOTDIR'}/pbauthors" if (! -f $authors);
    509             $authors = "/dev/null" if (! -f $authors);
    510 
    511             # Extract cms log history and store it
    512             if ((defined $chglog) && (! -f "$dest/NEWS")) {
    513                 pb_log(2,"Generating NEWS file from $chglog\n");
    514                 copy($chglog,"$dest/NEWS") || die "Unable to create $dest/NEWS";
    515             }
    516             pb_cms_log($scheme,"$ENV{'PBDIR'}/$dir",$dest,$chglog,$authors);
    517         }
     490        # Get project info on authors and log file
     491        $chglog = "$ENV{'PBROOTDIR'}/$pbpkg/pbcl";
     492        $chglog = "$ENV{'PBROOTDIR'}/pbcl" if (! -f $chglog);
     493        $chglog = undef if (! -f $chglog);
     494
     495        my $authors = "$ENV{'PBROOTDIR'}/$pbpkg/pbauthors";
     496        $authors = "$ENV{'PBROOTDIR'}/pbauthors" if (! -f $authors);
     497        $authors = "/dev/null" if (! -f $authors);
     498
     499        # Extract cms log history and store it
     500        if ((defined $chglog) && (! -f "$dest/NEWS")) {
     501            pb_log(2,"Generating NEWS file from $chglog\n");
     502            copy($chglog,"$dest/NEWS") || die "Unable to create $dest/NEWS";
     503        }
     504        pb_cms_log($scheme,"$ENV{'PBDIR'}/$dir",$dest,$chglog,$authors,$testver);
    518505
    519506        my %build;
     
    697684            symlink "pbconf/$ddir-$dver","debian" || die "Unable to symlink to pbconf/$ddir-$dver";
    698685            chmod 0755,"debian/rules";
     686            if ($dver !~ /[0-9]/) {
     687                # dpkg-deb doesn't accept non digit versions. removing checks
     688                # dpkg-source checks upper case when generating perl modules
     689            }
    699690            pb_system("dpkg-buildpackage -us -uc -rfakeroot","Building package");
    700691            $made="$made $pbpkg"."_*.deb $pbpkg"."_*.dsc $pbpkg"."_*.tar.gz";
     
    15101501chmod 0640,$file;
    15111502
     1503# Keep the VM in text mode
     1504$file="/etc/inittab";
     1505open(PBFILE,$file) || die "Unable to open $file";
     1506open(PBOUT,"> $file.new") || die "Unable to open $file.new";
     1507while (<PBFILE>) {
     1508    s/^(..):5:initdefault:$/$1:3:initdefault:/;
     1509    print PBOUT $_;
     1510}
     1511close(PBFILE);
     1512close(PBOUT);
     1513rename("$file.new",$file);
     1514chmod 0640,$file;
     1515
    15121516# pb has to be added to portage group on gentoo
    15131517
Note: See TracChangeset for help on using the changeset viewer.