diff options
author | Stefan Metzmacher <metze@samba.org> | 2009-01-21 10:14:29 +0100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2009-01-21 13:35:36 +0100 |
commit | 6f6533aa81791d40b37a9e715c7b7669cc92a1c9 (patch) | |
tree | 0e023de77b0158794f17dcde2b1152cd1fe69c0c | |
parent | ccffe1ca71392f8d4f62b8ca64f9eafe42505808 (diff) | |
download | samba-6f6533aa81791d40b37a9e715c7b7669cc92a1c9.tar.gz samba-6f6533aa81791d40b37a9e715c7b7669cc92a1c9.tar.bz2 samba-6f6533aa81791d40b37a9e715c7b7669cc92a1c9.zip |
selftest: add --exeext parameter
metze
-rwxr-xr-x | selftest/selftest.pl | 9 | ||||
-rw-r--r-- | selftest/target/Samba4.pm | 10 |
2 files changed, 14 insertions, 5 deletions
diff --git a/selftest/selftest.pl b/selftest/selftest.pl index fd0b85c9b0..6f0883c585 100755 --- a/selftest/selftest.pl +++ b/selftest/selftest.pl @@ -13,7 +13,7 @@ selftest - Samba test runner selftest --help -selftest [--srcdir=DIR] [--builddir=DIR] [--target=samba4|samba3|win|kvm] [--socket-wrapper] [--quick] [--exclude=FILE] [--include=FILE] [--one] [--prefix=prefix] [--immediate] [--testlist=FILE] [TESTS] +selftest [--srcdir=DIR] [--builddir=DIR] [--exeext=EXT][--target=samba4|samba3|win|kvm] [--socket-wrapper] [--quick] [--exclude=FILE] [--include=FILE] [--one] [--prefix=prefix] [--immediate] [--testlist=FILE] [TESTS] =head1 DESCRIPTION @@ -35,6 +35,10 @@ Source directory. Build directory. +=item I<--exeext=EXT> + +Executable extention + =item I<--prefix=DIR> Change directory to run tests in. Default is 'st'. @@ -156,6 +160,7 @@ my @testlists = (); my $srcdir = "."; my $builddir = "."; +my $exeext = ""; my $prefix = "./st"; my @expected_failures = (); @@ -294,6 +299,7 @@ Paths: --prefix=DIR prefix to run tests in [st] --srcdir=DIR source directory [.] --builddir=DIR output directory [.] + --exeext=EXT executable extention [] Target Specific: --socket-wrapper-pcap save traffic to pcap directories @@ -334,6 +340,7 @@ my $result = GetOptions ( 'include=s' => \@opt_include, 'srcdir=s' => \$srcdir, 'builddir=s' => \$builddir, + 'exeext=s' => \$exeext, 'verbose' => \$opt_verbose, 'testenv' => \$opt_testenv, 'ldap:s' => \$ldap, diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index bb4f39dd0c..83f62d45ec 100644 --- a/selftest/target/Samba4.pm +++ b/selftest/target/Samba4.pm @@ -10,13 +10,15 @@ use Cwd qw(abs_path); use FindBin qw($RealBin); use POSIX; -sub new($$$$) { - my ($classname, $bindir, $ldap, $setupdir) = @_; +sub new($$$$$) { + my ($classname, $bindir, $ldap, $setupdir, $exeext) = @_; + $exeext = "" unless defined($exeext); my $self = { vars => {}, ldap => $ldap, bindir => $bindir, - setupdir => $setupdir + setupdir => $setupdir, + exeext => $exeext }; bless $self; return $self; @@ -25,7 +27,7 @@ sub new($$$$) { sub bindir_path($$) { my ($self, $path) = @_; - return "$self->{bindir}/$path"; + return "$self->{bindir}/$path$self->{exeext}"; } sub openldap_start($$$) { |