1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00
Commit Graph

205 Commits

Author SHA1 Message Date
Uri Simchoni
88d1b44d15 autobuild: Add test for cross-compilation infrastructure
With added option to generate cross-answers by cross-execute script,
a test is added to verify that at least for tested build environments,
the infrastructure is self-consistent.

The test runs samba configuration in three modes:
1. Native
2. Cross compile with cross-execute, using the build machine as its own
   target
3. Cross compile with cross-answers, using the answers generated in
   step 2

The build environments created by the three processes are then tested to
be equal.

Signed-off-by: Uri Simchoni <urisimchoni@gmail.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed May 20 14:10:05 CEST 2015 on sn-devel-104
2015-05-20 14:10:05 +02:00
Uri Simchoni
4a0d599518 waf: add a script that compares configurations
This script is intended for use with the cross-build infrastructure
self-test during autobuild.

The script takes two or more "default.cache.py" files which are the
result of the waf configure process, and performs an intelligent
comparison - allowing for a limited set of variables to be different.

If the configurations are identical (apart from allowed differences) then
the script exit with 0 code.
If there are differences, the script outputs them to standard output
in unified diff format.

Signed-off-by: Uri Simchoni <urisimchoni@gmail.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2015-05-20 11:19:11 +02:00
Uri Simchoni
13ce285b24 waf: add a cross-execute program that runs natively
This added script is for supporting self-testing of the cross-build
infrastructure using autobuild.

The script can be used as the --cross-execute parameter
to samba's configure process, but it actually runs the program
natively on the build machine. This can be done if the build is
actually a native build disguised as a cross-build, i.e. native
toolchain is being used.

Signed-off-by: Uri Simchoni <urisimchoni@gmail.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2015-05-20 11:19:11 +02:00
Andrew Bartlett
15db9f6a2e autobuild: Add options to set mail host and send e-mail with logs
This helps when running the script in a cloud instance as
it is cheapest to shut it down once run

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed Apr 15 08:41:37 CEST 2015 on sn-devel-104
2015-04-15 08:41:37 +02:00
Andrew Bartlett
bc5a4f5227 autobuild: Do not consider IDL.pm and Expr.pm changes to make a build bad
This allows a different yapp to be installed on the build host without failing
the whole autobuild

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
2015-04-15 05:58:19 +02:00
Andrew Bartlett
1b0bfdf64f Improve output of check-clean-tree.sh script
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
2015-04-15 05:58:19 +02:00
Andrew Bartlett
d65675b2df autobuild: Do not wait when running just one target
This avoids having to remember to specify AUTOBUILD_RANDOM_SLEEP_OVERRIDE manually

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
2015-04-15 05:58:19 +02:00
Jelmer Vernooij
d16c0e369e Pass --recursive to 'git clone' in autobuild.
This makes it possible to use submodules in Samba.

Change-Id: Iccb1876b1daf82864b18486f2dca9036d7d3c75c
Signed-Off-By: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
2015-03-30 11:04:15 +02:00
Volker Lendecke
334015ebca autobuild: Remove ntdb target
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2015-03-17 11:30:51 +01:00
Volker Lendecke
89052936ae Remove ntdb from scripts
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2015-03-17 11:30:51 +01:00
Stefan Metzmacher
87b7a7dbaa script/autobuild.py: build the samba target with --with-profiling-data
In future we may get also runtime tests for profiling...

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>

Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Mon Dec 15 16:20:14 CET 2014 on sn-devel-104

(cherry picked from commit 4958fcdfa3)
2015-03-06 15:02:29 +01:00
Jelmer Vernooij
f980efeef1 show_test_time: Use system subunit.
Change-Id: I7d799b5f9d6066d988aa2e101e0fe7b6efe74aea
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2015-03-06 04:41:47 +01:00
Michael Adam
57a03c6947 autobuild: adapt a comment
The configure-option --with-cluster-support now only builds
against the included ctdb, and it also builds the ctdb component.
The comment in autobuild.py this patch changes was still from the olden days...

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Wed Dec 17 21:13:44 CET 2014 on sn-devel-104
2014-12-17 21:13:44 +01:00
Stefan Metzmacher
770f222f33 script/autobuild.py: use --picky-developer for the samba-ctdb target
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>

Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Wed Dec 17 11:52:25 CET 2014 on sn-devel-104
2014-12-17 11:52:25 +01:00
Stefan Metzmacher
af570c294b Revert "script/autobuild.py: build the samba target with --with-profiling-data"
This reverts commit 4958fcdfa3.

This only works for a single user on a system, as only one can create
the sysv shared memory segment.

In future we'll use a tdb instead of sysv shared memory,
then we can readd this.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Dec 16 11:25:47 CET 2014 on sn-devel-104
2014-12-16 11:25:47 +01:00
Stefan Metzmacher
4958fcdfa3 script/autobuild.py: build the samba target with --with-profiling-data
In future we may get also runtime tests for profiling...

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>

Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Mon Dec 15 16:20:14 CET 2014 on sn-devel-104
2014-12-15 16:20:14 +01:00
Stefan Metzmacher
e079ffd1da script/autobuild.py: build 'samba' using --picky-developer
This makes sure we don't get unexpected new compiler warnings.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Nov 25 09:46:30 CET 2014 on sn-devel-104
2014-11-25 09:46:30 +01:00
Jelmer Vernooij
b7efc12406 Print number of slow tests from script rather than wscript.
Change-Id: I6eaa0803b95cc81f514a2176f4e06f1e3fff4077
Signed-Off-By: Jelmer Vernooij <jelmer@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date(master): Mon Nov 24 13:06:46 CET 2014 on sn-devel-104
2014-11-24 13:06:46 +01:00
Jelmer Vernooij
34c6d47194 Rewrite show_test_time in python and support --limit argument.
Change-Id: I6c3f28ed52cc8597251aa195ec3c7e38587c2573
Signed-Off-By: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2014-11-19 02:46:04 +01:00
Michael Adam
062289f0f8 script: fix display of ten slowest tests if < 10 tests are run.
Note: $#array is the biggest index in an array in perl.
@array evaluated in scalar context is the number of elements.
Hence scalar(@array) = 1 + $#array

Or equivalently: 0 + @array = 1 + $#array

... :-)

Apart from this off-by-one error, the "unless" clause to trigger
the capping of the number of tests listed was wrong. Hence if
less then 10 tests were run, a number of blank lines were appended.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2014-10-30 20:25:04 +01:00
Michael Adam
6168ae0b87 script/show_testsuite_time: error out if number argument is not a decimal number
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2014-10-30 20:25:04 +01:00
Michael Adam
bf07a6b79e autobuild: check whether ctdbd has been installed in the samba-ctdb target
An intermediate test until we have full runtime-tests.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>

Autobuild-User(master): Amitay Isaacs <amitay@samba.org>
Autobuild-Date(master): Tue Oct 28 08:05:40 CET 2014 on sn-devel-104
2014-10-28 08:05:40 +01:00
Michael Adam
eeebbe7312 autobuild: adapt samba-ctdb target does not need a separate ctdb build any more
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
2014-10-28 05:42:05 +01:00
Matthieu Patou
4055eb6b7d scripts: Allow to specify a limit on the number of tests reported
This allows to report the 10 most slowest for instance.

Change-Id: I987520dbc28f598221c47df314d823f916312aab
Signed-off-by: Matthieu Patou <mat@matws.net>
Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-10-17 17:57:04 +02:00
Stefan Metzmacher
8c3e0f84cc script/autobuild.py: remove explicit --with-perl-*-install-dir options
BUG: https://bugzilla.samba.org/show_bug.cgi?id=10472

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Fri Sep  5 22:09:47 CEST 2014 on sn-devel-104
2014-09-05 22:09:47 +02:00
Michael Adam
cef718c39f autobuild: fix ctdb build of samba-ctdb target after switch to waf.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Sat Jun 21 02:05:38 CEST 2014 on sn-devel-104
2014-06-21 02:05:38 +02:00
Amitay Isaacs
46924f68c1 autobuild: Remove unsupported --enable-socket-wrapper option from the "ctdb" target.
Socket wrapper now works with LD_PRELOAD.

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-06-20 23:38:10 +02:00
Amitay Isaacs
659a665de8 autobuild: Don't need autogen.sh anymore in the "ctdb" target.
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-06-20 23:38:10 +02:00
Michael Adam
a4c50e2332 autobuild: fix samba-ctdb samba build to pick up right tdb
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>

Autobuild-User(master): Michael Adam <obnox@samba.org>
Autobuild-Date(master): Tue Jun 17 11:58:00 CEST 2014 on sn-devel-104
2014-06-17 11:58:00 +02:00
Michael Adam
30f3a86619 autobuild: add cflags and ldflags to find locally installed tdb
So that we can find our self-installed tdb lib and use new features.

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
2014-06-17 09:33:10 +02:00
Stefan Metzmacher
d18ee9e4b6 script/autobuild: make use of --with-perl-{arch,lib}-install-dir
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10472

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-05-09 23:10:07 +02:00
Stefan Metzmacher
ab9f021931 script/autobuild: use --force-rebase option
This makes sure the current user will be the committer.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2014-03-13 21:45:12 +01:00
Andreas Schneider
1d954103f5 autobuild: Set perl vendorlib direcotry.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2014-03-06 09:59:44 +01:00
Andrew Bartlett
6f092cfd87 autobuild: Run "make dist" to ensure non-waf docs build is run
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Tue Mar  4 05:00:27 CET 2014 on sn-devel-104
2014-03-04 05:00:27 +01:00
Garming Sam
a7d2f9a08e param: change s3_param.h from a generated file to a static one
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Change-Id: I131e37ec92f7a826caec382023915c5e4b4c52be
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
2014-02-20 10:11:20 +13:00
Garming Sam
0941789063 param: remove generated loadparm ctx table file and include it directly
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Change-Id: I5f1d42e3ae6495accf7a711938cc28c03ab2cd62
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
2014-02-20 10:11:17 +13:00
Garming Sam
9780113846 param: use loadparm_globals struct instead of lp function pointers in s3_helpers
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Change-Id: I4507cdbf111b7f9dca3ca18ee2bf242ffdfeb4e7
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
2014-02-20 10:11:13 +13:00
Garming Sam
1fb1f6bc0d lib/param: handle non-constant strings properly by passing in a memory context
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Change-Id: Ic6bb1c709defd2b0f35fc7b877da0badca385776
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
2014-02-20 10:11:06 +13:00
Garming Sam
2bf17a9d75 param: use generate_param.py to generate loadparm_ctx_table.c
Pair-programmed-with: Andrew Bartlett <abartlet@samba.org>
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-02-12 13:17:14 +13:00
Garming Sam
5cab9f16d0 param: use generate_param.py to generate s3_param.h
Pair-programmed-with: Andrew Bartlett <abartlet@samba.org>
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-02-12 13:17:14 +13:00
Garming Sam
b1de1abf7b param: use generate_param.py to generate param_global.h
Pair-programmed-with: Andrew Bartlett <abartlet@samba.org>
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-02-12 13:17:13 +13:00
Garming Sam
526cf3c119 param: use generate_param.py to generate param_proto.h
Pair-programmed-with: Andrew Bartlett <abartlet@samba.org>
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-02-12 13:17:13 +13:00
Garming Sam
66c2fbf2a1 lib/param: update generate_param.py to generate more of loadparm
These files can now be generated directly from the xml rather than from param_functions.c

Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-02-12 13:17:13 +13:00
Garming Sam
aea623e050 param: auto generate param_functions.c at build time
generate_param.py reads the documentation to define which functions need to
be generated.

To add new parameters, edit the xml files in docs-xml/smbdotconf.

Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-02-12 13:17:13 +13:00
Amitay Isaacs
e9f4b69bae autobuild: Run ctdb regression tests
Pair-Programmed-with: Michael Adam <obnox@samba.org>

Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
2013-11-28 07:31:13 +01:00
Michael Adam
85a25abed0 autobuild: build the "ctdb" target with socket-wrapper enabled
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
2013-11-28 07:31:13 +01:00
Stefan Metzmacher
7e01e4bc64 script: prepare librelease.sh for ntdb releases
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Sun Nov 17 12:50:13 CET 2013 on sn-devel-104
2013-11-17 12:50:13 +01:00
Michael Adam
06be5962ab random-sleep: add possiblity to override via environment variable
set AUTOBUILD_RANDOM_SLEEP_OVERRIDE=<x>

to the number x of seconds that you want to sleep.
This is added to make it possible to run one autobuild
target without having to wait for several minutes.

Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2013-11-13 14:53:45 +01:00
Michael Adam
c4214a7942 autobuild: extend samba-ctdb target to build ctdb, too
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-11-13 14:42:35 +01:00
Michael Adam
1da294a7eb autobuild: add a "ctdb" target
For a start, this just builds and installs the integrated ctdb copy.
It does not run "make test" in ctdb. This is time consuming and
too flakey for now.

Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2013-11-13 14:37:57 +01:00