Changeset 973 in ProjectBuilder


Ignore:
Timestamp:
Feb 19, 2010, 3:55:50 AM (14 years ago)
Author:
Bruno Cornec
Message:

Split function pb_env_init and add function pb_env_init_pbrc needed for rpmbootstrap

File:
1 edited

Legend:

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

    r933 r973  
    3131 
    3232our @ISA = qw(Exporter);
    33 our @EXPORT = qw(pb_env_init);
     33our @EXPORT = qw(pb_env_init pb_env_init_pbrc);
    3434
    3535=pod
     
    4747=over 4
    4848
    49 =item B<pb_env_init>
    50 
    51 This function setup the environment for project-builder.
    52 The first parameter is the project if given on the command line.
    53 The second parameter is a flag indicating whether we should setup up the pbconf environment or not.
    54 The third parameter is the action passed to pb.
    55 It sets up environement variables (PBETC, PBPROJ, PBDEFDIR, PBBUILDDIR, PBROOTDIR, PBDESTDIR, PBCONFDIR, PBPROJVER)
     49=item B<pb_env_init_pbrc>
     50
     51This function setup/use the configuration file in the HOME directory
     52It sets up environment variables (PBETC)
    5653
    5754=cut
    5855
    59 sub pb_env_init {
    60 
    61 my $proj=shift || undef;
    62 my $pbinit=shift || undef;
    63 my $action=shift;
    64 my $ver;
    65 my $tag;
     56sub pb_env_init_pbrc {
    6657
    6758$ENV{'PBETC'} = "$ENV{'HOME'}/.pbrc";
     
    111102# We only have one configuration file for now.
    112103pb_conf_add("$ENV{'PBETC'}");
     104}
     105
     106=item B<pb_env_init>
     107
     108This function setup the environment for project-builder.
     109The first parameter is the project if given on the command line.
     110The second parameter is a flag indicating whether we should setup up the pbconf environment or not.
     111The third parameter is the action passed to pb.
     112It sets up environement variables (PBETC, PBPROJ, PBDEFDIR, PBBUILDDIR, PBROOTDIR, PBDESTDIR, PBCONFDIR, PBPROJVER)
     113
     114=cut
     115
     116sub pb_env_init {
     117
     118my $proj=shift || undef;
     119my $pbinit=shift || undef;
     120my $action=shift;
     121my $ver;
     122my $tag;
     123
     124pb_env_init_pbrc();
    113125
    114126#
Note: See TracChangeset for help on using the changeset viewer.