Subversion Repositories DevTools

Rev

Rev 269 | Rev 285 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 269 Rev 279
Line 32... Line 32...
32
use Getopt::Long;
32
use Getopt::Long;
33
use File::Find;
33
use File::Find;
34
use File::Copy;
34
use File::Copy;
35
use File::Path;
35
use File::Path;
36
use Cwd;
36
use Cwd;
37
use Sys::Hostname;                          # For hostname
-
 
38
 
37
 
39
my $VERSION = "1.6.0";                      # Update this
38
my $VERSION = "1.6.0";                      # Update this
40
 
39
 
41
#
40
#
42
#   Options
41
#   Options
Line 77... Line 76...
77
my $USER            = $ENV{'USER'};
76
my $USER            = $ENV{'USER'};
78
my $UNIX            = $ENV{'GBE_UNIX'};
77
my $UNIX            = $ENV{'GBE_UNIX'};
79
my $HOME            = $ENV{'HOME'};
78
my $HOME            = $ENV{'HOME'};
80
my $GBE_SANDBOX     = $ENV{'GBE_SANDBOX'};
79
my $GBE_SANDBOX     = $ENV{'GBE_SANDBOX'};
81
my $GBE_ABT         = $ENV{'GBE_ABT'} || '0';
80
my $GBE_ABT         = $ENV{'GBE_ABT'} || '0';
-
 
81
my $MACHINENAME     = $ENV{'GBE_HOSTNAME'};
82
 
82
 
83
#
83
#
84
#   Globals
84
#   Globals
85
#
85
#
86
my $MACHINENAME;
-
 
87
my $VIEWDIR_ROOT = "c:/clearcase";          # Root of all static views (WIN32)
86
my $VIEWDIR_ROOT = "c:/clearcase";          # Root of all static views (WIN32)
88
my $VIEWTAG;                                # The view tag
87
my $VIEWTAG;                                # The view tag
89
my $VIEWDIR;                                # Absolute path to the view
88
my $VIEWDIR;                                # Absolute path to the view
90
my $VIEWPATH;                               # Path relative to clearcase
89
my $VIEWPATH;                               # Path relative to clearcase
91
my $user_cwd;
90
my $user_cwd;
Line 286... Line 285...
286
#
285
#
287
#   Determine the machine type
286
#   Determine the machine type
288
#
287
#
289
Verbose ("Machine Type: UNIX=$UNIX");
288
Verbose ("Machine Type: UNIX=$UNIX");
290
 
289
 
291
$MACHINENAME = hostname;
-
 
292
Error ("Machine Name not determined")
290
Error ("Machine Name not determined")
293
    unless ( $MACHINENAME );
291
    unless ( $MACHINENAME );
294
chomp( $MACHINENAME );
-
 
295
$user_cwd = getcwd;
292
$user_cwd = getcwd;
296
 
293
 
297
Error ("USER name not determined" )
294
Error ("USER name not determined" )
298
    unless ( $USER );
295
    unless ( $USER );
299
 
296
 
Line 795... Line 792...
795
    my $build_dir = $be->{dir};
792
    my $build_dir = $be->{dir};
796
    chdir ("$build_dir") or Error( "Cannot chdir to build directory: $build_dir");
793
    chdir ("$build_dir") or Error( "Cannot chdir to build directory: $build_dir");
797
    if ( $opt_dpkg )
794
    if ( $opt_dpkg )
798
    {
795
    {
799
        Message ("Using: $build_dir");
796
        Message ("Using: $build_dir");
800
        my $create_opts = "-o";
797
        my @create_opts = "-o";
801
        $create_opts .= " -m" if ( $opt_merge );
798
        push @create_opts ,"-m" if ( $opt_merge );
802
        JatsCmd('-here', 'create_dpkg', $create_opts, '-pname', $be->{name}, '-pversion', $be->{version}) and $error++;
799
        JatsCmd('-here', 'create_dpkg', @create_opts, '-pname', $be->{name}, '-pversion', $be->{version}) and $error++;
803
    }
800
    }
804
 
801
 
805
    if ( $opt_copy )
802
    if ( $opt_copy )
806
    {
803
    {
807
        Message ("Copy package to $user_cwd");
804
        Message ("Copy package to $user_cwd");