Changeset 17 in ProjectBuilder for devel/pb/lib/pb.pm


Ignore:
Timestamp:
Jul 30, 2007, 8:03:52 PM (17 years ago)
Author:
Bruno Cornec
Message:

Still in dev. phase - lots of changes - near the end for cms2build

File:
1 edited

Legend:

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

    r15 r17  
    1111@ISA = qw(Exporter);
    1212# global vars are here
    13 @EXPORT_OK = qw(%defpkgdir %extpkgdir %version @filteredfiles &pb_init);
     13@EXPORT_OK = qw(%defpkgdir %extpkgdir %version %param %filteredfiles &pb_init);
    1414use vars @EXPORT_OK;
    15 use AppConfig qw(ARGCOUNT_ONE ARGCOUNT_HASH ARGCOUNT_LIST EXPAND_ALL);
     15use AppConfig qw(ARGCOUNT_HASH);
    1616
    1717sub pb_init {
     
    2424                            CREATE => 1,
    2525                            DEBUG => 0,
     26                            GLOBAL => {
     27                                # Each conf item is a hash
     28                                ARGCOUNT => AppConfig::ARGCOUNT_HASH
     29                            }
    2630                        });
    27 $config->define("pbroot" => { ARGCOUNT => ARGCOUNT_ONE, EXPAND => EXPAND_ALL });
    28 $config->define("cvsroot" => { ARGCOUNT => ARGCOUNT_ONE });
    29 $config->define("defpkgdir" => { ARGCOUNT => ARGCOUNT_HASH });
    30 $config->define("extpkgdir" => { ARGCOUNT => ARGCOUNT_HASH });
    31 $config->define("version" => { ARGCOUNT => ARGCOUNT_HASH });
    32 $config->define("filteredfiles" => { ARGCOUNT => ARGCOUNT_LIST });
    33 
    3431$config->file($conffile);
    3532
     
    3734# needs at least 2 levels of dir as in the upper
    3835# other dirs will be created and used
    39 $ENV{'PBROOT'} = $config->get("pbroot") || die "Unable to find pbroot in $conffile";
    40 
    41 # If CVS, gives the way to login
    42 $ENV{'CVSROOT'} = $config->get("cvsroot");
     36$ptr = $config->get("param");
     37%param = %$ptr;
    4338
    4439# List of pkg to build by default
     
    5651# List of files to filter
    5752$ptr = $config->get("filteredfiles");
    58 @filteredfiles = @$ptr;
     53%filteredfiles = %$ptr;
    5954
    6055}
Note: See TracChangeset for help on using the changeset viewer.