mesa_interface: Move out of GL/internal/

Move it into src/gallium/include/ to make it absolutely clear this is a Mesa detail.
While we're at it, clean up its include sites, including some places
where we can just include kopper_interface.h instead since it includes
mesa_interface.h as its first act.

Acked-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28378>
This commit is contained in:
Adam Jackson 2024-06-13 19:25:17 -04:00 committed by Marge Bot
parent de41fda2f5
commit 91e1ea52c9
32 changed files with 34 additions and 41 deletions

View File

@ -34,7 +34,7 @@
#ifndef KOPPER_INTERFACE_H
#define KOPPER_INTERFACE_H
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include <vulkan/vulkan_core.h>
typedef struct __DRIkopperExtensionRec __DRIkopperExtension;

View File

@ -42,7 +42,7 @@
#include "drm-uapi/drm_fourcc.h"
#endif
#include <GL/gl.h>
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include <sys/stat.h>
#include <sys/types.h>
#include "dri_screen.h"

View File

@ -59,8 +59,7 @@ struct zwp_linux_dmabuf_feedback_v1;
#endif
#include <GL/gl.h>
#include <GL/internal/mesa_interface.h>
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include "kopper_interface.h"
#ifdef HAVE_DRM_PLATFORM

View File

@ -29,8 +29,7 @@
#include <stdbool.h>
#include <stdint.h>
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include "egl_dri2.h"
#if ANDROID_API_LEVEL < 26

View File

@ -31,7 +31,7 @@
#include "util/libdrm.h"
#include "git_sha1.h"
#include "GL/mesa_glinterop.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "util/disk_cache.h"
#include "util/u_memory.h"
#include "util/u_inlines.h"

View File

@ -52,7 +52,7 @@
#include "main/debug_output.h"
#include "main/errors.h"
#include "loader/loader.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "loader_dri_helper.h"
driOptionDescription __dri2ConfigOptions[] = {

View File

@ -35,7 +35,7 @@
#define _DRI_UTIL_H_
#include <GL/gl.h>
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include "kopper_interface.h"
#include "main/formats.h"
#include "main/glconfig.h"

View File

@ -26,7 +26,7 @@
*
**************************************************************************/
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "git_sha1.h"
#include "util/format/u_format.h"
#include "util/u_memory.h"

View File

@ -21,7 +21,7 @@
* DEALINGS IN THE SOFTWARE.
*/
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "git_sha1.h"
#include "util/format/u_format.h"
#include "util/u_memory.h"

View File

@ -34,18 +34,15 @@
#include <errno.h>
#include <limits.h>
#include <assert.h>
#include <sys/types.h>
#include <unistd.h>
#include <dlfcn.h>
#include <xf86drm.h>
#include "drm-uapi/drm_fourcc.h"
#include <GL/gl.h> /* mesa_interface needs GL types */
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include "gbm_driint.h"
#include "gbmint.h"
#include "loader_dri_helper.h"
#include "kopper_interface.h"

View File

@ -35,8 +35,7 @@
#include "c11/threads.h"
#include <GL/gl.h> /* mesa_interface needs GL types */
#include "GL/internal/mesa_interface.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "kopper_interface.h"
struct gbm_dri_surface;

View File

@ -16,7 +16,7 @@ args_gbm = [
]
deps_gbm = []
incs_gbm = [
include_directories('main'), inc_include, inc_src, inc_loader,
include_directories('main'), inc_include, inc_src, inc_loader, inc_gallium
]
if with_dri2

View File

@ -37,7 +37,7 @@
extern "C" {
#endif
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
struct dri2_screen {
struct glx_screen base;

View File

@ -60,7 +60,7 @@
#include <xcb/sync.h>
#include "loader_dri3_helper.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
struct dri3_display
{

View File

@ -38,7 +38,7 @@
#ifdef GLX_DIRECT_RENDERING
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include <stdbool.h>
#include "loader.h"
#include "util/macros.h" /* for PRINTFLIKE */

View File

@ -25,7 +25,7 @@
#include "glxclient.h"
#include "glx_error.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "dri2_priv.h"
#if defined(HAVE_DRI3)
#include "dri3_priv.h"

View File

@ -25,7 +25,7 @@
#include "glxclient.h"
#include "glx_error.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "dri2_priv.h"
#if defined(HAVE_DRI3)
#include "dri3_priv.h"

View File

@ -28,7 +28,6 @@
#include <X11/extensions/XShm.h>
#include "kopper_interface.h"
#include "GL/internal/mesa_interface.h"
struct drisw_display
{

View File

@ -108,7 +108,7 @@ endif
libglx = static_library(
'glx',
[files_libglx, glx_generated],
include_directories : [inc_include, inc_src, inc_glapi, inc_loader],
include_directories : [inc_include, inc_src, inc_glapi, inc_loader, inc_gallium],
c_args : [
'-DGL_LIB_NAME="lib@0@.so.@1@"'.format(gl_lib_name, gl_lib_version.split('.')[0]),
],

View File

@ -28,7 +28,7 @@ if with_shared_glapi
[files_glx_test, glx_indirect_size_h, main_dispatch_h],
link_with : [libglx, libglapi, libloader],
include_directories : [
inc_src, inc_include, inc_mesa, inc_mapi, inc_glx, inc_loader,
inc_src, inc_include, inc_mesa, inc_mapi, inc_glx, inc_loader, inc_gallium
],
dependencies : [dep_libdrm, dep_glproto, dep_thread, idep_gtest]
),

View File

@ -29,7 +29,7 @@
#include "glxclient.h"
#include "glx_error.h"
#include "dri2.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#include "dri2_priv.h"
namespace {

View File

@ -45,7 +45,7 @@
#include <sys/sysmacros.h>
#endif
#include <GL/gl.h>
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include "loader.h"
#include "util/libdrm.h"
#include "util/os_file.h"

View File

@ -30,7 +30,7 @@
#include <stdbool.h>
#include <sys/stat.h>
#include <stddef.h>
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
#ifdef __cplusplus
extern "C" {

View File

@ -32,7 +32,7 @@
#include <xcb/present.h>
#include <GL/gl.h>
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include <c11/threads.h>
enum loader_dri3_buffer_type {

View File

@ -24,7 +24,7 @@
#include <sys/types.h>
#include <GL/gl.h> /* mesa_interface needs GL types */
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include "drm-uapi/drm_fourcc.h"
#include "loader_dri_helper.h"

View File

@ -25,7 +25,7 @@
#include <sys/types.h>
#include <GL/gl.h> /* mesa_interface needs GL types */
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include <c11/threads.h>
#include "util/format/u_formats.h"

View File

@ -8,7 +8,7 @@ if with_platform_x11 and with_dri3
'loader_dri3_helper',
'loader_dri3_helper.c',
gnu_symbol_visibility : 'hidden',
include_directories : [inc_include, inc_src],
include_directories : [inc_include, inc_src, inc_gallium],
dependencies : [
idep_mesautil,
dep_libdrm, dep_xcb_dri3, dep_xcb_present, dep_xcb_sync, dep_xshmfence,
@ -25,7 +25,7 @@ if with_platform_wayland
'loader_wayland_helper',
'loader_wayland_helper.c',
gnu_symbol_visibility : 'hidden',
include_directories : [inc_include, inc_src],
include_directories : [inc_include, inc_src, inc_gallium],
dependencies : [
dep_wayland_client,
],
@ -44,7 +44,7 @@ libloader = static_library(
['loader_dri_helper.c', 'loader.c', sha1_h],
c_args : loader_c_args,
gnu_symbol_visibility : 'hidden',
include_directories : [inc_include, inc_src, inc_util],
include_directories : [inc_include, inc_src, inc_util, inc_gallium],
dependencies : [dep_libdrm, dep_thread, dep_xcb, dep_xcb_xrandr],
build_by_default : false,
)

View File

@ -63,7 +63,7 @@ endif
libglapi_bridge = static_library(
'glapi_bridge',
bridge_glapi_files,
include_directories : [inc_mesa, inc_include, inc_src, inc_mapi],
include_directories : [inc_mesa, inc_include, inc_src, inc_mapi, inc_gallium],
c_args : [c_msvc_compat_args, bridge_glapi_args],
dependencies : [dep_thread, dep_selinux, idep_mesautil],
build_by_default : false,
@ -75,7 +75,7 @@ else
libglapi_static = static_library(
'glapi_static',
static_glapi_files,
include_directories : [inc_mesa, inc_include, inc_src, inc_mapi],
include_directories : [inc_mesa, inc_include, inc_src, inc_mapi, inc_gallium],
c_args : [c_msvc_compat_args, static_glapi_args],
dependencies : [dep_thread, dep_selinux, idep_mesautil],
build_by_default : false,
@ -90,7 +90,7 @@ if with_any_opengl and not with_shared_glapi and with_tests and not with_platfor
executable(
'glapi_static_check_table',
['tests/check_table.cpp', glapitable_h],
include_directories : [inc_include, inc_src, inc_mesa, inc_mapi],
include_directories : [inc_include, inc_src, inc_mesa, inc_mapi, inc_gallium],
link_with : [libglapi_static],
dependencies : [idep_gtest, dep_thread],
),

View File

@ -25,7 +25,7 @@
* Chia-I Wu <olv@lunarg.com>
*/
#include <GL/internal/mesa_interface.h>
#include "mesa_interface.h"
#include "main/errors.h"
#include "main/texobj.h"
#include "main/teximage.h"

View File

@ -30,7 +30,7 @@ endif
_libmesa_u_gralloc = static_library(
'_mesa_u_gralloc',
[files_u_gralloc],
include_directories : [inc_include, inc_util],
include_directories : [inc_gallium, inc_include, inc_util],
c_args : c_args_for_u_gralloc,
cpp_args : cpp_args_for_u_gralloc,
override_options : options_for_u_gralloc,

View File

@ -17,7 +17,7 @@ extern "C" {
#include <stdbool.h>
#include "util/macros.h"
#include "GL/internal/mesa_interface.h"
#include "mesa_interface.h"
struct u_gralloc;