diff options
| author | Radu Patriu <radu.patriu@enea.com> | 2014-03-31 11:49:58 +0300 |
|---|---|---|
| committer | Bruce Ashfield <bruce.ashfield@windriver.com> | 2014-04-01 20:51:45 -0400 |
| commit | 36b5a4ca38064cfd5e19554f4b9a2b138a055478 (patch) | |
| tree | e2d0dddc258bb08e84670b1263b43871458c0f00 /recipes-networking/openvswitch/files/openvswitch-add-ptest.patch | |
| parent | 594a85674c5fd98ca9b34c3d94cca5c84c95cccb (diff) | |
| download | meta-virtualization-36b5a4ca38064cfd5e19554f4b9a2b138a055478.tar.gz | |
openvswitch: add ptest support
Install openvswitch test suite and run it as ptest.
Signed-off-by: Radu Patriu <radu.patriu@enea.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Diffstat (limited to 'recipes-networking/openvswitch/files/openvswitch-add-ptest.patch')
| -rw-r--r-- | recipes-networking/openvswitch/files/openvswitch-add-ptest.patch | 67 |
1 files changed, 67 insertions, 0 deletions
diff --git a/recipes-networking/openvswitch/files/openvswitch-add-ptest.patch b/recipes-networking/openvswitch/files/openvswitch-add-ptest.patch new file mode 100644 index 00000000..aebb1823 --- /dev/null +++ b/recipes-networking/openvswitch/files/openvswitch-add-ptest.patch | |||
| @@ -0,0 +1,67 @@ | |||
| 1 | Add test-install rule to support ptest execution | ||
| 2 | |||
| 3 | Signed-off-by: Radu Patriu <radu.patriu@enea.com> | ||
| 4 | |||
| 5 | Index: ovs/Makefile.am | ||
| 6 | =================================================================== | ||
| 7 | --- ovs.orig/Makefile.am 2014-03-10 16:19:46.000000000 +0200 | ||
| 8 | +++ ovs/Makefile.am 2014-03-10 16:23:10.481075341 +0200 | ||
| 9 | @@ -276,3 +276,4 @@ | ||
| 10 | include python/automake.mk | ||
| 11 | include python/compat/automake.mk | ||
| 12 | include tutorial/automake.mk | ||
| 13 | +include test.mk | ||
| 14 | Index: ovs/test.mk | ||
| 15 | =================================================================== | ||
| 16 | --- /dev/null 1970-01-01 00:00:00.000000000 +0000 | ||
| 17 | +++ ovs/test.mk 2014-03-10 16:42:41.000000000 +0200 | ||
| 18 | @@ -0,0 +1,49 @@ | ||
| 19 | +TEST_DEST ?= ${prefix}/lib/openvswitch | ||
| 20 | +TEST_ROOT ?= ${prefix}/lib/openvswitch | ||
| 21 | +TEST_DEPEND = | ||
| 22 | + | ||
| 23 | +if HAVE_OPENSSL | ||
| 24 | +TEST_DEPEND += $(TESTPKI_FILES) | ||
| 25 | +endif | ||
| 26 | + | ||
| 27 | +test-install: $(TEST_DEPEND) | ||
| 28 | + @list='$(noinst_PROGRAMS) $(EXTRA_DIST) $(dist_check_SCRIPTS) $(TEST_DEPEND) tests/atlocal tests/atconfig' ;\ | ||
| 29 | + install -d $(TEST_DEST)/tests ;\ | ||
| 30 | + install -d $(TEST_DEST)/python ;\ | ||
| 31 | + install -d $(TEST_DEST)/python/ovs ;\ | ||
| 32 | + install -d $(TEST_DEST)/python/ovs/db ;\ | ||
| 33 | + install -d $(TEST_DEST)/python/ovs/unixctl ;\ | ||
| 34 | + install -d $(TEST_DEST)/vswitchd ;\ | ||
| 35 | + install vswitchd/vswitch.ovsschema $(TEST_DEST)/vswitchd ;\ | ||
| 36 | + install -d $(TEST_DEST)/debian ;\ | ||
| 37 | + install debian/ovs-monitor-ipsec $(TEST_DEST)/debian ;\ | ||
| 38 | + install -d $(TEST_DEST)/build-aux ;\ | ||
| 39 | + install build-aux/check-structs $(TEST_DEST)/build-aux ;\ | ||
| 40 | + install -d $(TEST_DEST)/xenserver ;\ | ||
| 41 | + install xenserver/usr_share_openvswitch_scripts_ovs-xapi-sync $(TEST_DEST)/xenserver ;\ | ||
| 42 | + install xenserver/opt_xensource_libexec_interface-reconfigure $(TEST_DEST)/xenserver ;\ | ||
| 43 | + install xenserver/opt_xensource_libexec_InterfaceReconfigure.py $(TEST_DEST)/xenserver ;\ | ||
| 44 | + install xenserver/opt_xensource_libexec_InterfaceReconfigureBridge.py $(TEST_DEST)/xenserver ;\ | ||
| 45 | + install xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py $(TEST_DEST)/xenserver ;\ | ||
| 46 | + install -d $(TEST_DEST)/vtep ;\ | ||
| 47 | + install vtep/vtep.ovsschema $(TEST_DEST)/vtep ;\ | ||
| 48 | + for p in $$list ; do \ | ||
| 49 | + echo $$p ;\ | ||
| 50 | + p=$${p#./} ;\ | ||
| 51 | + pre=$${p#tests\/} ;\ | ||
| 52 | + if test $$pre != $$p ; then \ | ||
| 53 | + echo installing $$p to $(TEST_DEST)/tests/$$pre ;\ | ||
| 54 | + install $$p $(TEST_DEST)/tests/$$pre ;\ | ||
| 55 | + continue ;\ | ||
| 56 | + fi ;\ | ||
| 57 | + pre=$${p#python\/ovs\/} ;\ | ||
| 58 | + if test $$pre != $$p ; then \ | ||
| 59 | + echo installing $$p to $(TEST_DEST)/python/ovs/$$pre ;\ | ||
| 60 | + install $$p $(TEST_DEST)/python/ovs/$$pre ;\ | ||
| 61 | + continue ;\ | ||
| 62 | + fi; \ | ||
| 63 | + done ;\ | ||
| 64 | + sed -i 's|abs_builddir=.*|abs_builddir='"'"'$(TEST_ROOT)/tests'"'"'|g' $(TEST_DEST)/tests/atconfig | ||
| 65 | + sed -i 's|abs_srcdir=.*|abs_srcdir='"'"'$(TEST_ROOT)/tests'"'"'|g' $(TEST_DEST)/tests/atconfig | ||
| 66 | + sed -i 's|abs_top_srcdir=.*|abs_top_srcdir='"'"'$(TEST_ROOT)'"'"'|g' $(TEST_DEST)/tests/atconfig | ||
| 67 | + sed -i 's|abs_top_builddir=.*|abs_top_builddir='"'"'$(TEST_ROOT)'"'"'|g' $(TEST_DEST)/tests/atconfig | ||
