From: Eric Engestrom Date: Wed, 25 Sep 2019 16:38:49 +0000 (+0100) Subject: meson: revert glvnd workaround X-Git-Url: https://git.libre-soc.org/?p=mesa.git;a=commitdiff_plain;h=6e21dcc5a31634232660eff1a83052c2ebb4816c meson: revert glvnd workaround This effectively reverts MR !2112. Signed-off-by: Eric Engestrom Reviewed-by: Dylan Baker --- diff --git a/include/meson.build b/include/meson.build index a64d9373a92..4c0b12d3c6a 100644 --- a/include/meson.build +++ b/include/meson.build @@ -22,7 +22,7 @@ inc_include = include_directories('.') inc_d3d9 = include_directories('D3D9') inc_haikugl = include_directories('HaikuGL') -if not glvnd_has_headers_and_pc_files +if not with_glvnd if with_gles1 or with_gles2 or with_opengl or with_egl install_headers('KHR/khrplatform.h', subdir : 'KHR') endif diff --git a/meson.build b/meson.build index 9871d9d6aa9..b2d160ccedf 100644 --- a/meson.build +++ b/meson.build @@ -1447,12 +1447,8 @@ else endif dep_glvnd = null_dep -glvnd_has_headers_and_pc_files = false if with_glvnd dep_glvnd = dependency('libglvnd', version : '>= 1.2.0') - # GLVND before 1.2 was missing its pkg-config and header files, forcing every - # vendor to provide them and the distro maintainers to resolve the conflict. - glvnd_has_headers_and_pc_files = dep_glvnd.version().version_compare('>= 1.2.0') pre_args += '-DUSE_LIBGLVND=1' endif diff --git a/src/egl/meson.build b/src/egl/meson.build index 9c2c055c3eb..14aca2a2186 100644 --- a/src/egl/meson.build +++ b/src/egl/meson.build @@ -173,21 +173,12 @@ libegl = shared_library( version : egl_lib_version, ) -# If using glvnd the pkg-config header should not point to EGL_mesa, it should -# point to EGL. glvnd is only available on unix like platforms so adding -l -# should be safe here -if not with_glvnd or not glvnd_has_headers_and_pc_files - if not glvnd_has_headers_and_pc_files - _egl = '-L${libdir} -lEGL' - else - _egl = libegl - endif - +if not with_glvnd pkg.generate( name : 'egl', description : 'Mesa EGL Library', version : meson.project_version(), - libraries : _egl, + libraries : libegl, libraries_private: gl_priv_libs, requires_private : gl_priv_reqs, extra_cflags : gl_pkgconfig_c_flags, diff --git a/src/meson.build b/src/meson.build index 15fa52be57c..cefa1c9ac28 100644 --- a/src/meson.build +++ b/src/meson.build @@ -112,22 +112,12 @@ endif # This must be after at least mesa, glx, and gallium, since libgl will be # defined in one of those subdirs depending on the glx provider. -if with_glx != 'disabled' and (not with_glvnd or not glvnd_has_headers_and_pc_files) - # If using glvnd the pkg-config header should not point to GL_mesa, it should - # point to GL. glvnd is only available on unix like platforms so adding -l - # should be safe here - # TODO: in the glvnd case glvnd itself should really be providing this. - if not glvnd_has_headers_and_pc_files - _gl = '-L${libdir} -lGL' - else - _gl = libgl - endif - +if with_glx != 'disabled' and not with_glvnd pkg.generate( name : 'gl', description : 'Mesa OpenGL Library', version : meson.project_version(), - libraries : _gl, + libraries : libgl, libraries_private : gl_priv_libs, requires_private : gl_priv_reqs, variables : ['glx_tls=yes'],