diff options
author | Michael Goddard <michael.goddard@nokia.com> | 2011-06-30 14:51:16 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-07-22 14:59:08 +0200 |
commit | 997b2a96c1aec1c7f35cd2228eba907f29a28f25 (patch) | |
tree | 2c0d82d1420c9cf5018d43c9e9e5008832c8be76 /bin/syncqt | |
parent | 7fc3203062f27f582de84420fa0b519c58b5d1ff (diff) |
Add rudimentary config.test support when configuring modules.
An extra script is added (qtmodule-configtests) which is currently
invoked from syncqt (with some derived parameters passed to it).
The module can optionally have an entry in the module's sync.profile
file in the form of a perl map of "test name" => parameters. Tests
can print an advisory message if they fail (e.g. "Install this
SDK/dev package"), or abort the syncqt process (e.g. mandatory
prereq missing). Also, if the test has a "requires(foo)" line
that results in it being skipped, this is also supported.
Change-Id: Ic3c820a488a0992c944994d4d7dc283da36742d6
Reviewed-on: http://codereview.qt.nokia.com/928
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Sarah Jane Smith <sarah.j.smith@nokia.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
Diffstat (limited to 'bin/syncqt')
-rwxr-xr-x | bin/syncqt | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/bin/syncqt b/bin/syncqt index 691f09139c..0c22cf8a6f 100755 --- a/bin/syncqt +++ b/bin/syncqt @@ -15,6 +15,7 @@ use Cwd; use Cwd 'abs_path'; use Config; use strict; +use English qw(-no_match_vars ); # set output basedir to be where ever syncqt is run from our $out_basedir = getcwd(); @@ -50,6 +51,7 @@ my $module_fwd = ""; my $cache_module_fwd = 0; my $developer_build = 0; my $no_module_version_header = 0; +my $makefile_generator = ""; my @modules_to_sync ; $force_relative = 1 if ( -d "/System/Library/Frameworks" ); @@ -90,6 +92,7 @@ sub showUsage print " easy development\n"; print " -no-module-version-header\n"; print " Don't create module version header file\n"; + print " -generator <PATH> Specify the makefile generator setting (e.g. 'UNIX')\n"; print " -help This help\n"; exit 0; } @@ -658,6 +661,9 @@ while ( @ARGV ) { # skip, it's been dealt with at the top of the file shift @ARGV; next; + } elsif($arg eq "-generator") { + $var = "makefile_generator"; + $val = shift @ARGV; } elsif($arg =~/^-/) { print "Unknown option: $arg\n\n" if(!$var); showUsage(); @@ -741,6 +747,8 @@ while ( @ARGV ) { $cache_module_fwd = 1; } elsif ($var eq "developer_build") { $developer_build = 1; + } elsif ($var eq "makefile_generator") { + $makefile_generator = $val; } elsif ($var eq "no_module_version_header") { $no_module_version_header = 1; } elsif ($var eq "output") { @@ -1310,4 +1318,13 @@ if($check_includes) { } } +# Do configure tests now (pass some things along) +# fatal tests have a non zero return +unless ($showonly) { + my $configtests = dirname($0)."/qtmodule-configtests"; + if (system($EXECUTABLE_NAME, $configtests, $basedir, $out_basedir, $qtbasedir, $makefile_generator)) { + die "$configtests exited with status $?"; + } +} + exit 0; |