diff options
author | elliott_c <ocielliottc@users.noreply.github.com> | 2006-01-19 19:00:30 +0000 |
---|---|---|
committer | elliott_c <ocielliottc@users.noreply.github.com> | 2006-01-19 19:00:30 +0000 |
commit | 0c7484507851cbf204a5e2b8fb666f1506e494cb (patch) | |
tree | d4f0a71989d047be581fb210f4807a0455deb2c4 | |
parent | c1fb456a943f32542be4f5736845da5014428802 (diff) | |
download | MPC-0c7484507851cbf204a5e2b8fb666f1506e494cb.tar.gz |
ChangeLogTag: Thu Jan 19 12:59:55 2006 Chad Elliott <elliott_c@ociweb.com>
-rw-r--r-- | ChangeLog | 9 | ||||
-rw-r--r-- | USAGE | 4 | ||||
-rw-r--r-- | modules/Driver.pm | 4 | ||||
-rw-r--r-- | modules/Options.pm | 16 |
4 files changed, 31 insertions, 2 deletions
@@ -1,3 +1,12 @@ +Thu Jan 19 12:59:55 2006 Chad Elliott <elliott_c@ociweb.com> + + * USAGE: + * modules/Driver.pm: + * modules/Options.pm: + + Added a new option, -gfeature_file, to specify the global feature + file. + Thu Jan 19 12:30:18 2006 Chad Elliott <elliott_c@ociweb.com> * modules/VC71ProjectCreator.pm: @@ -19,6 +19,7 @@ Usage: mwc.pl [-global <file>] [-include <directory>] [-recurse] [-expand_vars] [-features <feature definitions>] [-exclude <directories>] [-name_modifier <pattern>] [-apply_project] [-version] [-into <directory>] + [-gfeature_file <file name>] [-language <cplusplus | csharp | java | vb>] [-type <automake | bds | bmake | cbx | em3 | ghs | html | make | nmake | sle | vc6 | vc7 | @@ -38,6 +39,9 @@ Usage: mwc.pl [-global <file>] [-include <directory>] [-recurse] config directory. -features Specifies the feature list to set before processing. -genins Generate .ins files for use with prj_install.pl. + -gfeature_file Specifies the global feature file. The + default value is global.features under the + config directory. -global Specifies the global input file. Values stored within this file are applied to all projects. -hierarchy Generate a workspace in a hierarchical fashion. diff --git a/modules/Driver.pm b/modules/Driver.pm index 82efd147..e66ec62d 100644 --- a/modules/Driver.pm +++ b/modules/Driver.pm @@ -192,7 +192,9 @@ sub run { } ## Set the global feature file - my($global_feature_file) = $self->{'path'} . '/config/global.features'; + my($global_feature_file) = (defined $options->{'gfeature_file'} ? + $options->{'gfeature_file'} : + $self->{'path'} . '/config/global.features'); ## Set up default values if (!defined $options->{'input'}->[0]) { diff --git a/modules/Options.pm b/modules/Options.pm index d7c8bd14..d36ceaf4 100644 --- a/modules/Options.pm +++ b/modules/Options.pm @@ -52,6 +52,7 @@ sub printUsage { $spaces . "[-expand_vars] [-features <feature definitions>]\n" . $spaces . "[-exclude <directories>] [-name_modifier <pattern>]\n" . $spaces . "[-apply_project] [-version] [-into <directory>]\n" . + $spaces . "[-gfeature_file <file name>]\n" . $spaces . "[-language <"; my(@keys) = sort keys %languages; @@ -94,6 +95,9 @@ sub printUsage { " config directory.\n" . " -features Specifies the feature list to set before processing.\n" . " -genins Generate .ins files for use with prj_install.pl.\n" . +" -gfeature_file Specifies the global feature file. The\n" . +" default value is global.features under the\n" . +" config directory.\n" . " -global Specifies the global input file. Values stored\n" . " within this file are applied to all projects.\n" . " -hierarchy Generate a workspace in a hierarchical fashion.\n" . @@ -160,7 +164,7 @@ sub completion_command { "ti static noreldefs notoplevel feature_file use_env " . "value_template value_project make_coexistence language " . "hierarchy exclude name_modifier apply_project version " . - "expand_vars)/' " . + "expand_vars gfeature_file)/' " . "'c/dll:/f/' 'c/dll_exe:/f/' 'c/lib_exe:/f/' 'c/lib:/f/' " . "'n/-ti/(dll lib dll_exe lib_exe)/:' "; @@ -204,6 +208,7 @@ sub options { my($global) = undef; my($template) = undef; my($feature_f) = undef; + my($gfeature_f) = undef; my(@features) = (); my($nmodifier) = undef; my($into) = undef; @@ -295,6 +300,14 @@ sub options { $self->optionError('-features requires a comma separated list argument'); } } + elsif ($arg eq '-gfeature_file') { + $i++; + $gfeature_f = $args[$i]; + if (!defined $gfeature_f) { + $self->optionError('-gfeature_file ' . + 'requires a file name argument'); + } + } elsif ($arg eq '-genins') { $genins = 1; } @@ -506,6 +519,7 @@ sub options { my(%options) = ('global' => $global, 'feature_file' => $feature_f, + 'gfeature_file' => $gfeature_f, 'features' => \@features, 'include' => \@include, 'input' => \@input, |