> I'm not sure to understand. > Do you want to **build** test in parallel or **run** test in parallel?
I want to build a test in parallel. > How are you calling ctest? ctest -V -R '^DDOTUT_x11$' I'm only running one test executable at a time. > cmake cmake -DCMAKE_TOOLCHAIN_FILE=../../Build/buildconfigs/any-linux-gcc-x86_64.cmake ../../Build The build system we have contains 30 odd external libraries and about 40 of our own. > make make -j8 This builds everything but the tests. We've been leaving the build of the tests to ctest upto now. However ctest now appears to be building more than just the tests. Its not rebuilding everything just some of the libraries. make on its own seems to respect the dependencies and only rebuild what is required unless I've run ctest. On 27 June 2017 at 13:03, Eric Noulard <eric.noul...@gmail.com> wrote: > > > 2017-06-27 13:32 GMT+02:00 Damian Dixon <damian.di...@gmail.com>: > >> Hi, >> >> Is there anyway to build tests in parallel when using ctest? >> > > I'm not sure to understand. > Do you want to **build** test in parallel or **run** test in parallel? > > >> >> I am generating makefiles on Linux. >> > > Then > > $ make -j 8 > > should build in parallel. > > >> >> Part of the reason I am asking this is that if I pre-build the test for >> some unknown reason ctest rebuilds the source files. >> > > Then you have to verify your test dependencies. ctest should only run the > tests not build then unless you call ctest > with --build-xxx option. > > How are you calling ctest? > > ctest --parallel 8 > or > ctest -j 8 > > should run tests in parallel. > > This works for me (either parallel build or parallel test run) but I'm > using ninja. > > > Could you give us more detail on how you run cmake, make and ctest ? > > > -- > Eric >
-- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake