kopper: print better error message if loader not detected
silently failing on release builds is annoying Reviewed-by: Yonggang Luo <luoyonggang@gmail.com> Reviewed-by: Daniel Stone <daniels@collabora.com> Reviewed-by: Michel Dänzer <mdaenzer@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15851>
This commit is contained in:

committed by
Marge Bot

parent
cf1390e1b8
commit
48ae404b42
@@ -116,7 +116,12 @@ kopper_init_screen(__DRIscreen * sPriv)
|
||||
struct kopper_screen *kscreen;
|
||||
struct pipe_screen *pscreen = NULL;
|
||||
|
||||
assert(sPriv->kopper_loader);
|
||||
if (!sPriv->kopper_loader) {
|
||||
fprintf(stderr, "mesa: Kopper interface not found!\n"
|
||||
" Ensure the versions of %s built with this version of Zink are\n"
|
||||
" in your library path!\n", KOPPER_LIB_NAMES);
|
||||
return NULL;
|
||||
}
|
||||
kscreen = CALLOC_STRUCT(kopper_screen);
|
||||
if (!kscreen)
|
||||
return NULL;
|
||||
|
@@ -45,11 +45,16 @@ if with_dri2
|
||||
files_libdri += files('dri2.c')
|
||||
endif
|
||||
|
||||
libdri_c_args = []
|
||||
if with_gallium_zink
|
||||
if get_option('glvnd')
|
||||
libdri_c_args += '-DKOPPER_LIB_NAMES="libEGL_@0@ and libGLX_@0@"'.format(get_option('glvnd-vendor-name'))
|
||||
else
|
||||
libdri_c_args += '-DKOPPER_LIB_NAMES="libEGL and libGLX"'
|
||||
endif
|
||||
files_libdri += files('kopper.c')
|
||||
endif
|
||||
|
||||
libdri_c_args = []
|
||||
if with_gallium_softpipe
|
||||
libdri_c_args += '-DGALLIUM_SOFTPIPE'
|
||||
endif
|
||||
|
Reference in New Issue
Block a user