[waffle] [PATCH (master) 1/2] tests: Move all test executables to $CMAKE_BINARY_DIR/tests

Emil Velikov emil.l.velikov at gmail.com
Wed Aug 13 15:30:35 PDT 2014


On 13/08/14 22:53, Chad Versace wrote:
> This makes it easier to find and run test executables by hand.
> 
I'm up for the idea but I fear that this and patch 2/2 will clash badly with
an earlier patch of mine.

 [PATCH 8/8] cmake: misc fixes and cleanups

I know the commit msg sucks, but I'd rather not split this into 4 one line
patches :)

Any objections if I rebase these patches on top of the series
 [PATCH 0/8] make check cleanup & windows support

I've spent more that I would dare acknowledge fighting with cmake+Windows'
"DLL is not a library but a runtime object" :\

-Emil

> Cc: Emil Velikov <emil.l.velikov at gmail.com>
> Signed-off-by: Chad Versace <chad.versace at linux.intel.com>
> ---
>  .gitignore                      | 2 +-
>  tests/functional/CMakeLists.txt | 7 +++++--
>  2 files changed, 6 insertions(+), 3 deletions(-)
> 
> diff --git a/.gitignore b/.gitignore
> index f4a0e43..eabf007 100644
> --- a/.gitignore
> +++ b/.gitignore
> @@ -55,7 +55,7 @@ Makefile
>  /examples/simple-x11-egl
>  /lib/
>  /src/waffle/libwaffle_static.a
> -/tests/functional/gl_basic_test
> +/tests/gl_basic_test
>  /tests/waffle_test/libwaffle_test.dylib
>  /tests/unittests/waffle-unittest
>  /tests/wcore_attrib_list_unittest
> diff --git a/tests/functional/CMakeLists.txt b/tests/functional/CMakeLists.txt
> index 7a83e39..d78328c 100644
> --- a/tests/functional/CMakeLists.txt
> +++ b/tests/functional/CMakeLists.txt
> @@ -31,10 +31,13 @@ set_source_files_properties(
>  add_executable(gl_basic_test
>      ${gl_basic_test_sources}
>      )
> -
> +set_target_properties(gl_basic_test
> +    PROPERTIES
> +        RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/tests
> +    )
>  add_custom_target(gl_basic_test_run
>      DEPENDS gl_basic_test
> -    COMMAND ${CMAKE_BINARY_DIR}/tests/functional/gl_basic_test
> +    COMMAND ${CMAKE_BINARY_DIR}/tests/gl_basic_test
>      )
>  
>  add_dependencies(check-func gl_basic_test_run)
> 



More information about the waffle mailing list