X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmapi%2Fglapi%2Fmeson.build;h=817dd57241dc7358a6dfe8b4fa662be64faf89a7;hb=9fb76392de4b3df558130df22ab483896a7fc257;hp=14ffa68ad0daa06a32ed2f7541008cd274e5cc7d;hpb=d16af7355900703514d95411b222e6e028252d66;p=mesa.git diff --git a/src/mapi/glapi/meson.build b/src/mapi/glapi/meson.build index 14ffa68ad0d..817dd57241d 100644 --- a/src/mapi/glapi/meson.build +++ b/src/mapi/glapi/meson.build @@ -26,7 +26,7 @@ static_glapi_files = [] static_glapi_args = [] if ['apple', 'windows'].contains(with_dri_platform) - static_glapi_files += files('glapi_gentable.c') + static_glapi_files += [glapi_gentable_c, glapitable_h] endif if with_shared_glapi @@ -44,6 +44,7 @@ if with_shared_glapi static_glapi_args += [ '-DMAPI_MODE_BRIDGE', '-DMAPI_ABI_HEADER="@0@"'.format(glapi_mapi_tmp_h.full_path()), + gcc_lto_quirk, ] else static_glapi_args += '-DMAPI_MODE_UTIL' @@ -64,8 +65,9 @@ else static_glapi_files += glapi_x86_s elif with_asm_arch == 'x86_64' static_glapi_files += glapi_x86_64_s + elif with_asm_arch == 'sparc' + static_glapi_files += glapi_sparc_s endif - # TODO: SPARC asm endif libglapi_static = static_library( @@ -77,13 +79,18 @@ libglapi_static = static_library( build_by_default : false, ) -if not with_shared_glapi and with_tests - glapi_static_check_table = executable( +# TODO: this test doesn't compile on windows with mingw or msvc due to +# undefined symbols from libglapi_static, but that should be fixable. +if with_any_opengl and not with_shared_glapi and with_tests and not with_platform_windows + test( 'glapi_static_check_table', - 'tests/check_table.cpp', - link_with : [libglapi_static], - dependencies : [idep_gtest], + executable( + 'glapi_static_check_table', + ['tests/check_table.cpp', glapitable_h], + include_directories : [inc_include, inc_src, inc_mesa, inc_mapi], + link_with : [libglapi_static], + dependencies : [idep_gtest, dep_thread], + ), + suite : ['mapi'], ) - - test('glapi_static_check_table', glapi_static_check_table) endif