
On Thu, Feb 11, 2016 at 02:36:28PM +0100, Andrea Bolognani wrote:
Instead of compiling either the mock or the non-mock part of the file based on a compiler flag, split the mock part off to its own file. --- tests/Makefile.am | 4 +- tests/virportallocatormock.c | 108 ++++++++++++++++++++++++++++++++++++++++++ tests/virportallocatortest.c | 110 +++---------------------------------------- 3 files changed, 117 insertions(+), 105 deletions(-) create mode 100644 tests/virportallocatormock.c
@@ -255,12 +168,3 @@ mymain(void) }
VIRT_TEST_MAIN_PRELOAD(mymain, abs_builddir "/.libs/libvirportallocatormock.so") -# endif - -#else /* ! defined(RTLD_NEXT) */ -int -main(void) -{ - return EXIT_AM_SKIP; -} -#endif
I'm afraid removing this will break the test on non-Linux. ACK if you leave the EXIT_AM_SKIP in. Jan