Changeset 1109 in ProjectBuilder for devel/pb-modules


Ignore:
Timestamp:
Nov 17, 2010, 12:40:28 PM (13 years ago)
Author:
Bruno Cornec
Message:

r4041@localhost: bruno | 2010-11-17 11:40:41 +0100

  • Adds new configuration parameters (oschkcmd, oschkopt) to externalize package checking command
  • Adds new configuration parameters (pbinstalltype, pbpkg) to start allowing installation of pb in VM/VE with packages or files (this last is only needed by upstream)
  • Remove dependency on Mail::Sendmail to where it's really needed (part of Log, not used yet, and annouce). In particular this removes one non std dep for VE/VM build.
Location:
devel/pb-modules
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • devel/pb-modules/etc/pb.conf

    r1108 r1109  
    405405#ospkgdep pkg = wget,make,perl
    406406# And also need ftp://ftp.sunfreeware.com/pub/freeware/sparc/10/sudo-1.7.2p1-sol10-sparc-local.gz ftp://ftp.sunfreeware.com/pub/freeware/sparc/10/make-3.81-sol10-sparc-local.gz ftp://ftp.sunfreeware.com/pub/freeware/intel/10/libintl-3.4.0-sol10-x86-local.gz ftp://ftp.sunfreeware.com/pub/freeware/intel/10/libiconv-1.9.2-sol10-x86-local.gz ftp://ftp.sunfreeware.com/pub/freeware/intel/10/libgcc-3.4.6-sol10-x86-local.gz
     407#
    407408
    408409# Version of the perl module as found on CPAN
     
    436437#oscmdopt rpmbootstrap =
    437438#
     439# Commands to check packages
     440#
     441oschkcmd rpm = /usr/bin/rpmlint
     442oschkopt rpm =
     443oschkcmd deb = /usr/bin/lintian
     444oschkopt deb =
  • devel/pb-modules/etc/pb.conf.pod

    r1072 r1109  
    7070 Conffile: pb
    7171 Example: osambiguous debian = debian,ubuntu
     72
     73=item B<oschkcmd>
     74
     75 Nature: Optional
     76 Key: OS (could be from the most generic up to the most specific from ostype, osfamily, os, os-ver, os-ver-arch).
     77 Value: package checker tool.
     78 Conffile: pb
     79 Example: oschkcmd deb = /usr/bin/lintian
     80
     81=item B<oschkopt>
     82
     83 Nature: Optional
     84 Key: OS (could be from the most generic up to the most specific from ostype, osfamily, os, os-ver, os-ver-arch).
     85 Value: package checker tool options.
     86 Conffile: pb
     87 Example: oschkcmd rpm = -i
    7288
    7389=item B<oscodename>
     
    200216 Example: pbdefdir default = $ENV{'HOME'}/local/pb/projects
    201217
     218=item B<pbinstalltype>
     219
     220 Nature: Mandatory
     221 Key: project (as defined in the -p option or PBPROJ environment variable)
     222 Value: file or pkg. Indicates how pb will be installed during the setupve|vm phase in the virtual environment|machine, using CPAN files or upstream packages. Only the dev team needs to use file as packages do not yet exist for it. Or when no repository exists to pull project-builder.org from.
     223 Conffile: pb
     224
    202225=item B<pbml>
    203226
     
    215238 Conffile: project
    216239 Example: pbpackager pb = Bruno Cornec <bruno@project-builder.org>
     240
     241=item B<pbpkg>
     242
     243 Nature: Optional (Mandatory if pbinstalltype is pkg)
     244 Key: OS (could be from the most generic up to the most specific from ostype, osfamily, os, os-ver, os-ver-arch).
     245 Value: coma separated list of packages that have to be installed in order for pb to be operational in the VE|VM
     246 Conffile: pb
     247 Example: pbpkg rhel-5 = project-builder
    217248
    218249=item B<pbprojdir>
  • devel/pb-modules/lib/ProjectBuilder/Log.pm

    r1090 r1109  
    55
    66use strict;
    7 use Mail::Sendmail;
    87use ProjectBuilder::Base;
    98use ProjectBuilder::Log::Item;
     
    227226# mails the summary to $to
    228227sub mailSummary {
     228    require Mail::Sendmail;
    229229    my $self = shift;
    230230    my $to = shift || "";
     
    239239        Message => $self->summary()
    240240    );
    241     sendmail(%mail) or return $Mail::Sendmail::error;
     241    if (! sendmail(%mail)) {
     242        if (defined $Mail::Sendmail::error) {
     243            return $Mail::Sendmail::error;
     244        } else {
     245            return "Unkown error";
     246        }
     247    }
    242248    pb_log(0,"Mail send to ". $to ."\n");
    243249}
  • devel/pb-modules/t/Base.t

    r1106 r1109  
    55use strict;
    66use ProjectBuilder::Base;
    7 use Test;
    87
    98eval
     
    1514# Test::More not found so no test will be performed here
    1615if ($@) {
    17     BEGIN { plan tests => 1 };
     16    require Test;
     17    plan(tests => 1);
    1818    print "# Faking tests as test::More is not available\n";
    1919    ok(1,1);
  • devel/pb-modules/t/Log.t

    r1106 r1109  
    55use strict;
    66use ProjectBuilder::Base;
    7 use Test;
    87
    98eval
     
    1514# Test::More not found so no test will be performed here
    1615if ($@) {
    17     BEGIN { plan tests => 1 };
     16    require Test;
     17    plan(tests => 1);
    1818    print "# Faking tests as test::More is not available\n";
    1919    ok(1,1);
Note: See TracChangeset for help on using the changeset viewer.