Subversion Repositories DevTools

Rev

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

Rev 375 Rev 379
Line 52... Line 52...
52
my $opt_locate_dir;
52
my $opt_locate_dir;
53
my $opt_dir;
53
my $opt_dir;
54
my $opt_java;
54
my $opt_java;
55
my $opt_export_vars = 1;
55
my $opt_export_vars = 1;
56
my $result;
56
my $result;
-
 
57
my $opt_logfile;
57
 
58
 
58
#
59
#
59
#   Grab a copy of ALL the environment variable that will be used
60
#   Grab a copy of ALL the environment variable that will be used
60
#   This will simplify the script a great deal
61
#   This will simplify the script a great deal
61
#
62
#
Line 129... Line 130...
129
            "version=s",        => \&opts_version,
130
            "version=s",        => \&opts_version,
130
            "platform:s",       => sub{ opts_extend( \$GBE_PLATFORM, @_ )},
131
            "platform:s",       => sub{ opts_extend( \$GBE_PLATFORM, @_ )},
131
            "buildfilter:s"     => sub{ opts_extend( \$GBE_BUILDFILTER, @_ )},
132
            "buildfilter:s"     => sub{ opts_extend( \$GBE_BUILDFILTER, @_ )},
132
            "abt:s"             => sub{ opts_extend( \$GBE_ABT, @_ )},
133
            "abt:s"             => sub{ opts_extend( \$GBE_ABT, @_ )},
133
            "exportvars!"       => \$opt_export_vars,
134
            "exportvars!"       => \$opt_export_vars,
-
 
135
            "logfile=s",        => \$opt_logfile,
134
            );
136
            );
135
 
137
 
136
#
138
#
137
#   Configure the error reporting process now that we have the user options
139
#   Configure the error reporting process now that we have the user options
138
#
140
#
Line 1571... Line 1573...
1571
{
1573
{
1572
    my $command = shift;
1574
    my $command = shift;
1573
    my $cmd;
1575
    my $cmd;
1574
    my @etool_path = ( "$ENV{'GBE_TOOLS'}",
1576
    my @etool_path = ( "$ENV{'GBE_TOOLS'}",
1575
                       "$ENV{'GBE_TOOLS'}/DEPLOY",
1577
                       "$ENV{'GBE_TOOLS'}/DEPLOY",
1576
                       "$ENV{'GBE_TOOLS'}/LOCAL" );
1578
                       "$ENV{'GBE_TOOLS'}/LOCAL",
-
 
1579
                        );
1577
    if ( $command )
1580
    if ( $command )
1578
    {
1581
    {
1579
        #
1582
        #
1580
        #   Locate a potential tool
1583
        #   Locate a potential tool
1581
        #   These will have the user name or a .pl extension
1584
        #   These will have the user name or a .pl extension
Line 2037... Line 2040...
2037
#
2040
#
2038
#   Process help and manual options
2041
#   Process help and manual options
2039
#       Done after all the setup to ensure that the PATH is correct
2042
#       Done after all the setup to ensure that the PATH is correct
2040
#       Done before bombout to give user a chance
2043
#       Done before bombout to give user a chance
2041
#
2044
#
-
 
2045
 
-
 
2046
#
-
 
2047
#   Redirect all output to a log file
-
 
2048
#   Only perform redirection AFTER we have setup the users environment
-
 
2049
#       May change this.
-
 
2050
#
-
 
2051
if ( $opt_logfile )
-
 
2052
{
-
 
2053
    open STDOUT, '>', $opt_logfile  or die "Can't redirect STDOUT: $!";
-
 
2054
    open STDERR, ">&STDOUT"         or die "Can't dup STDOUT: $!";
-
 
2055
}
-
 
2056
 
2042
help() if $opt_help;
2057
help() if $opt_help;
2043
ErrorDoExit();  # Exit if any error in setup
2058
ErrorDoExit();  # Exit if any error in setup
2044
ErrorConfig( 'on_exit'    => \&do_exit );
2059
ErrorConfig( 'on_exit'    => \&do_exit );
2045
 
2060
 
2046
#
2061
#
Line 2126... Line 2141...
2126
    -abt=[xxx]          - Set GBE_ABT to xxx (=+ to append)
2141
    -abt=[xxx]          - Set GBE_ABT to xxx (=+ to append)
2127
    -java=version       - Alters java version used (1.4, 1.5, 1.6)
2142
    -java=version       - Alters java version used (1.4, 1.5, 1.6)
2128
    -time               - Time build and compile times
2143
    -time               - Time build and compile times
2129
    -version=xxx        - Use specified version of JATS
2144
    -version=xxx        - Use specified version of JATS
2130
    -[no]exportvars     - Export sanitised JATS EnvVars (default)
2145
    -[no]exportvars     - Export sanitised JATS EnvVars (default)
-
 
2146
    -logfile=xxxx       - All output is redirected to the specified file
2131
 
2147
 
2132
 Common commands include:
2148
 Common commands include:
2133
    build               - Rebuild the sandbox and makefiles
2149
    build               - Rebuild the sandbox and makefiles
2134
    make                - Make one or more components
2150
    make                - Make one or more components
2135
    ant                 - Invoke an ant build
2151
    ant                 - Invoke an ant build
Line 2320... Line 2336...
2320
programs running under JATS. The use of NoExportVars will prevent JATS from
2336
programs running under JATS. The use of NoExportVars will prevent JATS from
2321
exporting modified EnvVars into the environment. This may be required by
2337
exporting modified EnvVars into the environment. This may be required by
2322
processes, such as the build daemons that need to pick up the current version of
2338
processes, such as the build daemons that need to pick up the current version of
2323
JATS on the fly and not have it fixed when the daemon is started.
2339
JATS on the fly and not have it fixed when the daemon is started.
2324
 
2340
 
-
 
2341
=item B<-logfile=xxxx>
-
 
2342
 
-
 
2343
This option will cause all output to be redirected to the named logroll. Both
-
 
2344
STDOUT and STDERR will be redirected.
-
 
2345
 
-
 
2346
The redirection occurs after the sanity testing that JATS performs and before the
-
 
2347
user command is invoked. The redirection occurs after any directory change option
-
 
2348
is executed.
-
 
2349
 
-
 
2350
Output redirection continues until the program terminates. If JATS invokes other
-
 
2351
programs or scripts, there default output will also be redirected.
-
 
2352
 
2325
=back
2353
=back
2326
 
2354
 
2327
=head1 ARGUMENTS
2355
=head1 ARGUMENTS
2328
 
2356
 
2329
=head2 Basic Commands
2357
=head2 Basic Commands