Mesa (master): intel: Move the DRM uapi headers to a non-Intel location.

Eric Anholt anholt at kemper.freedesktop.org
Wed Jul 12 18:06:09 UTC 2017


Module: Mesa
Branch: master
Commit: 5d6271c6a566b71b84ce060a71494467f312b0df
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=5d6271c6a566b71b84ce060a71494467f312b0df

Author: Eric Anholt <eric at anholt.net>
Date:   Wed Jun 28 16:35:55 2017 -0700

intel: Move the DRM uapi headers to a non-Intel location.

I want to remove vc4's dependency on headers from libdrm as well, but
storing multiple copies of drm_fourcc.h in our tree would be silly.

v2: Update Android.mk as well, move distcheck drm*.h references to
    top-level noinst_HEADERS.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com> (v1)
Reviewed-by: Daniel Stone <daniels at collabora.com> (v1)
Reviewed-by: Rob Herring <robh at kernel.org>

---

 Makefile.am                                      |  4 ++++
 {src/intel/drm => include/drm-uapi}/README       |  0
 {src/intel/drm => include/drm-uapi}/drm.h        |  0
 {src/intel/drm => include/drm-uapi}/drm_fourcc.h |  0
 {src/intel/drm => include/drm-uapi}/drm_mode.h   |  0
 {src/intel/drm => include/drm-uapi}/i915_drm.h   |  0
 src/intel/Android.vulkan.mk                      |  2 +-
 src/intel/Makefile.am                            |  1 -
 src/intel/Makefile.drm.am                        | 22 ----------------------
 src/intel/Makefile.sources                       |  6 ------
 src/intel/Makefile.vulkan.am                     |  2 +-
 src/mesa/drivers/dri/i965/Android.mk             |  4 ++--
 src/mesa/drivers/dri/i965/Makefile.am            |  2 +-
 13 files changed, 9 insertions(+), 34 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 51542af3b8..c83e636603 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -62,6 +62,10 @@ noinst_HEADERS = \
 	include/c99_compat.h \
 	include/c99_math.h \
 	include/c11 \
+	include/drm-uapi/drm.h \
+	include/drm-uapi/drm_fourcc.h \
+	include/drm-uapi/drm_mode.h \
+	include/drm-uapi/i915_drm.h \
 	include/D3D9 \
 	include/GL/wglext.h \
 	include/HaikuGL \
diff --git a/src/intel/drm/README b/include/drm-uapi/README
similarity index 100%
rename from src/intel/drm/README
rename to include/drm-uapi/README
diff --git a/src/intel/drm/drm.h b/include/drm-uapi/drm.h
similarity index 100%
rename from src/intel/drm/drm.h
rename to include/drm-uapi/drm.h
diff --git a/src/intel/drm/drm_fourcc.h b/include/drm-uapi/drm_fourcc.h
similarity index 100%
rename from src/intel/drm/drm_fourcc.h
rename to include/drm-uapi/drm_fourcc.h
diff --git a/src/intel/drm/drm_mode.h b/include/drm-uapi/drm_mode.h
similarity index 100%
rename from src/intel/drm/drm_mode.h
rename to include/drm-uapi/drm_mode.h
diff --git a/src/intel/drm/i915_drm.h b/include/drm-uapi/i915_drm.h
similarity index 100%
rename from src/intel/drm/i915_drm.h
rename to include/drm-uapi/i915_drm.h
diff --git a/src/intel/Android.vulkan.mk b/src/intel/Android.vulkan.mk
index 8f8366aa7f..398f2e7cd0 100644
--- a/src/intel/Android.vulkan.mk
+++ b/src/intel/Android.vulkan.mk
@@ -33,7 +33,7 @@ VULKAN_COMMON_INCLUDES := \
 	$(MESA_TOP)/src/vulkan/wsi \
 	$(MESA_TOP)/src/vulkan/util \
 	$(MESA_TOP)/src/intel \
-	$(MESA_TOP)/src/intel/drm \
+	$(MESA_TOP)/include/drm-uapi \
 	$(MESA_TOP)/src/intel/vulkan
 
 # libmesa_anv_entrypoints with header and dummy.c
diff --git a/src/intel/Makefile.am b/src/intel/Makefile.am
index dad54b70a9..269d73dfcb 100644
--- a/src/intel/Makefile.am
+++ b/src/intel/Makefile.am
@@ -62,7 +62,6 @@ EXTRA_DIST =
 include Makefile.blorp.am
 include Makefile.common.am
 include Makefile.compiler.am
-include Makefile.drm.am
 include Makefile.genxml.am
 include Makefile.isl.am
 include Makefile.tools.am
diff --git a/src/intel/Makefile.drm.am b/src/intel/Makefile.drm.am
deleted file mode 100644
index af4e4afbcd..0000000000
--- a/src/intel/Makefile.drm.am
+++ /dev/null
@@ -1,22 +0,0 @@
-# Copyright 2017 Intel Corporation
-#
-# Permission is hereby granted, free of charge, to any person obtaining a
-# copy of this software and associated documentation files (the "Software"),
-# to deal in the Software without restriction, including without limitation
-# the rights to use, copy, modify, merge, publish, distribute, sublicense,
-# and/or sell copies of the Software, and to permit persons to whom the
-# Software is furnished to do so, subject to the following conditions:
-#
-# The above copyright notice and this permission notice (including the next
-# paragraph) shall be included in all copies or substantial portions of the
-# Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
-# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
-# IN THE SOFTWARE.
-
-EXTRA_DIST += $(DRM_INTEL_FILES)
diff --git a/src/intel/Makefile.sources b/src/intel/Makefile.sources
index 2b6d607aa9..8b2f9fd055 100644
--- a/src/intel/Makefile.sources
+++ b/src/intel/Makefile.sources
@@ -118,12 +118,6 @@ COMPILER_FILES = \
 COMPILER_GENERATED_FILES = \
 	compiler/brw_nir_trig_workarounds.c
 
-DRM_INTEL_FILES = \
-	drm/drm.h \
-	drm/drm_fourcc.h \
-	drm/drm_mode.h \
-	drm/i915_drm.h
-
 GENXML_XML_FILES = \
 	genxml/gen4.xml \
 	genxml/gen45.xml \
diff --git a/src/intel/Makefile.vulkan.am b/src/intel/Makefile.vulkan.am
index 3857a5dc62..6550f6846f 100644
--- a/src/intel/Makefile.vulkan.am
+++ b/src/intel/Makefile.vulkan.am
@@ -84,7 +84,7 @@ VULKAN_CFLAGS = \
 VULKAN_CPPFLAGS = \
 	-I$(top_srcdir)/src/compiler \
 	-I$(top_srcdir)/src/intel/compiler \
-	-I$(top_srcdir)/src/intel/drm \
+	-I$(top_srcdir)/include/drm-uapi \
 	-I$(top_builddir)/src/intel/vulkan \
 	-I$(top_srcdir)/src/intel/vulkan \
 	-I$(top_srcdir)/src/vulkan/wsi \
diff --git a/src/mesa/drivers/dri/i965/Android.mk b/src/mesa/drivers/dri/i965/Android.mk
index 8996aec3b6..d75ffb1381 100644
--- a/src/mesa/drivers/dri/i965/Android.mk
+++ b/src/mesa/drivers/dri/i965/Android.mk
@@ -30,7 +30,7 @@ include $(LOCAL_PATH)/Makefile.sources
 I965_PERGEN_COMMON_INCLUDES := \
 	$(MESA_DRI_C_INCLUDES) \
 	$(MESA_TOP)/src/intel \
-	$(MESA_TOP)/src/intel/drm
+	$(MESA_TOP)/include/drm-uapi
 
 I965_PERGEN_SHARED_LIBRARIES := \
 	$(MESA_DRI_SHARED_LIBRARIES)
@@ -258,7 +258,7 @@ endif
 
 LOCAL_C_INCLUDES := \
 	$(MESA_DRI_C_INCLUDES) \
-	$(MESA_TOP)/src/intel/drm
+	$(MESA_TOP)/include/drm-uapi
 
 LOCAL_SRC_FILES := \
 	$(i965_FILES)
diff --git a/src/mesa/drivers/dri/i965/Makefile.am b/src/mesa/drivers/dri/i965/Makefile.am
index 4b56b4b0ef..ecc1e766f1 100644
--- a/src/mesa/drivers/dri/i965/Makefile.am
+++ b/src/mesa/drivers/dri/i965/Makefile.am
@@ -38,7 +38,7 @@ AM_CFLAGS = \
 	-I$(top_srcdir)/src/compiler/nir \
 	-I$(top_builddir)/src/intel \
 	-I$(top_srcdir)/src/intel \
-	-I$(top_srcdir)/src/intel/drm \
+	-I$(top_srcdir)/include/drm-uapi \
 	$(DEFINES) \
 	$(VISIBILITY_CFLAGS) \
 	$(LIBDRM_CFLAGS) \




More information about the mesa-commit mailing list