On 23/06/2019 20:32, Gert Doering wrote: > We used to ship git submodule instructions to build a local copy of > cmocka in vendor/cmocka/ and use that (if cmake is installed) to build > unit tests. With the network test driver this turns out to be a > LD_LIBRARY_PATH vs. SUDO complication which is really outweighing the > benefit of a local build today - so, use the system-wide installation > if available (querying pgk-config). Do not build unit-tests otherwise. > > v2: (inspired by patch from David Sommerseth) > introduce "configure --disable-unit-test" switch > simplify configure.ac logic > use CMOCKA_LIBS and CMOCKA_INCLUDE (set by PKG_CHECK) > > v3: > repair conflict with commit 7473f326366fbceb > CMOCKA_INCLUDE is not correct, must be CMOCKA_CFLAGS (see config.status) > > Signed-off-by: Gert Doering <g...@greenie.muc.de> > --- > .gitmodules | 4 ---- > INSTALL | 14 +++++++++++++ > Makefile.am | 2 +- > configure.ac | 40 +++++++++++++++++------------------- > tests/unit_tests/Makefile.am | 2 +- > vendor/Makefile.am | 22 -------------------- > vendor/README.md | 8 -------- > vendor/cmocka | 1 - > 8 files changed, 35 insertions(+), 58 deletions(-) > delete mode 100644 .gitmodules > delete mode 100644 vendor/Makefile.am > delete mode 100644 vendor/README.md > delete mode 160000 vendor/cmocka
Acked-By: David Sommerseth <dav...@openvpn.net> Changes looks good too now. I've tested this with a few configs, passes 'make distcheck' with and without cmocka available. A big plus with this change is also that these cmocka unit tests are also run via 'make check' if it is available on the system. I have not verified "how to install cmocka from source" in INSTALL. -- kind regards, David Sommerseth OpenVPN Inc
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel