| author | sl |
| Tue, 10 Jun 2014 14:32:02 +0200 | |
| changeset 1 | 260cb5ec6c19 |
| permissions | -rw-r--r-- |
| sl@0 | 1 |
# |
| sl@0 | 2 |
# Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). |
| sl@0 | 3 |
# All rights reserved. |
| sl@0 | 4 |
# This component and the accompanying materials are made available |
| sl@0 | 5 |
# under the terms of "Eclipse Public License v1.0" |
| sl@0 | 6 |
# which accompanies this distribution, and is available |
| sl@0 | 7 |
# at the URL "http://www.eclipse.org/legal/epl-v10.html". |
| sl@0 | 8 |
# |
| sl@0 | 9 |
# Initial Contributors: |
| sl@0 | 10 |
# Nokia Corporation - initial contribution. |
| sl@0 | 11 |
# |
| sl@0 | 12 |
# Contributors: |
| sl@0 | 13 |
# |
| sl@0 | 14 |
# Description: |
| sl@0 | 15 |
# |
| sl@0 | 16 |
# |
| sl@0 | 17 |
|
| sl@0 | 18 |
use Getopt::Long; |
| sl@0 | 19 |
use Cwd; |
| sl@0 | 20 |
|
| sl@0 | 21 |
|
| sl@0 | 22 |
sub Usage() |
| sl@0 | 23 |
{
|
| sl@0 | 24 |
print <<USAGE_EOF; |
| sl@0 | 25 |
Usage |
| sl@0 | 26 |
perl testdriversetup.pl --statlite=StatLite |
| sl@0 | 27 |
|
| sl@0 | 28 |
StatLite = [true | false ] |
| sl@0 | 29 |
|
| sl@0 | 30 |
--help : This help |
| sl@0 | 31 |
USAGE_EOF |
| sl@0 | 32 |
exit( 0 ) |
| sl@0 | 33 |
} |
| sl@0 | 34 |
|
| sl@0 | 35 |
sub main() |
| sl@0 | 36 |
{
|
| sl@0 | 37 |
my $help=''; |
| sl@0 | 38 |
my $statLite=""; |
| sl@0 | 39 |
|
| sl@0 | 40 |
GetOptions( |
| sl@0 | 41 |
'statlite=s'=> \$statLite, |
| sl@0 | 42 |
'help' => \$help |
| sl@0 | 43 |
); |
| sl@0 | 44 |
|
| sl@0 | 45 |
if($help or (($statLite ne "true") and ($statLite ne "false")) ) |
| sl@0 | 46 |
{
|
| sl@0 | 47 |
Usage(); |
| sl@0 | 48 |
exit(0); |
| sl@0 | 49 |
} |
| sl@0 | 50 |
|
| sl@0 | 51 |
my $theEpocRoot=$ENV{EPOCROOT};
|
| sl@0 | 52 |
my $epoc32Location="$theEpocRoot.\\epoc32"; |
| sl@0 | 53 |
|
| sl@0 | 54 |
my $currentDirectory=cwd; |
| sl@0 | 55 |
$currentDirectory =~ s/Group//i; |
| sl@0 | 56 |
$currentDirectory =~ s/\//\\/g; |
| sl@0 | 57 |
|
| sl@0 | 58 |
my $currentDrive = substr($currentDirectory,0,2); |
| sl@0 | 59 |
|
| sl@0 | 60 |
my $cmd="TestDriver config"; |
| sl@0 | 61 |
my $suite="file:/$currentDrive$epoc32Location\\testdriver\\salt\\devsoundexthai.driver"; |
| sl@0 | 62 |
$suite =~ s.\\./.g; |
| sl@0 | 63 |
$suite =~ s\/./\/\g; |
| sl@0 | 64 |
|
| sl@0 | 65 |
$cmd .= " --bldclean OFF"; |
| sl@0 | 66 |
$cmd .= " --bldmake OFF"; |
| sl@0 | 67 |
$cmd .= " -e $currentDrive$theEpocRoot"; |
| sl@0 | 68 |
$cmd .= " -x $currentDrive$epoc32Location\\testdriver\\salt"; |
| sl@0 | 69 |
$cmd .= " --repos $currentDrive$epoc32Location\\testdriver\\Repository"; |
| sl@0 | 70 |
$cmd .= " -c $currentDrive$epoc32Location\\testdriver\\Results"; |
| sl@0 | 71 |
$cmd .= " -i $currentDirectory"; |
| sl@0 | 72 |
$cmd .= " -s $suite"; |
| sl@0 | 73 |
$cmd .= " --source $currentDirectory"; |
| sl@0 | 74 |
$cmd .= " --tp $currentDirectory"; |
| sl@0 | 75 |
$cmd .= " --testexec ON"; |
| sl@0 | 76 |
$cmd .= " --statlite $statLite"; |
| sl@0 | 77 |
$cmd .= " --teflite true"; |
| sl@0 | 78 |
$cmd .= " --commdb overwrite"; |
| sl@0 | 79 |
system("$cmd");
|
| sl@0 | 80 |
} |
| sl@0 | 81 |
|
| sl@0 | 82 |
main(); |