meson: revert glvnd workaround
authorEric Engestrom <eric.engestrom@intel.com>
Wed, 25 Sep 2019 16:38:49 +0000 (17:38 +0100)
committerEric Engestrom <eric.engestrom@intel.com>
Thu, 31 Oct 2019 17:09:59 +0000 (17:09 +0000)
This effectively reverts MR !2112.

Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
include/meson.build
meson.build
src/egl/meson.build
src/meson.build

index a64d9373a9295e2b21496007a3812245a4d489f4..4c0b12d3c6a83dcf6e835a9bb65d8292394214e4 100644 (file)
@@ -22,7 +22,7 @@ inc_include = include_directories('.')
 inc_d3d9 = include_directories('D3D9')
 inc_haikugl = include_directories('HaikuGL')
 
 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
   if with_gles1 or with_gles2 or with_opengl or with_egl
     install_headers('KHR/khrplatform.h', subdir : 'KHR')
   endif
index 9871d9d6aa9af41b288241437f9494df1d19c380..b2d160ccedf1f0b304c3e152e14fcf41c7e254c8 100644 (file)
@@ -1447,12 +1447,8 @@ else
 endif
 
 dep_glvnd = null_dep
 endif
 
 dep_glvnd = null_dep
-glvnd_has_headers_and_pc_files = false
 if with_glvnd
   dep_glvnd = dependency('libglvnd', version : '>= 1.2.0')
 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
 
   pre_args += '-DUSE_LIBGLVND=1'
 endif
 
index 9c2c055c3eb07f8852345e0bf3e58d61920492de..14aca2a2186ea62bd21b7756f00ea9b80f93a491 100644 (file)
@@ -173,21 +173,12 @@ libegl = shared_library(
   version : egl_lib_version,
 )
 
   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(),
   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,
     libraries_private: gl_priv_libs,
     requires_private : gl_priv_reqs,
     extra_cflags : gl_pkgconfig_c_flags,
index 15fa52be57c4f84c081e694be8b834de5a8d43ef..cefa1c9ac2803f6709b88d88d3829b600edff937 100644 (file)
@@ -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.
 
 # 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(),
   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'],
     libraries_private : gl_priv_libs,
     requires_private : gl_priv_reqs,
     variables : ['glx_tls=yes'],