1 set(gl_basic_test_sources
6 list(APPEND gl_basic_test_sources
12 set_source_files_properties(
13 ${gl_basic_test_sources}
15 COMPILE_FLAGS "-Wno-initializer-overrides"
19 # CMake will pass to the C compiler only C sources. CMake does not recognize the
20 # .m extension and ignores any such files in the source lists. To coerce CMake
21 # to pass .m files to the compiler, we must lie and claim that they are
23 set_source_files_properties(
24 ${gl_basic_test_sources}
28 add_executable(gl_basic_test
29 ${gl_basic_test_sources}
32 target_link_libraries(gl_basic_test
38 # ----------------------------------------------------------------------------
39 # Per platform functionality tests
40 # ----------------------------------------------------------------------------
42 function(add_functest platform_name)
43 add_custom_target(gl_basic_test_${platform_name}_run
44 COMMAND gl_basic_test --platform ${platform_name}
46 add_dependencies(check-func gl_basic_test_${platform_name}_run)
48 if(VALGRIND_EXECUTABLE)
49 add_custom_target(valgrind_gl_basic_test_${platform_name}_run
51 COMMAND ${VALGRIND_EXECUTABLE} $<TARGET_FILE:gl_basic_test> --platform ${platform_name}
54 add_dependencies(valgrind-check-func valgrind_gl_basic_test_${platform_name}_run)
67 if(waffle_has_wayland)
71 if(waffle_has_x11_egl)
79 if(waffle_has_surfaceless)
80 add_functest(surfaceless_egl)