Changeset 890


Ignore:
Timestamp:
Oct 27, 2009, 11:54:28 AM (10 years ago)
Author:
Bruno Cornec
Message:
  • Adds solaris support to pb_env_init (template file creation)
  • Simplify pb_changelog when dest ChangeLog? file exists
Location:
devel/pb/lib/ProjectBuilder
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • devel/pb/lib/ProjectBuilder/CMS.pm

    r873 r890  
    779779}
    780780
    781 if ($scheme =~ /^svn/) {
    782     if (! -f "$dest/ChangeLog") {
     781if (! -f "$dest/ChangeLog") {
     782    if ($scheme =~ /^svn/) {
    783783        # In case we have no network, just create an empty one before to allow correct build
    784784        open(CL,"> $dest/ChangeLog") || die "Unable to create $dest/ChangeLog";
     
    790790            pb_system("$vcscmd log -v $pkgdir > $dest/$ENV{'PBCMSLOGFILE'}","Extracting log info from SVN");
    791791        }
    792     }
    793 } elsif ($scheme =~ /^svk/) {
    794     if (! -f "$dest/ChangeLog") {
     792    } elsif ($scheme =~ /^svk/) {
    795793        pb_system("$vcscmd log -v $pkgdir > $dest/$ENV{'PBCMSLOGFILE'}","Extracting log info from SVK");
    796         }
    797 } elsif ($scheme =~ /^hg/) {
    798     if (! -f "$dest/ChangeLog") {
     794    } elsif ($scheme =~ /^hg/) {
    799795        # In case we have no network, just create an empty one before to allow correct build
    800796        open(CL,"> $dest/ChangeLog") || die "Unable to create $dest/ChangeLog";
    801797        close(CL);
    802798        pb_system("$vcscmd log -v $pkgdir > $dest/$ENV{'PBCMSLOGFILE'}","Extracting log info from SVN");
    803         }
    804 } elsif ($scheme =~ /^git/) {
    805     if (! -f "$dest/ChangeLog") {
     799    } elsif ($scheme =~ /^git/) {
    806800        # In case we have no network, just create an empty one before to allow correct build
    807801        open(CL,"> $dest/ChangeLog") || die "Unable to create $dest/ChangeLog";
    808802        close(CL);
    809803        pb_system("$vcscmd log -v $pkgdir > $dest/$ENV{'PBCMSLOGFILE'}","Extracting log info from GIT");
    810         }
    811 } elsif (($scheme eq "file") || ($scheme eq "dir") || ($scheme eq "http") || ($scheme eq "ftp")) {
    812     if (! -f "$dest/ChangeLog") {
     804    } elsif (($scheme eq "file") || ($scheme eq "dir") || ($scheme eq "http") || ($scheme eq "ftp")) {
    813805        pb_system("echo ChangeLog for $pkgdir > $dest/ChangeLog","Empty ChangeLog file created");
    814     }
    815 } elsif ($scheme =~ /^cvs/) {
    816     my $tmp=basename($pkgdir);
    817     # CVS needs a relative path !
    818     if (! -f "$dest/ChangeLog") {
     806    } elsif ($scheme =~ /^cvs/) {
     807        my $tmp=basename($pkgdir);
     808        # CVS needs a relative path !
    819809        # In case we have no network, just create an empty one before to allow correct build
    820810        open(CL,"> $dest/ChangeLog") || die "Unable to create $dest/ChangeLog";
     
    826816            pb_system("$vcscmd log $tmp > $dest/$ENV{'PBCMSLOGFILE'}","Extracting log info from CVS");
    827817        }
    828     }
    829 } else {
    830     die "cms $scheme unknown";
     818    } else {
     819        die "cms $scheme unknown";
     820    }
    831821}
    832822}
  • devel/pb/lib/ProjectBuilder/Env.pm

    r865 r890  
    412412# a QEMU rhel-3-i286 here means that the VM will be named rhel-3-i386.qemu
    413413#
    414 #vmlist $ENV{'PBPROJ'} = mandrake-10.1-i386,mandrake-10.2-i386,mandriva-2006.0-i386,mandriva-2007.0-i386,mandriva-2007.1-i386,mandriva-2008.0-i386,redhat-7.3-i386,redhat-9-i386,fedora-4-i386,fedora-5-i386,fedora-6-i386,fedora-7-i386,fedora-8-i386,rhel-3-i386,rhel-4-i386,rhel-5-i386,suse-10.0-i386,suse-10.1-i386,suse-10.2-i386,suse-10.3-i386,sles-9-i386,sles-10-i386,gentoo-nover-i386,debian-3.1-i386,debian-4.0-i386,ubuntu-6.06-i386,ubuntu-7.04-i386,ubuntu-7.10-i386,mandriva-2007.0-x86_64,mandriva-2007.1-x86_64,mandriva-2008.0-x86_64,fedora-6-x86_64,fedora-7-x86_64,fedora-8-x86_64,rhel-4-x86_64,rhel-5-x86_64,suse-10.2-x86_64,suse-10.3-x86_64,sles-10-x86_64,gentoo-nover-x86_64,debian-4.0-x86_64,ubuntu-7.04-x86_64,ubuntu-7.10-x86_64
     414#vmlist $ENV{'PBPROJ'} = mandrake-10.1-i386,mandrake-10.2-i386,mandriva-2006.0-i386,mandriva-2007.0-i386,mandriva-2007.1-i386,mandriva-2008.0-i386,redhat-7.3-i386,redhat-9-i386,fedora-4-i386,fedora-5-i386,fedora-6-i386,fedora-7-i386,fedora-8-i386,rhel-3-i386,rhel-4-i386,rhel-5-i386,suse-10.0-i386,suse-10.1-i386,suse-10.2-i386,suse-10.3-i386,sles-9-i386,sles-10-i386,gentoo-nover-i386,debian-3.1-i386,debian-4.0-i386,ubuntu-6.06-i386,ubuntu-7.04-i386,ubuntu-7.10-i386,mandriva-2007.0-x86_64,mandriva-2007.1-x86_64,mandriva-2008.0-x86_64,fedora-6-x86_64,fedora-7-x86_64,fedora-8-x86_64,rhel-4-x86_64,rhel-5-x86_64,suse-10.2-x86_64,suse-10.3-x86_64,sles-10-x86_64,gentoo-nover-x86_64,debian-4.0-x86_64,ubuntu-7.04-x86_64,ubuntu-7.10-x86_64,solaris-10-x86_64
    415415
    416416#
     
    956956                close(CONF);
    957957                pb_mkdir_p("$ENV{'PBROOTDIR'}/$pp/pbfilter") || die "Unable to create $ENV{'PBROOTDIR'}/$pp/pbfilter";
     958                pb_mkdir_p("$ENV{'PBROOTDIR'}/$pp/pkg") || die "Unable to create $ENV{'PBROOTDIR'}/$pp/pkg";
     959                open(CONF,"> $ENV{'PBROOTDIR'}/$pp/pkg/pkginfo") || die "Unable to create $ENV{'PBROOTDIR'}/$pp/pkg/pkginfo";
     960                print CONF << 'EOF';
     961#
     962# $Id$
     963#
     964PKG="PBREALPKG"
     965NAME="PBSUMMARY"
     966VERSION="PBVER"
     967# or i386
     968ARCH="all"
     969CATEGORY="application"
     970DESC="PBDESC"
     971EMAIL="PBPACKAGER"
     972VENDOR="PBPACKAGER"
     973HOTLINE="PBURL"
     974EOF
     975                close(CONF);
     976                open(CONF,"> $ENV{'PBROOTDIR'}/$pp/pkg/pbbuild") || die "Unable to create $ENV{'PBROOTDIR'}/$pp/pkg/pbbuild";
     977                print CONF << 'EOF';
     978#
     979# $Id$
     980#
     981#perl Makefile.PL INSTALLDIRS=vendor
     982./configure --prefix=/usr
     983make
     984make install DESTDIR=\$1
     985EOF
     986                close(CONF);
     987                open(CONF,"> $ENV{'PBROOTDIR'}/$pp/pkg/depend") || die "Unable to create $ENV{'PBROOTDIR'}/$pp/pkg/depend";
     988                print CONF << 'EOF';
     989#
     990# $Id$
     991#
     992#P SUNWperl584core       Perl 5.8.4 (core)
     993EOF
     994                close(CONF);
    958995   
    959996            }
Note: See TracChangeset for help on using the changeset viewer.