All of lore.kernel.org
 help / color / mirror / Atom feed
From: Emil Velikov <emil.l.velikov@gmail.com>
To: dri-devel@lists.freedesktop.org
Cc: Emil Velikov <emil.l.velikov@gmail.com>
Subject: [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources
Date: Tue, 29 Jul 2014 18:27:18 +0100	[thread overview]
Message-ID: <1406654843-13625-4-git-send-email-emil.l.velikov@gmail.com> (raw)
In-Reply-To: <1406654843-13625-1-git-send-email-emil.l.velikov@gmail.com>

Will be used to consolidate the required sources lists as well as the
install-able headers. This is turn will help us to avoid the
duplication with the upcoming Android build support.

v2 Rename the headers variable to *_H_FILES.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Makefile.am                  | 13 ++++---------
 Makefile.sources             | 12 ++++++++++++
 freedreno/Makefile.am        | 24 +++---------------------
 freedreno/Makefile.sources   | 24 ++++++++++++++++++++++++
 include/drm/Makefile.am      | 20 ++++----------------
 include/drm/Makefile.sources | 18 ++++++++++++++++++
 intel/Makefile.am            | 16 ++++------------
 intel/Makefile.sources       | 14 ++++++++++++++
 nouveau/Makefile.am          | 11 ++++-------
 nouveau/Makefile.sources     |  9 +++++++++
 radeon/Makefile.am           | 22 ++++------------------
 radeon/Makefile.sources      | 19 +++++++++++++++++++
 12 files changed, 119 insertions(+), 83 deletions(-)
 create mode 100644 Makefile.sources
 create mode 100644 freedreno/Makefile.sources
 create mode 100644 include/drm/Makefile.sources
 create mode 100644 intel/Makefile.sources
 create mode 100644 nouveau/Makefile.sources
 create mode 100644 radeon/Makefile.sources

diff --git a/Makefile.am b/Makefile.am
index 826c30d..fab2a9a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -18,6 +18,8 @@
 #  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.
 
+include Makefile.sources
+
 ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
 
 pkgconfigdir = @pkgconfigdir@
@@ -62,17 +64,10 @@ libdrm_la_CPPFLAGS = -I$(top_srcdir)/include/drm
 AM_CFLAGS = \
 	$(VALGRIND_CFLAGS)
 
-libdrm_la_SOURCES =				\
-	xf86drm.c				\
-	xf86drmHash.c				\
-	xf86drmRandom.c				\
-	xf86drmSL.c				\
-	xf86drmMode.c				\
-	xf86atomic.h				\
-	libdrm_lists.h
+libdrm_la_SOURCES = $(LIBDRM_FILES)
 
 libdrmincludedir = ${includedir}
-libdrminclude_HEADERS = xf86drm.h xf86drmMode.h
+libdrminclude_HEADERS = $(LIBDRM_H_FILES)
 
 EXTRA_DIST = libdrm.pc.in include/drm/*
 
diff --git a/Makefile.sources b/Makefile.sources
new file mode 100644
index 0000000..15e38b5
--- /dev/null
+++ b/Makefile.sources
@@ -0,0 +1,12 @@
+LIBDRM_FILES := \
+	xf86drm.c \
+	xf86drmHash.c \
+	xf86drmRandom.c \
+	xf86drmSL.c \
+	xf86drmMode.c \
+	xf86atomic.h \
+	libdrm_lists.h
+
+LIBDRM_H_FILES := \
+	xf86drm.h \
+	xf86drmMode.h
diff --git a/freedreno/Makefile.am b/freedreno/Makefile.am
index 7903e5b..3a6f7f5 100644
--- a/freedreno/Makefile.am
+++ b/freedreno/Makefile.am
@@ -1,4 +1,5 @@
 AUTOMAKE_OPTIONS=subdir-objects
+include Makefile.sources
 
 AM_CFLAGS = \
 	$(WARN_CFLAGS) \
@@ -12,29 +13,10 @@ libdrm_freedreno_ladir = $(libdir)
 libdrm_freedreno_la_LDFLAGS = -version-number 1:0:0 -no-undefined
 libdrm_freedreno_la_LIBADD = ../libdrm.la @PTHREADSTUBS_LIBS@
 
-libdrm_freedreno_la_SOURCES = \
-	freedreno_device.c \
-	freedreno_pipe.c \
-	freedreno_priv.h \
-	freedreno_ringbuffer.c \
-	freedreno_bo.c \
-	kgsl/kgsl_bo.c \
-	kgsl/kgsl_device.c \
-	kgsl/kgsl_drm.h \
-	kgsl/kgsl_pipe.c \
-	kgsl/kgsl_priv.h \
-	kgsl/kgsl_ringbuffer.c \
-	kgsl/msm_kgsl.h \
-	msm/msm_bo.c \
-	msm/msm_device.c \
-	msm/msm_drm.h \
-	msm/msm_pipe.c \
-	msm/msm_priv.h \
-	msm/msm_ringbuffer.c \
-	list.h
+libdrm_freedreno_la_SOURCES = $(LIBDRM_FREEDRENO_FILES)
 
 libdrm_freedrenocommonincludedir = ${includedir}/freedreno
-libdrm_freedrenocommoninclude_HEADERS = freedreno_drmif.h freedreno_ringbuffer.h
+libdrm_freedrenocommoninclude_HEADERS = $(LIBDRM_FREEDRENO_H_FILES)
 
 pkgconfigdir = @pkgconfigdir@
 pkgconfig_DATA = libdrm_freedreno.pc
diff --git a/freedreno/Makefile.sources b/freedreno/Makefile.sources
new file mode 100644
index 0000000..91020df
--- /dev/null
+++ b/freedreno/Makefile.sources
@@ -0,0 +1,24 @@
+LIBDRM_FREEDRENO_FILES := \
+	freedreno_device.c \
+	freedreno_pipe.c \
+	freedreno_priv.h \
+	freedreno_ringbuffer.c \
+	freedreno_bo.c \
+	kgsl/kgsl_bo.c \
+	kgsl/kgsl_device.c \
+	kgsl/kgsl_drm.h \
+	kgsl/kgsl_pipe.c \
+	kgsl/kgsl_priv.h \
+	kgsl/kgsl_ringbuffer.c \
+	kgsl/msm_kgsl.h \
+	msm/msm_bo.c \
+	msm/msm_device.c \
+	msm/msm_drm.h \
+	msm/msm_pipe.c \
+	msm/msm_priv.h \
+	msm/msm_ringbuffer.c \
+	list.h
+
+LIBDRM_FREEDRENO_H_FILES := \
+	freedreno_drmif.h \
+	freedreno_ringbuffer.h
diff --git a/include/drm/Makefile.am b/include/drm/Makefile.am
index 2bc34d2..7a246ae 100644
--- a/include/drm/Makefile.am
+++ b/include/drm/Makefile.am
@@ -22,23 +22,11 @@
 # however, r300 and via need their reg headers installed in order to build.
 # better solutions are welcome.
 
+include Makefile.sources
+
 klibdrmincludedir = ${includedir}/libdrm
-klibdrminclude_HEADERS = \
-	drm.h \
-	drm_mode.h \
-	drm_fourcc.h \
-	drm_sarea.h \
-	i915_drm.h \
-	mga_drm.h \
-	nouveau_drm.h \
-	r128_drm.h \
-	radeon_drm.h \
-	savage_drm.h \
-	sis_drm.h \
-	via_drm.h \
-	mach64_drm.h \
-	qxl_drm.h
+klibdrminclude_HEADERS = $(LIBDRM_INCLUDE_H_FILES)
 
 if HAVE_VMWGFX
-klibdrminclude_HEADERS += vmwgfx_drm.h
+klibdrminclude_HEADERS += $(LIBDRM_INCLUDE_VMWGFX_H_FILES)
 endif
diff --git a/include/drm/Makefile.sources b/include/drm/Makefile.sources
new file mode 100644
index 0000000..8e1b585
--- /dev/null
+++ b/include/drm/Makefile.sources
@@ -0,0 +1,18 @@
+LIBDRM_INCLUDE_H_FILES := \
+	drm.h \
+	drm_mode.h \
+	drm_fourcc.h \
+	drm_sarea.h \
+	i915_drm.h \
+	mga_drm.h \
+	nouveau_drm.h \
+	r128_drm.h \
+	radeon_drm.h \
+	savage_drm.h \
+	sis_drm.h \
+	via_drm.h \
+	mach64_drm.h \
+	qxl_drm.h
+
+LIBDRM_INCLUDE_VMWGFX_H_FILES := \
+	vmwgfx_drm.h
diff --git a/intel/Makefile.am b/intel/Makefile.am
index f49b099..9c85c47 100644
--- a/intel/Makefile.am
+++ b/intel/Makefile.am
@@ -22,6 +22,8 @@
 # Authors:
 #    Eric Anholt <eric@anholt.net>
 
+include Makefile.sources
+
 AM_CFLAGS = \
 	$(WARN_CFLAGS) \
 	-I$(top_srcdir) \
@@ -39,22 +41,12 @@ libdrm_intel_la_LIBADD = ../libdrm.la \
 	@PCIACCESS_LIBS@ \
 	@CLOCK_LIB@
 
-libdrm_intel_la_SOURCES = \
-	intel_bufmgr.c \
-	intel_bufmgr_priv.h \
-	intel_bufmgr_fake.c \
-	intel_bufmgr_gem.c \
-	intel_decode.c \
-	intel_chipset.h \
-	mm.c \
-	mm.h
+libdrm_intel_la_SOURCES = $(LIBDRM_INTEL_FILES)
 
 intel_bufmgr_gem_o_CFLAGS = $(AM_CFLAGS) -c99
 
 libdrm_intelincludedir = ${includedir}/libdrm
-libdrm_intelinclude_HEADERS = intel_bufmgr.h \
-			      intel_aub.h \
-			      intel_debug.h
+libdrm_intelinclude_HEADERS = $(LIBDRM_INTEL_H_FILES)
 
 # This may be interesting even outside of "make check", due to the -dump option.
 noinst_PROGRAMS = test_decode
diff --git a/intel/Makefile.sources b/intel/Makefile.sources
new file mode 100644
index 0000000..7b2272c
--- /dev/null
+++ b/intel/Makefile.sources
@@ -0,0 +1,14 @@
+LIBDRM_INTEL_FILES := \
+	intel_bufmgr.c \
+	intel_bufmgr_priv.h \
+	intel_bufmgr_fake.c \
+	intel_bufmgr_gem.c \
+	intel_decode.c \
+	intel_chipset.h \
+	mm.c \
+	mm.h
+
+LIBDRM_INTEL_H_FILES := \
+	intel_bufmgr.h \
+	intel_aub.h \
+	intel_debug.h
diff --git a/nouveau/Makefile.am b/nouveau/Makefile.am
index 206e892..00fa690 100644
--- a/nouveau/Makefile.am
+++ b/nouveau/Makefile.am
@@ -1,3 +1,5 @@
+include Makefile.sources
+
 AM_CFLAGS = \
 	$(WARN_CFLAGS) \
 	-I$(top_srcdir) \
@@ -11,15 +13,10 @@ libdrm_nouveau_ladir = $(libdir)
 libdrm_nouveau_la_LDFLAGS = -version-number 2:0:0 -no-undefined
 libdrm_nouveau_la_LIBADD = ../libdrm.la @PTHREADSTUBS_LIBS@
 
-libdrm_nouveau_la_SOURCES = nouveau.c \
-			    pushbuf.c \
-			    bufctx.c \
-			    abi16.c \
-			    private.h
-
+libdrm_nouveau_la_SOURCES = $(LIBDRM_NOUVEAU_FILES)
 
 libdrm_nouveauincludedir = ${includedir}/libdrm
-libdrm_nouveauinclude_HEADERS = nouveau.h
+libdrm_nouveauinclude_HEADERS = $(LIBDRM_NOUVEAU_H_FILES)
 
 pkgconfigdir = @pkgconfigdir@
 pkgconfig_DATA = libdrm_nouveau.pc
diff --git a/nouveau/Makefile.sources b/nouveau/Makefile.sources
new file mode 100644
index 0000000..89f2a2b
--- /dev/null
+++ b/nouveau/Makefile.sources
@@ -0,0 +1,9 @@
+LIBDRM_NOUVEAU_FILES := \
+	nouveau.c \
+	pushbuf.c \
+	bufctx.c \
+	abi16.c \
+	private.h
+
+LIBDRM_NOUVEAU_H_FILES := \
+	nouveau.h
diff --git a/radeon/Makefile.am b/radeon/Makefile.am
index a8cd100..ae913c0 100644
--- a/radeon/Makefile.am
+++ b/radeon/Makefile.am
@@ -22,6 +22,8 @@
 # Authors:
 #    Jérôme Glisse <glisse@freedesktop.org>
 
+include Makefile.sources
+
 AM_CFLAGS = \
 	$(WARN_CFLAGS) \
 	-I$(top_srcdir) \
@@ -34,26 +36,10 @@ libdrm_radeon_ladir = $(libdir)
 libdrm_radeon_la_LDFLAGS = -version-number 1:0:1 -no-undefined
 libdrm_radeon_la_LIBADD = ../libdrm.la @PTHREADSTUBS_LIBS@
 
-libdrm_radeon_la_SOURCES = \
-	radeon_bo_gem.c \
-	radeon_cs_gem.c \
-	radeon_cs_space.c \
-	radeon_bo.c \
-	radeon_cs.c \
-	radeon_surface.c \
-	bof.c \
-	bof.h
+libdrm_radeon_la_SOURCES = $(LIBDRM_RADEON_FILES)
 
 libdrm_radeonincludedir = ${includedir}/libdrm
-libdrm_radeoninclude_HEADERS = \
-	radeon_bo.h \
-	radeon_cs.h \
-	radeon_surface.h \
-	radeon_bo_gem.h \
-	radeon_cs_gem.h \
-	radeon_bo_int.h \
-	radeon_cs_int.h \
-	r600_pci_ids.h
+libdrm_radeoninclude_HEADERS = $(LIBDRM_RADEON_H_FILES)
 
 pkgconfigdir = @pkgconfigdir@
 pkgconfig_DATA = libdrm_radeon.pc
diff --git a/radeon/Makefile.sources b/radeon/Makefile.sources
new file mode 100644
index 0000000..a17701a
--- /dev/null
+++ b/radeon/Makefile.sources
@@ -0,0 +1,19 @@
+LIBDRM_RADEON_FILES := \
+	radeon_bo_gem.c \
+	radeon_cs_gem.c \
+	radeon_cs_space.c \
+	radeon_bo.c \
+	radeon_cs.c \
+	radeon_surface.c \
+	bof.c \
+	bof.h
+
+LIBDRM_RADEON_H_FILES := \
+	radeon_bo.h \
+	radeon_cs.h \
+	radeon_surface.h \
+	radeon_bo_gem.h \
+	radeon_cs_gem.h \
+	radeon_bo_int.h \
+	radeon_cs_int.h \
+	r600_pci_ids.h
-- 
2.0.2

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

  parent reply	other threads:[~2014-07-29 17:28 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
2014-07-27 18:25 ` [PATCH 1/8] all: include config.h only when available and use its defines Emil Velikov
2014-07-27 18:25 ` [PATCH 2/8] libkms: remove explicit define _FILE_OFFSET_BITS 64 Emil Velikov
2014-07-27 18:25 ` [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
2014-07-27 18:25 ` [PATCH 4/8] libdrm,intel: Add Android build Emil Velikov
2014-07-27 18:25 ` [PATCH 5/8] libdrm,intel: rework android header handling Emil Velikov
2014-07-27 18:25 ` [PATCH 6/8] radeon: add Android build support Emil Velikov
2014-07-27 18:25 ` [PATCH 7/8] nouveau: " Emil Velikov
2014-07-27 18:25 ` [PATCH 8/8] freedreno: " Emil Velikov
2014-07-28  2:48 ` [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
2014-07-28  7:07   ` Daniel Vetter
2014-07-28 12:01     ` Emil Velikov
2014-07-28 15:22       ` Daniel Vetter
2014-07-29 16:14         ` Gore, Tim
2014-07-29 17:10           ` Emil Velikov
2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
2014-07-29 17:27   ` [PATCH 1/8] all: include config.h only when available and use its defines Emil Velikov
2014-07-29 17:27   ` [PATCH 2/8] libkms: remove explicit define _FILE_OFFSET_BITS 64 Emil Velikov
2014-07-29 17:27   ` Emil Velikov [this message]
2014-08-24 18:28     ` [PATCHv3 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
2014-07-29 17:27   ` [PATCH 4/8] libdrm,intel: Add Android build Emil Velikov
2014-07-29 17:27   ` [PATCH 5/8] libdrm,intel: rework android header handling Emil Velikov
2014-07-29 17:27   ` [PATCH 6/8] radeon: add Android build support Emil Velikov
2014-07-29 17:27   ` [PATCH 7/8] nouveau: " Emil Velikov
2014-07-29 17:27   ` [PATCH 8/8] freedreno: " Emil Velikov
2014-07-31 15:33   ` [PATCHv2 0/8] Upstreaming the Android build and misc fixes Gore, Tim
2014-07-31 18:32     ` Emil Velikov
2014-08-24 18:39       ` Emil Velikov
2014-08-29  9:44         ` Gore, Tim
2014-08-29 10:02           ` Emil Velikov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1406654843-13625-4-git-send-email-emil.l.velikov@gmail.com \
    --to=emil.l.velikov@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.