dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/8] Upstreaming the Android build and misc fixes
@ 2014-07-27 18:25 Emil Velikov
  2014-07-27 18:25 ` [PATCH 1/8] all: include config.h only when available and use its defines Emil Velikov
                   ` (9 more replies)
  0 siblings, 10 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

Hello list,

Recently I've had a go at the Anroid builds and I felt ... inspired that
there are (at least) two downstream repositories that have the relevant
Android build, yet all of them use 6+month old libdrm.
Making even builds a pain in the neck :'(

Are there any objections if we get the android build upstream ? AFAICS 
it's nicely isolated from everything else + I've managed to reuse all 
the source/headers lists.

Note that the series lacks a couple of patches from the downstream 
repos, yet adds support for radeon, nouveau and freedreno :)

The missing fixes are - s/mmap/mmap64/, dma-bufs support + other intel 
specific "hacks". If people are happy with the series then we can take
a look at the final bits.


Cheers,
Emil

^ permalink raw reply	[flat|nested] 31+ messages in thread

* [PATCH 1/8] all: include config.h only when available and use its defines
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
@ 2014-07-27 18:25 ` Emil Velikov
  2014-07-27 18:25 ` [PATCH 2/8] libkms: remove explicit define _FILE_OFFSET_BITS 64 Emil Velikov
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

... rather than explicitly redefining HAVE_STDINT_H and _GNU_SOURCE.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 intel/test_decode.c       | 5 +++--
 libkms/api.c              | 2 ++
 libkms/dumb.c             | 4 +++-
 libkms/exynos.c           | 4 +++-
 libkms/intel.c            | 4 +++-
 libkms/linux.c            | 2 ++
 libkms/nouveau.c          | 4 +++-
 libkms/radeon.c           | 4 +++-
 libkms/vmwgfx.c           | 4 +++-
 tests/drmstat.c           | 2 ++
 tests/modetest/buffers.c  | 2 ++
 tests/modetest/cursor.c   | 2 ++
 tests/modetest/modetest.c | 2 ++
 tests/vbltest/vbltest.c   | 2 ++
 14 files changed, 35 insertions(+), 8 deletions(-)

diff --git a/intel/test_decode.c b/intel/test_decode.c
index b710f34..bef9d99 100644
--- a/intel/test_decode.c
+++ b/intel/test_decode.c
@@ -21,7 +21,9 @@
  * IN THE SOFTWARE.
  */
 
-#define _GNU_SOURCE
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 
 #include <string.h>
 #include <stdlib.h>
@@ -33,7 +35,6 @@
 #include <sys/mman.h>
 #include <err.h>
 
-#include "config.h"
 #include "intel_bufmgr.h"
 #include "intel_chipset.h"
 
diff --git a/libkms/api.c b/libkms/api.c
index 5befaa0..b512c42 100644
--- a/libkms/api.c
+++ b/libkms/api.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 #include <errno.h>
 #include <stdlib.h>
 #include <string.h>
diff --git a/libkms/dumb.c b/libkms/dumb.c
index 440efb3..794282f 100644
--- a/libkms/dumb.c
+++ b/libkms/dumb.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/exynos.c b/libkms/exynos.c
index 93e36a1..243915b 100644
--- a/libkms/exynos.c
+++ b/libkms/exynos.c
@@ -11,7 +11,9 @@
  * option) any later version.
  */
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/intel.c b/libkms/intel.c
index abae452..92f1cf2 100644
--- a/libkms/intel.c
+++ b/libkms/intel.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/linux.c b/libkms/linux.c
index 9b4f29e..17e1d58 100644
--- a/libkms/linux.c
+++ b/libkms/linux.c
@@ -30,7 +30,9 @@
  */
 
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 #include <errno.h>
 #include <stdio.h>
 #include <stdlib.h>
diff --git a/libkms/nouveau.c b/libkms/nouveau.c
index 608092f..2de827d 100644
--- a/libkms/nouveau.c
+++ b/libkms/nouveau.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/radeon.c b/libkms/radeon.c
index f5e382a..29375c4 100644
--- a/libkms/radeon.c
+++ b/libkms/radeon.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/vmwgfx.c b/libkms/vmwgfx.c
index d594b3b..598f383 100644
--- a/libkms/vmwgfx.c
+++ b/libkms/vmwgfx.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/tests/drmstat.c b/tests/drmstat.c
index c51cbc6..5935d07 100644
--- a/tests/drmstat.c
+++ b/tests/drmstat.c
@@ -28,7 +28,9 @@
  * 
  */
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <stdio.h>
 #include <stdlib.h>
diff --git a/tests/modetest/buffers.c b/tests/modetest/buffers.c
index 8206ce3..29b520d 100644
--- a/tests/modetest/buffers.c
+++ b/tests/modetest/buffers.c
@@ -24,7 +24,9 @@
  * IN THE SOFTWARE.
  */
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <errno.h>
diff --git a/tests/modetest/cursor.c b/tests/modetest/cursor.c
index 7077f20..60f240a 100644
--- a/tests/modetest/cursor.c
+++ b/tests/modetest/cursor.c
@@ -22,7 +22,9 @@
  * IN THE SOFTWARE.
  */
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <errno.h>
diff --git a/tests/modetest/modetest.c b/tests/modetest/modetest.c
index 7d436b5..92efb82 100644
--- a/tests/modetest/modetest.c
+++ b/tests/modetest/modetest.c
@@ -37,7 +37,9 @@
  * TODO: use cairo to write the mode info on the selected output once
  *       the mode has been programmed, along with possible test patterns.
  */
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <ctype.h>
diff --git a/tests/vbltest/vbltest.c b/tests/vbltest/vbltest.c
index 2a09d28..50e29dc 100644
--- a/tests/vbltest/vbltest.c
+++ b/tests/vbltest/vbltest.c
@@ -37,7 +37,9 @@
  * TODO: use cairo to write the mode info on the selected output once
  *       the mode has been programmed, along with possible test patterns.
  */
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <stdio.h>
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 2/8] libkms: remove explicit define _FILE_OFFSET_BITS 64
  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 ` Emil Velikov
  2014-07-27 18:25 ` [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

configure.ac has AC_SYS_LARGEFILE which provides the define and/or
approapriate magic when required.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 libkms/dumb.c    | 1 -
 libkms/exynos.c  | 1 -
 libkms/intel.c   | 1 -
 libkms/nouveau.c | 1 -
 libkms/radeon.c  | 1 -
 libkms/vmwgfx.c  | 1 -
 6 files changed, 6 deletions(-)

diff --git a/libkms/dumb.c b/libkms/dumb.c
index 794282f..5702543 100644
--- a/libkms/dumb.c
+++ b/libkms/dumb.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/exynos.c b/libkms/exynos.c
index 243915b..92e329c 100644
--- a/libkms/exynos.c
+++ b/libkms/exynos.c
@@ -14,7 +14,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/intel.c b/libkms/intel.c
index 92f1cf2..b006ea4 100644
--- a/libkms/intel.c
+++ b/libkms/intel.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/nouveau.c b/libkms/nouveau.c
index 2de827d..15c012e 100644
--- a/libkms/nouveau.c
+++ b/libkms/nouveau.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/radeon.c b/libkms/radeon.c
index 29375c4..938321b 100644
--- a/libkms/radeon.c
+++ b/libkms/radeon.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/vmwgfx.c b/libkms/vmwgfx.c
index 598f383..08163a1 100644
--- a/libkms/vmwgfx.c
+++ b/libkms/vmwgfx.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdlib.h>
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources
  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 ` Emil Velikov
  2014-07-27 18:25 ` [PATCH 4/8] libdrm,intel: Add Android build Emil Velikov
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

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.

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..16704df 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_HEADERS)
 
 EXTRA_DIST = libdrm.pc.in include/drm/*
 
diff --git a/Makefile.sources b/Makefile.sources
new file mode 100644
index 0000000..fbf9635
--- /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_HEADERS := \
+	xf86drm.h \
+	xf86drmMode.h
diff --git a/freedreno/Makefile.am b/freedreno/Makefile.am
index 7903e5b..55de79d 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_HEADERS)
 
 pkgconfigdir = @pkgconfigdir@
 pkgconfig_DATA = libdrm_freedreno.pc
diff --git a/freedreno/Makefile.sources b/freedreno/Makefile.sources
new file mode 100644
index 0000000..f78cd12
--- /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_HEADERS := \
+	freedreno_drmif.h \
+	freedreno_ringbuffer.h
diff --git a/include/drm/Makefile.am b/include/drm/Makefile.am
index 2bc34d2..83b1eae 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_HEADERS)
 
 if HAVE_VMWGFX
-klibdrminclude_HEADERS += vmwgfx_drm.h
+klibdrminclude_HEADERS += $(LIBDRM_INCLUDE_VMWGFX_HEADERS)
 endif
diff --git a/include/drm/Makefile.sources b/include/drm/Makefile.sources
new file mode 100644
index 0000000..474d4c1
--- /dev/null
+++ b/include/drm/Makefile.sources
@@ -0,0 +1,18 @@
+LIBDRM_INCLUDE_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
+
+LIBDRM_INCLUDE_VMWGFX_HEADERS := \
+	vmwgfx_drm.h
diff --git a/intel/Makefile.am b/intel/Makefile.am
index f49b099..49b41a8 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_HEADERS)
 
 # 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..f1ae351
--- /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_HEADERS := \
+	intel_bufmgr.h \
+	intel_aub.h \
+	intel_debug.h
diff --git a/nouveau/Makefile.am b/nouveau/Makefile.am
index 206e892..47c1eb2 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_HEADERS)
 
 pkgconfigdir = @pkgconfigdir@
 pkgconfig_DATA = libdrm_nouveau.pc
diff --git a/nouveau/Makefile.sources b/nouveau/Makefile.sources
new file mode 100644
index 0000000..220d44b
--- /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_HEADERS := \
+	nouveau.h
diff --git a/radeon/Makefile.am b/radeon/Makefile.am
index a8cd100..a99a625 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_HEADERS)
 
 pkgconfigdir = @pkgconfigdir@
 pkgconfig_DATA = libdrm_radeon.pc
diff --git a/radeon/Makefile.sources b/radeon/Makefile.sources
new file mode 100644
index 0000000..ff0e1f6
--- /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_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
-- 
2.0.2

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

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 4/8] libdrm,intel: Add Android build
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
                   ` (2 preceding siblings ...)
  2014-07-27 18:25 ` [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
@ 2014-07-27 18:25 ` Emil Velikov
  2014-07-27 18:25 ` [PATCH 5/8] libdrm,intel: rework android header handling Emil Velikov
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

Contains the following patches squashed in:

    commit f340a8b9f2b84d5762553bef046914e0bde20795
    Author: Chad Versace <chad.versace@linux.intel.com>
    Date: Wed, 21 Dec 2011 11:43:57 -0800

        libdrm,intel: Add Android makefiles (v2)

        This enables libdrm.so and libdrm_intel.so to build on Android
        IceCreamSandwich.

        v2: Link libdrm_intel to libpciaccess.

        Change-Id: Ie5ed4bc0e6b4f9f819e3ec44488e385c35e97128
        Signed-off-by: Chad Versace <chad.versace@linux.intel.com>

    commit 8fb3f42389dea34218ed1fe59550ec2abb4d6953
    Author: Andrew Boie <andrew.p.boie@intel.com>
    Date: Wed, 26 Sep 2012 13:32:05 -0700

        libdrm, libdrm_intel: Skip driver name checks

        These libraries have 'optional' tags, which means they won't get
        built unless something else depends on them or they are added to
        PRODUCT_PACKAGES. There's no need for additional filtering.

        Change-Id: I5d90969f38671f8144c0dc27d47144b3f09a15ce
        Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
---
 Android.mk       | 45 +++++++++++++++++++++++++++++++++++++++++++++
 intel/Android.mk | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 95 insertions(+)
 create mode 100644 Android.mk
 create mode 100644 intel/Android.mk

diff --git a/Android.mk b/Android.mk
new file mode 100644
index 0000000..afe59ce
--- /dev/null
+++ b/Android.mk
@@ -0,0 +1,45 @@
+#
+# Copyright © 2011 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.
+#
+
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+LIBDRM_TOP := $(LOCAL_PATH)
+
+# Import variables LIBDRM_FILES, LIBDRM_HEADERS
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SRC_FILES := $(LIBDRM_FILES)
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+include $(BUILD_SHARED_LIBRARY)
+
+include $(LOCAL_PATH)/intel/Android.mk
diff --git a/intel/Android.mk b/intel/Android.mk
new file mode 100644
index 0000000..5c48a95
--- /dev/null
+++ b/intel/Android.mk
@@ -0,0 +1,50 @@
+#
+# Copyright © 2011 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.
+#
+
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_INTEL_FILES, LIBDRM_INTEL_HEADERS
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_intel
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_INTEL_FILES)
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/intel \
+	$(LIBDRM_TOP)/include/drm \
+	external/libpciaccess/include
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm \
+	libpciaccess
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

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

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 5/8] libdrm,intel: rework android header handling
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
                   ` (3 preceding siblings ...)
  2014-07-27 18:25 ` [PATCH 4/8] libdrm,intel: Add Android build Emil Velikov
@ 2014-07-27 18:25 ` Emil Velikov
  2014-07-27 18:25 ` [PATCH 6/8] radeon: add Android build support Emil Velikov
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

Contains the following patches squashed in:

    commit 99247a5bd724ddcf0f06a5518baad207c53f1e2b
    Author: Haitao Huang <haitao.huang@intel.com>
    Date: Fri, 27 Apr 2012 13:20:53 -0500

        Android.mk: use LOCAL_COPY_HEADERS to export headers.

        Export necessary header files used by other components for
        Android, such as libva intel-driver, gralloc, hwcomposer, etc.

        Change-Id: I2feabf6941379ef4d756e942f30eba059de641f1
        Signed-off-by: Haitao Huang <haitao.huang@intel.com>
        [chad: Fixed inconsistent indentation.]
        Signed-off-by: Chad Versace <chad.versace@linux.intel.com>

    commit 7d0b528cb69995d7ea4e29b2daa1e3b28a362f42
    Author: Emil Velikov <emil.l.velikov@gmail.com>
    Date: Sun, 27 Jul 2014 18:22:41 +0100

        android: reuse headers lists, separate libdrm from intel headers

        Rather than having a duplicate copy of the headers list(s),
        reuse the existing one(s). Distinguish that the intel headers
        should be copied when libdrm_intel is used.

        Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>

    commit 361de3ba4cadd5357596d1537bb3f216d281532b
    Author: Piotr Luc <piotr.luc@intel.com>
    Date: Fri, 14 Jun 2013 13:00:39 +0200

        Export include dir from libdrm

        BZ: 116218

        Google introduced new method of specifying include path(s)
        between modules. This allows a module to include header from a
        library without directly specifyining by includer the path where
        headers are located.

        The method requires from library that holds headers to export
        include path(s) in LOCAL_EXPORT_C_INCLUDE_DIRS variable.
        These exported include path(s) are automatically added to
        include path(s) of modules that have name of the library in the
        LOCAL_SHARED_LIBRARIES or LOCAL_STATIC_LIBRARIES list.

        This change sets LOCAL_EXPORT_C_INCLUDE_DIRS to folders that
        contain headers file that used by other modules in order to
        export these paths.

        Change-Id: Id1ac885b31ef2efe194e0289fbcaecd9eb533df0
        Signed-off-by: Piotr Luc <piotr.luc@intel.com>
        Reviewed-on: http://android.intel.com:8080/113562
        Reviewed-by: cactus <cactus@intel.com>
        Reviewed-by: Luc, Piotr <Piotr.Luc@intel.com>
        Reviewed-by: Purushothaman, Vijay A <vijay.a.purushothaman@intel.com>
        Reviewed-by: Stimson, Dale B <dale.b.stimson@intel.com>
        Tested-by: Stimson, Dale B <dale.b.stimson@intel.com>
        Reviewed-by: buildbot <buildbot@intel.com>
        Tested-by: buildbot <buildbot@intel.com>

    commit 2bf22fcbd4cbb9e7c7764d5eff0bb4e75ab1a005
    Author: Emil Velikov <emil.l.velikov@gmail.com>
    Date: 27 Jul 2014 18:27:21 +0100

        android: Separate libdrm and intel LOCAL_EXPORT_C_INCLUDE_DIRS

        Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk       | 13 ++++++++++++-
 intel/Android.mk |  5 +++++
 2 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/Android.mk b/Android.mk
index afe59ce..ec340b4 100644
--- a/Android.mk
+++ b/Android.mk
@@ -1,5 +1,5 @@
 #
-# Copyright © 2011 Intel Corporation
+# Copyright © 2011-2012 Intel Corporation
 #
 # Permission is hereby granted, free of charge, to any person obtaining a
 # copy of this software and associated documentation files (the "Software"),
@@ -28,11 +28,16 @@ LIBDRM_TOP := $(LOCAL_PATH)
 
 # Import variables LIBDRM_FILES, LIBDRM_HEADERS
 include $(LOCAL_PATH)/Makefile.sources
+# Import variables LIBDRM_INCLUDE_HEADERS, LIBDRM_INCLUDE_VMWGFX_HEADERS
+include $(LOCAL_PATH)/include/drm/Makefile.sources
 
 LOCAL_MODULE := libdrm
 LOCAL_MODULE_TAGS := optional
 
 LOCAL_SRC_FILES := $(LIBDRM_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH) \
+	$(LOCAL_PATH)/include/drm
 
 LOCAL_C_INCLUDES := \
 	$(LIBDRM_TOP)/include/drm
@@ -40,6 +45,12 @@ LOCAL_C_INCLUDES := \
 LOCAL_CFLAGS := \
 	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
 
+LOCAL_COPY_HEADERS := \
+	$(LIBDRM_HEADERS) \
+	$(addprefix include/drm/,$(LIBDRM_INCLUDE_HEADERS)) \
+	$(addprefix include/drm/,$(LIBDRM_INCLUDE_VMWGFX_HEADERS))
+
+LOCAL_COPY_HEADERS_TO := libdrm
 include $(BUILD_SHARED_LIBRARY)
 
 include $(LOCAL_PATH)/intel/Android.mk
diff --git a/intel/Android.mk b/intel/Android.mk
index 5c48a95..8f6d6e3 100644
--- a/intel/Android.mk
+++ b/intel/Android.mk
@@ -33,6 +33,8 @@ LOCAL_MODULE_TAGS := optional
 LOCAL_SHARED_LIBRARIES := libdrm
 
 LOCAL_SRC_FILES := $(LIBDRM_INTEL_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/intel
 
 LOCAL_C_INCLUDES := \
 	$(LIBDRM_TOP) \
@@ -43,6 +45,9 @@ LOCAL_C_INCLUDES := \
 LOCAL_CFLAGS := \
 	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
 
+LOCAL_COPY_HEADERS := $(LIBDRM_INTEL_HEADERS)
+LOCAL_COPY_HEADERS_TO := libdrm
+
 LOCAL_SHARED_LIBRARIES := \
 	libdrm \
 	libpciaccess
-- 
2.0.2

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

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 6/8] radeon: add Android build support
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
                   ` (4 preceding siblings ...)
  2014-07-27 18:25 ` [PATCH 5/8] libdrm,intel: rework android header handling Emil Velikov
@ 2014-07-27 18:25 ` Emil Velikov
  2014-07-27 18:25 ` [PATCH 7/8] nouveau: " Emil Velikov
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk        |  1 +
 radeon/Android.mk | 30 ++++++++++++++++++++++++++++++
 2 files changed, 31 insertions(+)
 create mode 100644 radeon/Android.mk

diff --git a/Android.mk b/Android.mk
index ec340b4..b3fbb5b 100644
--- a/Android.mk
+++ b/Android.mk
@@ -54,3 +54,4 @@ LOCAL_COPY_HEADERS_TO := libdrm
 include $(BUILD_SHARED_LIBRARY)
 
 include $(LOCAL_PATH)/intel/Android.mk
+include $(LOCAL_PATH)/radeon/Android.mk
diff --git a/radeon/Android.mk b/radeon/Android.mk
new file mode 100644
index 0000000..8c267df
--- /dev/null
+++ b/radeon/Android.mk
@@ -0,0 +1,30 @@
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_RADEON_FILES, LIBDRM_RADEON_HEADERS
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_radeon
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_RADEON_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/radeon
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/radeon \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_COPY_HEADERS := $(LIBDRM_RADEON_HEADERS)
+LOCAL_COPY_HEADERS_TO := libdrm
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 7/8] nouveau: add Android build support
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
                   ` (5 preceding siblings ...)
  2014-07-27 18:25 ` [PATCH 6/8] radeon: add Android build support Emil Velikov
@ 2014-07-27 18:25 ` Emil Velikov
  2014-07-27 18:25 ` [PATCH 8/8] freedreno: " Emil Velikov
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk         |  1 +
 nouveau/Android.mk | 30 ++++++++++++++++++++++++++++++
 2 files changed, 31 insertions(+)
 create mode 100644 nouveau/Android.mk

diff --git a/Android.mk b/Android.mk
index b3fbb5b..eb54bf7 100644
--- a/Android.mk
+++ b/Android.mk
@@ -54,4 +54,5 @@ LOCAL_COPY_HEADERS_TO := libdrm
 include $(BUILD_SHARED_LIBRARY)
 
 include $(LOCAL_PATH)/intel/Android.mk
+include $(LOCAL_PATH)/nouveau/Android.mk
 include $(LOCAL_PATH)/radeon/Android.mk
diff --git a/nouveau/Android.mk b/nouveau/Android.mk
new file mode 100644
index 0000000..28350bd
--- /dev/null
+++ b/nouveau/Android.mk
@@ -0,0 +1,30 @@
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_NOUVEAU_FILES, LIBDRM_NOUVEAU_HEADERS
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_nouveau
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_NOUVEAU_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/nouveau
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/nouveau \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_COPY_HEADERS := $(LIBDRM_NOUVEAU_HEADERS)
+LOCAL_COPY_HEADERS_TO := libdrm
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 8/8] freedreno: add Android build support
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
                   ` (6 preceding siblings ...)
  2014-07-27 18:25 ` [PATCH 7/8] nouveau: " Emil Velikov
@ 2014-07-27 18:25 ` Emil Velikov
  2014-07-28  2:48 ` [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
  9 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-27 18:25 UTC (permalink / raw)
  To: dri-devel; +Cc: freedreno, emil.l.velikov

Cc: freedreno@lists.freedesktop.org
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk           |  1 +
 freedreno/Android.mk | 30 ++++++++++++++++++++++++++++++
 2 files changed, 31 insertions(+)
 create mode 100644 freedreno/Android.mk

diff --git a/Android.mk b/Android.mk
index eb54bf7..b3bf411 100644
--- a/Android.mk
+++ b/Android.mk
@@ -53,6 +53,7 @@ LOCAL_COPY_HEADERS := \
 LOCAL_COPY_HEADERS_TO := libdrm
 include $(BUILD_SHARED_LIBRARY)
 
+include $(LOCAL_PATH)/freedreno/Android.mk
 include $(LOCAL_PATH)/intel/Android.mk
 include $(LOCAL_PATH)/nouveau/Android.mk
 include $(LOCAL_PATH)/radeon/Android.mk
diff --git a/freedreno/Android.mk b/freedreno/Android.mk
new file mode 100644
index 0000000..e91b623
--- /dev/null
+++ b/freedreno/Android.mk
@@ -0,0 +1,30 @@
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_FREEDRENO_FILES, LIBDRM_FREEDRENO_HEADERS
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_freedreno
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_FREEDRENO_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/freedreno
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/freedreno \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_COPY_HEADERS := $(LIBDRM_FREEDRENO_HEADERS)
+LOCAL_COPY_HEADERS_TO := libdrm
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCH 0/8] Upstreaming the Android build and misc fixes
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
                   ` (7 preceding siblings ...)
  2014-07-27 18:25 ` [PATCH 8/8] freedreno: " Emil Velikov
@ 2014-07-28  2:48 ` Emil Velikov
  2014-07-28  7:07   ` Daniel Vetter
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
  9 siblings, 1 reply; 31+ messages in thread
From: Emil Velikov @ 2014-07-28  2:48 UTC (permalink / raw)
  To: dri-devel@lists.freedesktop.org; +Cc: emil.l.velikov

A few updates:

 - Naming the headers lists *_HEADERS caused autohell to hate us. Renamed to
*_H_FILES
 - Including the platform Android.mk files individually is not the right way
to do. One needs to construct an array/list of Android.mks and include it.

 - The series including the above fixes can be found in branch fixes+android
over at https://github.com/evelikov/libdrm.

-Emil

On 27/07/14 19:25, Emil Velikov wrote:
> Hello list,
> 
> Recently I've had a go at the Anroid builds and I felt ... inspired that
> there are (at least) two downstream repositories that have the relevant
> Android build, yet all of them use 6+month old libdrm.
> Making even builds a pain in the neck :'(
> 
> Are there any objections if we get the android build upstream ? AFAICS 
> it's nicely isolated from everything else + I've managed to reuse all 
> the source/headers lists.
> 
> Note that the series lacks a couple of patches from the downstream 
> repos, yet adds support for radeon, nouveau and freedreno :)
> 
> The missing fixes are - s/mmap/mmap64/, dma-bufs support + other intel 
> specific "hacks". If people are happy with the series then we can take
> a look at the final bits.
> 
> 
> Cheers,
> Emil
> 

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH 0/8] Upstreaming the Android build and misc fixes
  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
  0 siblings, 1 reply; 31+ messages in thread
From: Daniel Vetter @ 2014-07-28  7:07 UTC (permalink / raw)
  To: Emil Velikov, Gore, Tim; +Cc: dri-devel@lists.freedesktop.org

On Mon, Jul 28, 2014 at 03:48:53AM +0100, Emil Velikov wrote:
> A few updates:
>
>  - Naming the headers lists *_HEADERS caused autohell to hate us. Renamed to
> *_H_FILES
>  - Including the platform Android.mk files individually is not the right way
> to do. One needs to construct an array/list of Android.mks and include it.
>
>  - The series including the above fixes can be found in branch fixes+android
> over at https://github.com/evelikov/libdrm.

Adding Tim Gore who's working on Android.mk support for i-g-t from our
side and probably knows whom to poke for the intel side of things for
libdrm Android ports.
-Daniel

>
> -Emil
>
> On 27/07/14 19:25, Emil Velikov wrote:
> > Hello list,
> >
> > Recently I've had a go at the Anroid builds and I felt ... inspired that
> > there are (at least) two downstream repositories that have the relevant
> > Android build, yet all of them use 6+month old libdrm.
> > Making even builds a pain in the neck :'(
> >
> > Are there any objections if we get the android build upstream ? AFAICS
> > it's nicely isolated from everything else + I've managed to reuse all
> > the source/headers lists.
> >
> > Note that the series lacks a couple of patches from the downstream
> > repos, yet adds support for radeon, nouveau and freedreno :)
> >
> > The missing fixes are - s/mmap/mmap64/, dma-bufs support + other intel
> > specific "hacks". If people are happy with the series then we can take
> > a look at the final bits.
> >
> >
> > Cheers,
> > Emil
> >
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH 0/8] Upstreaming the Android build and misc fixes
  2014-07-28  7:07   ` Daniel Vetter
@ 2014-07-28 12:01     ` Emil Velikov
  2014-07-28 15:22       ` Daniel Vetter
  0 siblings, 1 reply; 31+ messages in thread
From: Emil Velikov @ 2014-07-28 12:01 UTC (permalink / raw)
  To: Daniel Vetter, Gore, Tim; +Cc: emil.l.velikov, dri-devel@lists.freedesktop.org

On 28/07/14 08:07, Daniel Vetter wrote:
> On Mon, Jul 28, 2014 at 03:48:53AM +0100, Emil Velikov wrote:
>> A few updates:
>>
>>  - Naming the headers lists *_HEADERS caused autohell to hate us. Renamed to
>> *_H_FILES
>>  - Including the platform Android.mk files individually is not the right way
>> to do. One needs to construct an array/list of Android.mks and include it.
>>
>>  - The series including the above fixes can be found in branch fixes+android
>> over at https://github.com/evelikov/libdrm.
> 
> Adding Tim Gore who's working on Android.mk support for i-g-t from our
> side and probably knows whom to poke for the intel side of things for
> libdrm Android ports.
> -Daniel
> 
Thank you Daniel,

In case it was not clear enough, some of these patches are taken from
android-ia/external/drm. The very same are written by Intel employees AFAICT
:) Would be great to hear if anyone is against the idea of getting Android.mks
in the canonical repo.


-Emil

>>
>> -Emil
>>
>> On 27/07/14 19:25, Emil Velikov wrote:
>>> Hello list,
>>>
>>> Recently I've had a go at the Anroid builds and I felt ... inspired that
>>> there are (at least) two downstream repositories that have the relevant
>>> Android build, yet all of them use 6+month old libdrm.
>>> Making even builds a pain in the neck :'(
>>>
>>> Are there any objections if we get the android build upstream ? AFAICS
>>> it's nicely isolated from everything else + I've managed to reuse all
>>> the source/headers lists.
>>>
>>> Note that the series lacks a couple of patches from the downstream
>>> repos, yet adds support for radeon, nouveau and freedreno :)
>>>
>>> The missing fixes are - s/mmap/mmap64/, dma-bufs support + other intel
>>> specific "hacks". If people are happy with the series then we can take
>>> a look at the final bits.
>>>
>>>
>>> Cheers,
>>> Emil
>>>
>>
>> _______________________________________________
>> dri-devel mailing list
>> dri-devel@lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/dri-devel
> 

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH 0/8] Upstreaming the Android build and misc fixes
  2014-07-28 12:01     ` Emil Velikov
@ 2014-07-28 15:22       ` Daniel Vetter
  2014-07-29 16:14         ` Gore, Tim
  0 siblings, 1 reply; 31+ messages in thread
From: Daniel Vetter @ 2014-07-28 15:22 UTC (permalink / raw)
  To: Emil Velikov; +Cc: dri-devel@lists.freedesktop.org

On Mon, Jul 28, 2014 at 01:01:19PM +0100, Emil Velikov wrote:
> On 28/07/14 08:07, Daniel Vetter wrote:
> > On Mon, Jul 28, 2014 at 03:48:53AM +0100, Emil Velikov wrote:
> >> A few updates:
> >>
> >>  - Naming the headers lists *_HEADERS caused autohell to hate us. Renamed to
> >> *_H_FILES
> >>  - Including the platform Android.mk files individually is not the right way
> >> to do. One needs to construct an array/list of Android.mks and include it.
> >>
> >>  - The series including the above fixes can be found in branch fixes+android
> >> over at https://github.com/evelikov/libdrm.
> > 
> > Adding Tim Gore who's working on Android.mk support for i-g-t from our
> > side and probably knows whom to poke for the intel side of things for
> > libdrm Android ports.
> > -Daniel
> > 
> Thank you Daniel,
> 
> In case it was not clear enough, some of these patches are taken from
> android-ia/external/drm. The very same are written by Intel employees AFAICT
> :) Would be great to hear if anyone is against the idea of getting Android.mks
> in the canonical repo.

Oh, that's kinda why I want to drag the relevant people in from Intel's
side. Responsibility for Android builds have shifted around a bit the past
few years and Intel is big, so I'm trying to get hold off the right
person. No success thus far :(

But personally I want this, just need to make sure that our own Android
guys see it and can start to help out. Occasionally it takes a while until
they dare to walk out of their hidings ;-)
-Daniel
> 
> 
> -Emil
> 
> >>
> >> -Emil
> >>
> >> On 27/07/14 19:25, Emil Velikov wrote:
> >>> Hello list,
> >>>
> >>> Recently I've had a go at the Anroid builds and I felt ... inspired that
> >>> there are (at least) two downstream repositories that have the relevant
> >>> Android build, yet all of them use 6+month old libdrm.
> >>> Making even builds a pain in the neck :'(
> >>>
> >>> Are there any objections if we get the android build upstream ? AFAICS
> >>> it's nicely isolated from everything else + I've managed to reuse all
> >>> the source/headers lists.
> >>>
> >>> Note that the series lacks a couple of patches from the downstream
> >>> repos, yet adds support for radeon, nouveau and freedreno :)
> >>>
> >>> The missing fixes are - s/mmap/mmap64/, dma-bufs support + other intel
> >>> specific "hacks". If people are happy with the series then we can take
> >>> a look at the final bits.
> >>>
> >>>
> >>> Cheers,
> >>> Emil
> >>>
> >>
> >> _______________________________________________
> >> dri-devel mailing list
> >> dri-devel@lists.freedesktop.org
> >> http://lists.freedesktop.org/mailman/listinfo/dri-devel
> > 
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 31+ messages in thread

* RE: [PATCH 0/8] Upstreaming the Android build and misc fixes
  2014-07-28 15:22       ` Daniel Vetter
@ 2014-07-29 16:14         ` Gore, Tim
  2014-07-29 17:10           ` Emil Velikov
  0 siblings, 1 reply; 31+ messages in thread
From: Gore, Tim @ 2014-07-29 16:14 UTC (permalink / raw)
  To: Daniel Vetter, Emil Velikov; +Cc: dri-devel@lists.freedesktop.org



> -----Original Message-----
> From: Daniel Vetter [mailto:daniel.vetter@ffwll.ch] On Behalf Of Daniel
> Vetter
> Sent: Monday, July 28, 2014 4:22 PM
> To: Emil Velikov
> Cc: Daniel Vetter; Gore, Tim; dri-devel@lists.freedesktop.org
> Subject: Re: [PATCH 0/8] Upstreaming the Android build and misc fixes
> 
> On Mon, Jul 28, 2014 at 01:01:19PM +0100, Emil Velikov wrote:
> > On 28/07/14 08:07, Daniel Vetter wrote:
> > > On Mon, Jul 28, 2014 at 03:48:53AM +0100, Emil Velikov wrote:
> > >> A few updates:
> > >>
> > >>  - Naming the headers lists *_HEADERS caused autohell to hate us.
> > >> Renamed to *_H_FILES
> > >>  - Including the platform Android.mk files individually is not the
> > >> right way to do. One needs to construct an array/list of Android.mks and
> include it.
> > >>
> > >>  - The series including the above fixes can be found in branch
> > >> fixes+android over at https://github.com/evelikov/libdrm.
> > >
> > > Adding Tim Gore who's working on Android.mk support for i-g-t from
> > > our side and probably knows whom to poke for the intel side of
> > > things for libdrm Android ports.
> > > -Daniel
> > >
> > Thank you Daniel,
> >
> > In case it was not clear enough, some of these patches are taken from
> > android-ia/external/drm. The very same are written by Intel employees
> > AFAICT
> > :) Would be great to hear if anyone is against the idea of getting
> > Android.mks in the canonical repo.
> 
> Oh, that's kinda why I want to drag the relevant people in from Intel's side.
> Responsibility for Android builds have shifted around a bit the past few years
> and Intel is big, so I'm trying to get hold off the right person. No success thus
> far :(
> 
> But personally I want this, just need to make sure that our own Android guys
> see it and can start to help out. Occasionally it takes a while until they dare to
> walk out of their hidings ;-) -Daniel

On the whole these look fine. Jon Bloomfield seemed happy with the overall idea.
 3 comments.
   1)  Patch 3 didn't apply cleanly, I assume because it
        was based on a different branch (ie not master), but the difference was trivial.
  2) The Android makefiles as they are will not build within the android tree. I am
       Trying to get them to work at the moment.
  3) Depending on which Android tree you have, the resulting libdrm may or may not
       Work in there. I don't think the latest intel android tree is compatible with the
      Upstream libdrm.

   Tim

> >
> >
> > -Emil
> >
> > >>
> > >> -Emil
> > >>
> > >> On 27/07/14 19:25, Emil Velikov wrote:
> > >>> Hello list,
> > >>>
> > >>> Recently I've had a go at the Anroid builds and I felt ...
> > >>> inspired that there are (at least) two downstream repositories
> > >>> that have the relevant Android build, yet all of them use 6+month old
> libdrm.
> > >>> Making even builds a pain in the neck :'(
> > >>>
> > >>> Are there any objections if we get the android build upstream ?
> > >>> AFAICS it's nicely isolated from everything else + I've managed to
> > >>> reuse all the source/headers lists.
> > >>>
> > >>> Note that the series lacks a couple of patches from the downstream
> > >>> repos, yet adds support for radeon, nouveau and freedreno :)
> > >>>
> > >>> The missing fixes are - s/mmap/mmap64/, dma-bufs support + other
> > >>> intel specific "hacks". If people are happy with the series then
> > >>> we can take a look at the final bits.
> > >>>
> > >>>
> > >>> Cheers,
> > >>> Emil
> > >>>
> > >>
> > >> _______________________________________________
> > >> dri-devel mailing list
> > >> dri-devel@lists.freedesktop.org
> > >> http://lists.freedesktop.org/mailman/listinfo/dri-devel
> > >
> >
> 
> --
> Daniel Vetter
> Software Engineer, Intel Corporation
> +41 (0) 79 365 57 48 - http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 31+ messages in thread

* RE: [PATCH 0/8] Upstreaming the Android build and misc fixes
@ 2014-07-29 16:43 Gore, Tim
  0 siblings, 0 replies; 31+ messages in thread
From: Gore, Tim @ 2014-07-29 16:43 UTC (permalink / raw)
  To: Emil Velikov (emil.l.velikov@gmail.com); +Cc: dri-devel@lists.freedesktop.org

Hi Emil, these seemed to work ok, with two fixes.

1) Patch 3 didn't apply cleanly to the master branch due to a difference in the
Author email address for  a couple of files.

2) The Android.mk at the top level, at the end where you include the sub makefiles,
You need to use  LIBDRM_TOP instead of LOCAL_PATH. (Patches 4,6,7,8) So 

include $(LOCAL_PATH)/.....

Becomes

include $(LIBDRM_TOP)/....

this is because the included Android.mk files modify LOCAL_PATH

  TIm

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH 0/8] Upstreaming the Android build and misc fixes
  2014-07-29 16:14         ` Gore, Tim
@ 2014-07-29 17:10           ` Emil Velikov
  0 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:10 UTC (permalink / raw)
  To: Gore, Tim, Daniel Vetter; +Cc: emil.l.velikov, dri-devel@lists.freedesktop.org

On 29/07/14 17:14, Gore, Tim wrote:
> 
> 
>> -----Original Message-----
>> From: Daniel Vetter [mailto:daniel.vetter@ffwll.ch] On Behalf Of Daniel
>> Vetter
>> Sent: Monday, July 28, 2014 4:22 PM
>> To: Emil Velikov
>> Cc: Daniel Vetter; Gore, Tim; dri-devel@lists.freedesktop.org
>> Subject: Re: [PATCH 0/8] Upstreaming the Android build and misc fixes
>>
>> On Mon, Jul 28, 2014 at 01:01:19PM +0100, Emil Velikov wrote:
>>> On 28/07/14 08:07, Daniel Vetter wrote:
>>>> On Mon, Jul 28, 2014 at 03:48:53AM +0100, Emil Velikov wrote:
>>>>> A few updates:
>>>>>
>>>>>  - Naming the headers lists *_HEADERS caused autohell to hate us.
>>>>> Renamed to *_H_FILES
>>>>>  - Including the platform Android.mk files individually is not the
>>>>> right way to do. One needs to construct an array/list of Android.mks and
>> include it.
>>>>>
>>>>>  - The series including the above fixes can be found in branch
>>>>> fixes+android over at https://github.com/evelikov/libdrm.
>>>>
>>>> Adding Tim Gore who's working on Android.mk support for i-g-t from
>>>> our side and probably knows whom to poke for the intel side of
>>>> things for libdrm Android ports.
>>>> -Daniel
>>>>
>>> Thank you Daniel,
>>>
>>> In case it was not clear enough, some of these patches are taken from
>>> android-ia/external/drm. The very same are written by Intel employees
>>> AFAICT
>>> :) Would be great to hear if anyone is against the idea of getting
>>> Android.mks in the canonical repo.
>>
>> Oh, that's kinda why I want to drag the relevant people in from Intel's side.
>> Responsibility for Android builds have shifted around a bit the past few years
>> and Intel is big, so I'm trying to get hold off the right person. No success thus
>> far :(
>>
>> But personally I want this, just need to make sure that our own Android guys
>> see it and can start to help out. Occasionally it takes a while until they dare to
>> walk out of their hidings ;-) -Daniel
> 
> On the whole these look fine. Jon Bloomfield seemed happy with the overall idea.
>  3 comments.
>    1)  Patch 3 didn't apply cleanly, I assume because it
>         was based on a different branch (ie not master), but the difference was trivial.
>   2) The Android makefiles as they are will not build within the android tree. I am
>        Trying to get them to work at the moment.
The Android issue you've mentioned in the other email is fixed in the branch
mentioned above + I have squashed additional fixes over at fixes+android-v2 in
https://github.com/evelikov/libdrm. Will post these in just a moment.

>   3) Depending on which Android tree you have, the resulting libdrm may or may not
>        Work in there. I don't think the latest intel android tree is compatible with the
>       Upstream libdrm.
> 
Not sure what is the exact meaning of "compatible" is in this case. IMHO Intel
(if interested) can easily rebase their repo on top of upstream (as these
land) thus keep a smaller (if any) delta and ease development :)

-Emil

P.S. Who is Jon Bloomfield ?

>    Tim
> 
>>>
>>>
>>> -Emil
>>>
>>>>>
>>>>> -Emil
>>>>>
>>>>> On 27/07/14 19:25, Emil Velikov wrote:
>>>>>> Hello list,
>>>>>>
>>>>>> Recently I've had a go at the Anroid builds and I felt ...
>>>>>> inspired that there are (at least) two downstream repositories
>>>>>> that have the relevant Android build, yet all of them use 6+month old
>> libdrm.
>>>>>> Making even builds a pain in the neck :'(
>>>>>>
>>>>>> Are there any objections if we get the android build upstream ?
>>>>>> AFAICS it's nicely isolated from everything else + I've managed to
>>>>>> reuse all the source/headers lists.
>>>>>>
>>>>>> Note that the series lacks a couple of patches from the downstream
>>>>>> repos, yet adds support for radeon, nouveau and freedreno :)
>>>>>>
>>>>>> The missing fixes are - s/mmap/mmap64/, dma-bufs support + other
>>>>>> intel specific "hacks". If people are happy with the series then
>>>>>> we can take a look at the final bits.
>>>>>>
>>>>>>
>>>>>> Cheers,
>>>>>> Emil
>>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> dri-devel mailing list
>>>>> dri-devel@lists.freedesktop.org
>>>>> http://lists.freedesktop.org/mailman/listinfo/dri-devel
>>>>
>>>
>>
>> --
>> Daniel Vetter
>> Software Engineer, Intel Corporation
>> +41 (0) 79 365 57 48 - http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 31+ messages in thread

* [PATCHv2 0/8] Upstreaming the Android build and misc fixes
  2014-07-27 18:25 [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
                   ` (8 preceding siblings ...)
  2014-07-28  2:48 ` [PATCH 0/8] Upstreaming the Android build and misc fixes Emil Velikov
@ 2014-07-29 17:27 ` Emil Velikov
  2014-07-29 17:27   ` [PATCH 1/8] all: include config.h only when available and use its defines Emil Velikov
                     ` (8 more replies)
  9 siblings, 9 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel

Changes since the orignal posting:
 - Rebased on top of master.
 - Used _H_FILES for header lists (_HEADERS is a no-go with autotools)
 - Install the freedreno headers to {include_dir}/freedreno, similar to
the automake builds.
 - Correctly include $(hw)/Android.mk

The series is also available at the fixes+android-v2 branch in
https://github.com/evelikov/libdrm.

-Emil

^ permalink raw reply	[flat|nested] 31+ messages in thread

* [PATCH 1/8] all: include config.h only when available and use its defines
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
@ 2014-07-29 17:27   ` Emil Velikov
  2014-07-29 17:27   ` [PATCH 2/8] libkms: remove explicit define _FILE_OFFSET_BITS 64 Emil Velikov
                     ` (7 subsequent siblings)
  8 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

... rather than explicitly redefining HAVE_STDINT_H and _GNU_SOURCE.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 intel/test_decode.c       | 5 +++--
 libkms/api.c              | 2 ++
 libkms/dumb.c             | 4 +++-
 libkms/exynos.c           | 4 +++-
 libkms/intel.c            | 4 +++-
 libkms/linux.c            | 2 ++
 libkms/nouveau.c          | 4 +++-
 libkms/radeon.c           | 4 +++-
 libkms/vmwgfx.c           | 4 +++-
 tests/drmstat.c           | 2 ++
 tests/modetest/buffers.c  | 2 ++
 tests/modetest/cursor.c   | 2 ++
 tests/modetest/modetest.c | 2 ++
 tests/vbltest/vbltest.c   | 2 ++
 14 files changed, 35 insertions(+), 8 deletions(-)

diff --git a/intel/test_decode.c b/intel/test_decode.c
index b710f34..bef9d99 100644
--- a/intel/test_decode.c
+++ b/intel/test_decode.c
@@ -21,7 +21,9 @@
  * IN THE SOFTWARE.
  */
 
-#define _GNU_SOURCE
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 
 #include <string.h>
 #include <stdlib.h>
@@ -33,7 +35,6 @@
 #include <sys/mman.h>
 #include <err.h>
 
-#include "config.h"
 #include "intel_bufmgr.h"
 #include "intel_chipset.h"
 
diff --git a/libkms/api.c b/libkms/api.c
index 5befaa0..b512c42 100644
--- a/libkms/api.c
+++ b/libkms/api.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 #include <errno.h>
 #include <stdlib.h>
 #include <string.h>
diff --git a/libkms/dumb.c b/libkms/dumb.c
index 440efb3..794282f 100644
--- a/libkms/dumb.c
+++ b/libkms/dumb.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/exynos.c b/libkms/exynos.c
index 93e36a1..243915b 100644
--- a/libkms/exynos.c
+++ b/libkms/exynos.c
@@ -11,7 +11,9 @@
  * option) any later version.
  */
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/intel.c b/libkms/intel.c
index abae452..92f1cf2 100644
--- a/libkms/intel.c
+++ b/libkms/intel.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/linux.c b/libkms/linux.c
index 9b4f29e..17e1d58 100644
--- a/libkms/linux.c
+++ b/libkms/linux.c
@@ -30,7 +30,9 @@
  */
 
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 #include <errno.h>
 #include <stdio.h>
 #include <stdlib.h>
diff --git a/libkms/nouveau.c b/libkms/nouveau.c
index 608092f..2de827d 100644
--- a/libkms/nouveau.c
+++ b/libkms/nouveau.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/radeon.c b/libkms/radeon.c
index f5e382a..29375c4 100644
--- a/libkms/radeon.c
+++ b/libkms/radeon.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/libkms/vmwgfx.c b/libkms/vmwgfx.c
index d594b3b..598f383 100644
--- a/libkms/vmwgfx.c
+++ b/libkms/vmwgfx.c
@@ -26,7 +26,9 @@
  **************************************************************************/
 
 
-#define HAVE_STDINT_H
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
 #define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
diff --git a/tests/drmstat.c b/tests/drmstat.c
index c51cbc6..5935d07 100644
--- a/tests/drmstat.c
+++ b/tests/drmstat.c
@@ -28,7 +28,9 @@
  * 
  */
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <stdio.h>
 #include <stdlib.h>
diff --git a/tests/modetest/buffers.c b/tests/modetest/buffers.c
index 8206ce3..29b520d 100644
--- a/tests/modetest/buffers.c
+++ b/tests/modetest/buffers.c
@@ -24,7 +24,9 @@
  * IN THE SOFTWARE.
  */
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <errno.h>
diff --git a/tests/modetest/cursor.c b/tests/modetest/cursor.c
index 7077f20..60f240a 100644
--- a/tests/modetest/cursor.c
+++ b/tests/modetest/cursor.c
@@ -22,7 +22,9 @@
  * IN THE SOFTWARE.
  */
 
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <errno.h>
diff --git a/tests/modetest/modetest.c b/tests/modetest/modetest.c
index 7d436b5..92efb82 100644
--- a/tests/modetest/modetest.c
+++ b/tests/modetest/modetest.c
@@ -37,7 +37,9 @@
  * TODO: use cairo to write the mode info on the selected output once
  *       the mode has been programmed, along with possible test patterns.
  */
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <ctype.h>
diff --git a/tests/vbltest/vbltest.c b/tests/vbltest/vbltest.c
index 2a09d28..50e29dc 100644
--- a/tests/vbltest/vbltest.c
+++ b/tests/vbltest/vbltest.c
@@ -37,7 +37,9 @@
  * TODO: use cairo to write the mode info on the selected output once
  *       the mode has been programmed, along with possible test patterns.
  */
+#ifdef HAVE_CONFIG_H
 #include "config.h"
+#endif
 
 #include <assert.h>
 #include <stdio.h>
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 2/8] libkms: remove explicit define _FILE_OFFSET_BITS 64
  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   ` Emil Velikov
  2014-07-29 17:27   ` [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
                     ` (6 subsequent siblings)
  8 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

configure.ac has AC_SYS_LARGEFILE which provides the define and/or
approapriate magic when required.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 libkms/dumb.c    | 1 -
 libkms/exynos.c  | 1 -
 libkms/intel.c   | 1 -
 libkms/nouveau.c | 1 -
 libkms/radeon.c  | 1 -
 libkms/vmwgfx.c  | 1 -
 6 files changed, 6 deletions(-)

diff --git a/libkms/dumb.c b/libkms/dumb.c
index 794282f..5702543 100644
--- a/libkms/dumb.c
+++ b/libkms/dumb.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/exynos.c b/libkms/exynos.c
index 243915b..92e329c 100644
--- a/libkms/exynos.c
+++ b/libkms/exynos.c
@@ -14,7 +14,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/intel.c b/libkms/intel.c
index 92f1cf2..b006ea4 100644
--- a/libkms/intel.c
+++ b/libkms/intel.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/nouveau.c b/libkms/nouveau.c
index 2de827d..15c012e 100644
--- a/libkms/nouveau.c
+++ b/libkms/nouveau.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/radeon.c b/libkms/radeon.c
index 29375c4..938321b 100644
--- a/libkms/radeon.c
+++ b/libkms/radeon.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdio.h>
diff --git a/libkms/vmwgfx.c b/libkms/vmwgfx.c
index 598f383..08163a1 100644
--- a/libkms/vmwgfx.c
+++ b/libkms/vmwgfx.c
@@ -29,7 +29,6 @@
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
-#define _FILE_OFFSET_BITS 64
 
 #include <errno.h>
 #include <stdlib.h>
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources
  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
  2014-08-24 18:28     ` [PATCHv3 " Emil Velikov
  2014-07-29 17:27   ` [PATCH 4/8] libdrm,intel: Add Android build Emil Velikov
                     ` (5 subsequent siblings)
  8 siblings, 1 reply; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

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

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 4/8] libdrm,intel: Add Android build
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
                     ` (2 preceding siblings ...)
  2014-07-29 17:27   ` [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
@ 2014-07-29 17:27   ` Emil Velikov
  2014-07-29 17:27   ` [PATCH 5/8] libdrm,intel: rework android header handling Emil Velikov
                     ` (4 subsequent siblings)
  8 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

Contains the following patches squashed in:

    commit f340a8b9f2b84d5762553bef046914e0bde20795
    Author: Chad Versace <chad.versace@linux.intel.com>
    Date: Wed, 21 Dec 2011 11:43:57 -0800

        libdrm,intel: Add Android makefiles (v2)

        This enables libdrm.so and libdrm_intel.so to build on Android
        IceCreamSandwich.

        v2: Link libdrm_intel to libpciaccess.

        Change-Id: Ie5ed4bc0e6b4f9f819e3ec44488e385c35e97128
        Signed-off-by: Chad Versace <chad.versace@linux.intel.com>

    commit 8fb3f42389dea34218ed1fe59550ec2abb4d6953
    Author: Andrew Boie <andrew.p.boie@intel.com>
    Date: Wed, 26 Sep 2012 13:32:05 -0700

        libdrm, libdrm_intel: Skip driver name checks

        These libraries have 'optional' tags, which means they won't get
        built unless something else depends on them or they are added to
        PRODUCT_PACKAGES. There's no need for additional filtering.

        Change-Id: I5d90969f38671f8144c0dc27d47144b3f09a15ce
        Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
---
 Android.mk       | 45 +++++++++++++++++++++++++++++++++++++++++++++
 intel/Android.mk | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 95 insertions(+)
 create mode 100644 Android.mk
 create mode 100644 intel/Android.mk

diff --git a/Android.mk b/Android.mk
new file mode 100644
index 0000000..afe59ce
--- /dev/null
+++ b/Android.mk
@@ -0,0 +1,45 @@
+#
+# Copyright © 2011 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.
+#
+
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+LIBDRM_TOP := $(LOCAL_PATH)
+
+# Import variables LIBDRM_FILES, LIBDRM_HEADERS
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SRC_FILES := $(LIBDRM_FILES)
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+include $(BUILD_SHARED_LIBRARY)
+
+include $(LOCAL_PATH)/intel/Android.mk
diff --git a/intel/Android.mk b/intel/Android.mk
new file mode 100644
index 0000000..5c48a95
--- /dev/null
+++ b/intel/Android.mk
@@ -0,0 +1,50 @@
+#
+# Copyright © 2011 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.
+#
+
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_INTEL_FILES, LIBDRM_INTEL_HEADERS
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_intel
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_INTEL_FILES)
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/intel \
+	$(LIBDRM_TOP)/include/drm \
+	external/libpciaccess/include
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm \
+	libpciaccess
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

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

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 5/8] libdrm,intel: rework android header handling
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
                     ` (3 preceding siblings ...)
  2014-07-29 17:27   ` [PATCH 4/8] libdrm,intel: Add Android build Emil Velikov
@ 2014-07-29 17:27   ` Emil Velikov
  2014-07-29 17:27   ` [PATCH 6/8] radeon: add Android build support Emil Velikov
                     ` (3 subsequent siblings)
  8 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

Contains the following patches squashed in:

    commit 99247a5bd724ddcf0f06a5518baad207c53f1e2b
    Author: Haitao Huang <haitao.huang@intel.com>
    Date: Fri, 27 Apr 2012 13:20:53 -0500

        Android.mk: use LOCAL_COPY_HEADERS to export headers.

        Export necessary header files used by other components for
        Android, such as libva intel-driver, gralloc, hwcomposer, etc.

        Change-Id: I2feabf6941379ef4d756e942f30eba059de641f1
        Signed-off-by: Haitao Huang <haitao.huang@intel.com>
        [chad: Fixed inconsistent indentation.]
        Signed-off-by: Chad Versace <chad.versace@linux.intel.com>

    commit 7d0b528cb69995d7ea4e29b2daa1e3b28a362f42
    Author: Emil Velikov <emil.l.velikov@gmail.com>
    Date: Sun, 27 Jul 2014 18:22:41 +0100

        android: reuse headers lists, separate libdrm from intel headers

        Rather than having a duplicate copy of the headers list(s),
        reuse the existing one(s). Distinguish that the intel headers
        should be copied when libdrm_intel is used.

        v2 Rename the headers variable(s) to *_H_FILES.

        Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>

    commit 361de3ba4cadd5357596d1537bb3f216d281532b
    Author: Piotr Luc <piotr.luc@intel.com>
    Date: Fri, 14 Jun 2013 13:00:39 +0200

        Export include dir from libdrm

        BZ: 116218

        Google introduced new method of specifying include path(s)
        between modules. This allows a module to include header from a
        library without directly specifyining by includer the path where
        headers are located.

        The method requires from library that holds headers to export
        include path(s) in LOCAL_EXPORT_C_INCLUDE_DIRS variable.
        These exported include path(s) are automatically added to
        include path(s) of modules that have name of the library in the
        LOCAL_SHARED_LIBRARIES or LOCAL_STATIC_LIBRARIES list.

        This change sets LOCAL_EXPORT_C_INCLUDE_DIRS to folders that
        contain headers file that used by other modules in order to
        export these paths.

        Change-Id: Id1ac885b31ef2efe194e0289fbcaecd9eb533df0
        Signed-off-by: Piotr Luc <piotr.luc@intel.com>
        Reviewed-on: http://android.intel.com:8080/113562
        Reviewed-by: cactus <cactus@intel.com>
        Reviewed-by: Luc, Piotr <Piotr.Luc@intel.com>
        Reviewed-by: Purushothaman, Vijay A <vijay.a.purushothaman@intel.com>
        Reviewed-by: Stimson, Dale B <dale.b.stimson@intel.com>
        Tested-by: Stimson, Dale B <dale.b.stimson@intel.com>
        Reviewed-by: buildbot <buildbot@intel.com>
        Tested-by: buildbot <buildbot@intel.com>

    commit 2bf22fcbd4cbb9e7c7764d5eff0bb4e75ab1a005
    Author: Emil Velikov <emil.l.velikov@gmail.com>
    Date: 27 Jul 2014 18:27:21 +0100

        android: Separate libdrm and intel LOCAL_EXPORT_C_INCLUDE_DIRS

        Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk       | 15 +++++++++++++--
 intel/Android.mk |  7 ++++++-
 2 files changed, 19 insertions(+), 3 deletions(-)

diff --git a/Android.mk b/Android.mk
index afe59ce..795e554 100644
--- a/Android.mk
+++ b/Android.mk
@@ -1,5 +1,5 @@
 #
-# Copyright © 2011 Intel Corporation
+# Copyright © 2011-2012 Intel Corporation
 #
 # Permission is hereby granted, free of charge, to any person obtaining a
 # copy of this software and associated documentation files (the "Software"),
@@ -26,13 +26,18 @@ include $(CLEAR_VARS)
 
 LIBDRM_TOP := $(LOCAL_PATH)
 
-# Import variables LIBDRM_FILES, LIBDRM_HEADERS
+# Import variables LIBDRM_FILES, LIBDRM_H_FILES
 include $(LOCAL_PATH)/Makefile.sources
+# Import variables LIBDRM_INCLUDE_H_FILES, LIBDRM_INCLUDE_VMWGFX_H_FILES
+include $(LOCAL_PATH)/include/drm/Makefile.sources
 
 LOCAL_MODULE := libdrm
 LOCAL_MODULE_TAGS := optional
 
 LOCAL_SRC_FILES := $(LIBDRM_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH) \
+	$(LOCAL_PATH)/include/drm
 
 LOCAL_C_INCLUDES := \
 	$(LIBDRM_TOP)/include/drm
@@ -40,6 +45,12 @@ LOCAL_C_INCLUDES := \
 LOCAL_CFLAGS := \
 	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
 
+LOCAL_COPY_HEADERS := \
+	$(LIBDRM_H_FILES) \
+	$(addprefix include/drm/,$(LIBDRM_INCLUDE_H_FILES)) \
+	$(addprefix include/drm/,$(LIBDRM_INCLUDE_VMWGFX_H_FILES))
+
+LOCAL_COPY_HEADERS_TO := libdrm
 include $(BUILD_SHARED_LIBRARY)
 
 include $(LOCAL_PATH)/intel/Android.mk
diff --git a/intel/Android.mk b/intel/Android.mk
index 5c48a95..f2f21b9 100644
--- a/intel/Android.mk
+++ b/intel/Android.mk
@@ -24,7 +24,7 @@
 LOCAL_PATH := $(call my-dir)
 include $(CLEAR_VARS)
 
-# Import variables LIBDRM_INTEL_FILES, LIBDRM_INTEL_HEADERS
+# Import variables LIBDRM_INTEL_FILES, LIBDRM_INTEL_H_FILES
 include $(LOCAL_PATH)/Makefile.sources
 
 LOCAL_MODULE := libdrm_intel
@@ -33,6 +33,8 @@ LOCAL_MODULE_TAGS := optional
 LOCAL_SHARED_LIBRARIES := libdrm
 
 LOCAL_SRC_FILES := $(LIBDRM_INTEL_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/intel
 
 LOCAL_C_INCLUDES := \
 	$(LIBDRM_TOP) \
@@ -43,6 +45,9 @@ LOCAL_C_INCLUDES := \
 LOCAL_CFLAGS := \
 	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
 
+LOCAL_COPY_HEADERS := $(LIBDRM_INTEL_H_FILES)
+LOCAL_COPY_HEADERS_TO := libdrm
+
 LOCAL_SHARED_LIBRARIES := \
 	libdrm \
 	libpciaccess
-- 
2.0.2

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

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 6/8] radeon: add Android build support
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
                     ` (4 preceding siblings ...)
  2014-07-29 17:27   ` [PATCH 5/8] libdrm,intel: rework android header handling Emil Velikov
@ 2014-07-29 17:27   ` Emil Velikov
  2014-07-29 17:27   ` [PATCH 7/8] nouveau: " Emil Velikov
                     ` (2 subsequent siblings)
  8 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

v2 Rename the headers variable(s) to *_H_FILES.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk        |  7 ++++++-
 radeon/Android.mk | 30 ++++++++++++++++++++++++++++++
 2 files changed, 36 insertions(+), 1 deletion(-)
 create mode 100644 radeon/Android.mk

diff --git a/Android.mk b/Android.mk
index 795e554..3f43625 100644
--- a/Android.mk
+++ b/Android.mk
@@ -53,4 +53,9 @@ LOCAL_COPY_HEADERS := \
 LOCAL_COPY_HEADERS_TO := libdrm
 include $(BUILD_SHARED_LIBRARY)
 
-include $(LOCAL_PATH)/intel/Android.mk
+SUBDIRS := \
+	intel \
+	radeon
+
+mkfiles := $(patsubst %,$(LIBDRM_TOP)/%/Android.mk,$(SUBDIRS))
+include $(mkfiles)
diff --git a/radeon/Android.mk b/radeon/Android.mk
new file mode 100644
index 0000000..9cba546
--- /dev/null
+++ b/radeon/Android.mk
@@ -0,0 +1,30 @@
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_RADEON_FILES, LIBDRM_RADEON_H_FILES
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_radeon
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_RADEON_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/radeon
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/radeon \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_COPY_HEADERS := $(LIBDRM_RADEON_H_FILES)
+LOCAL_COPY_HEADERS_TO := libdrm
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 7/8] nouveau: add Android build support
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
                     ` (5 preceding siblings ...)
  2014-07-29 17:27   ` [PATCH 6/8] radeon: add Android build support Emil Velikov
@ 2014-07-29 17:27   ` 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
  8 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

v2 Rename the headers variable(s) to *_H_FILES.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk         |  1 +
 nouveau/Android.mk | 30 ++++++++++++++++++++++++++++++
 2 files changed, 31 insertions(+)
 create mode 100644 nouveau/Android.mk

diff --git a/Android.mk b/Android.mk
index 3f43625..d040d4f 100644
--- a/Android.mk
+++ b/Android.mk
@@ -55,6 +55,7 @@ include $(BUILD_SHARED_LIBRARY)
 
 SUBDIRS := \
 	intel \
+	nouveau \
 	radeon
 
 mkfiles := $(patsubst %,$(LIBDRM_TOP)/%/Android.mk,$(SUBDIRS))
diff --git a/nouveau/Android.mk b/nouveau/Android.mk
new file mode 100644
index 0000000..734fc21
--- /dev/null
+++ b/nouveau/Android.mk
@@ -0,0 +1,30 @@
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_NOUVEAU_FILES, LIBDRM_NOUVEAU_H_FILES
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_nouveau
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_NOUVEAU_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/nouveau
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/nouveau \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_COPY_HEADERS := $(LIBDRM_NOUVEAU_H_FILES)
+LOCAL_COPY_HEADERS_TO := libdrm
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH 8/8] freedreno: add Android build support
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
                     ` (6 preceding siblings ...)
  2014-07-29 17:27   ` [PATCH 7/8] nouveau: " Emil Velikov
@ 2014-07-29 17:27   ` Emil Velikov
  2014-07-31 15:33   ` [PATCHv2 0/8] Upstreaming the Android build and misc fixes Gore, Tim
  8 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-07-29 17:27 UTC (permalink / raw)
  To: dri-devel; +Cc: Emil Velikov

v2 Rename the headers variable(s) to *_H_FILES.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Android.mk           |  1 +
 freedreno/Android.mk | 30 ++++++++++++++++++++++++++++++
 2 files changed, 31 insertions(+)
 create mode 100644 freedreno/Android.mk

diff --git a/Android.mk b/Android.mk
index d040d4f..bb49b0b 100644
--- a/Android.mk
+++ b/Android.mk
@@ -54,6 +54,7 @@ LOCAL_COPY_HEADERS_TO := libdrm
 include $(BUILD_SHARED_LIBRARY)
 
 SUBDIRS := \
+	freedreno \
 	intel \
 	nouveau \
 	radeon
diff --git a/freedreno/Android.mk b/freedreno/Android.mk
new file mode 100644
index 0000000..243a1e2
--- /dev/null
+++ b/freedreno/Android.mk
@@ -0,0 +1,30 @@
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Import variables LIBDRM_FREEDRENO_FILES, LIBDRM_FREEDRENO_H_FILES
+include $(LOCAL_PATH)/Makefile.sources
+
+LOCAL_MODULE := libdrm_freedreno
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SHARED_LIBRARIES := libdrm
+
+LOCAL_SRC_FILES := $(LIBDRM_FREEDRENO_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+	$(LOCAL_PATH)/freedreno
+
+LOCAL_C_INCLUDES := \
+	$(LIBDRM_TOP) \
+	$(LIBDRM_TOP)/freedreno \
+	$(LIBDRM_TOP)/include/drm
+
+LOCAL_CFLAGS := \
+	-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+
+LOCAL_COPY_HEADERS := $(LIBDRM_FREEDRENO_H_FILES)
+LOCAL_COPY_HEADERS_TO := freedreno
+
+LOCAL_SHARED_LIBRARIES := \
+	libdrm
+
+include $(BUILD_SHARED_LIBRARY)
-- 
2.0.2

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* RE: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
  2014-07-29 17:27 ` [PATCHv2 " Emil Velikov
                     ` (7 preceding siblings ...)
  2014-07-29 17:27   ` [PATCH 8/8] freedreno: " Emil Velikov
@ 2014-07-31 15:33   ` Gore, Tim
  2014-07-31 18:32     ` Emil Velikov
  8 siblings, 1 reply; 31+ messages in thread
From: Gore, Tim @ 2014-07-31 15:33 UTC (permalink / raw)
  To: Emil Velikov, dri-devel@lists.freedesktop.org

Ok, I still had to manually apply some of patch 3/8 as it was corrupted
And would not apply, but after this I was able to build within one of 
My android trees. I have not tested the resulting libraries yet, but the
Overall build process seems ok.

  Tim

> -----Original Message-----
> From: Emil Velikov [mailto:emil.l.velikov@gmail.com]
> Sent: Tuesday, July 29, 2014 6:27 PM
> To: dri-devel@lists.freedesktop.org
> Cc: Gore, Tim
> Subject: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
> 
> Changes since the orignal posting:
>  - Rebased on top of master.
>  - Used _H_FILES for header lists (_HEADERS is a no-go with autotools)
>  - Install the freedreno headers to {include_dir}/freedreno, similar to the
> automake builds.
>  - Correctly include $(hw)/Android.mk
> 
> The series is also available at the fixes+android-v2 branch in
> https://github.com/evelikov/libdrm.
> 
> -Emil

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
  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
  0 siblings, 1 reply; 31+ messages in thread
From: Emil Velikov @ 2014-07-31 18:32 UTC (permalink / raw)
  To: Gore, Tim, dri-devel@lists.freedesktop.org; +Cc: emil.l.velikov

Strange, I've explicitly made sure that it's rebased on top of libdrm/master.
I will give it another try in a moment.

FWIW, for Intel at least a mmap/mmap64 would be needed due to the bionic
shortage of their original implementation.

As mentioned earlier, I'm seeking for a few acked/reviewed-by and the rest of
the fixes will follow in due time. Can I consider this acked-by ?

Thanks for having a look
-Emil

On 31/07/14 16:33, Gore, Tim wrote:
> Ok, I still had to manually apply some of patch 3/8 as it was corrupted
> And would not apply, but after this I was able to build within one of 
> My android trees. I have not tested the resulting libraries yet, but the
> Overall build process seems ok.
> 
>   Tim
> 
>> -----Original Message-----
>> From: Emil Velikov [mailto:emil.l.velikov@gmail.com]
>> Sent: Tuesday, July 29, 2014 6:27 PM
>> To: dri-devel@lists.freedesktop.org
>> Cc: Gore, Tim
>> Subject: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
>>
>> Changes since the orignal posting:
>>  - Rebased on top of master.
>>  - Used _H_FILES for header lists (_HEADERS is a no-go with autotools)
>>  - Install the freedreno headers to {include_dir}/freedreno, similar to the
>> automake builds.
>>  - Correctly include $(hw)/Android.mk
>>
>> The series is also available at the fixes+android-v2 branch in
>> https://github.com/evelikov/libdrm.
>>
>> -Emil
> 

^ permalink raw reply	[flat|nested] 31+ messages in thread

* [PATCHv3 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources
  2014-07-29 17:27   ` [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
@ 2014-08-24 18:28     ` Emil Velikov
  0 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-08-24 18:28 UTC (permalink / raw)
  To: dri-devel; +Cc: emil.l.velikov

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.
v3: Rebase on top of symbol visibility patches.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---
 Makefile.am                  | 14 ++++----------
 Makefile.sources             | 13 +++++++++++++
 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, 120 insertions(+), 84 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 65680da..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,18 +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.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..d078ca9
--- /dev/null
+++ b/Makefile.sources
@@ -0,0 +1,13 @@
+LIBDRM_FILES := \
+	xf86drm.c \
+	xf86drmHash.c \
+	xf86drmRandom.c \
+	xf86drmSL.c \
+	xf86drmMode.c \
+	xf86atomic.h \
+	libdrm.h \
+	libdrm_lists.h
+
+LIBDRM_H_FILES := \
+	xf86drm.h \
+	xf86drmMode.h
diff --git a/freedreno/Makefile.am b/freedreno/Makefile.am
index 49471e9..0c7db81 100644
--- a/freedreno/Makefile.am
+++ b/freedreno/Makefile.am
@@ -1,4 +1,5 @@
 AUTOMAKE_OPTIONS=subdir-objects
+include Makefile.sources
 
 AM_CFLAGS = \
 	$(WARN_CFLAGS) \
@@ -13,29 +14,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 f734b0b..846695d 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) \
 	$(VISIBILITY_CFLAGS) \
@@ -40,22 +42,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 73cff9f..a7df1ab 100644
--- a/nouveau/Makefile.am
+++ b/nouveau/Makefile.am
@@ -1,3 +1,5 @@
+include Makefile.sources
+
 AM_CFLAGS = \
 	$(WARN_CFLAGS) \
 	$(VISIBILITY_CFLAGS) \
@@ -12,15 +14,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 c969573..aa66ca3 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) \
 	$(VISIBILITY_CFLAGS) \
@@ -35,26 +37,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

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
  2014-07-31 18:32     ` Emil Velikov
@ 2014-08-24 18:39       ` Emil Velikov
  2014-08-29  9:44         ` Gore, Tim
  0 siblings, 1 reply; 31+ messages in thread
From: Emil Velikov @ 2014-08-24 18:39 UTC (permalink / raw)
  To: Gore, Tim, dri-devel@lists.freedesktop.org; +Cc: emil.l.velikov

Hi Tim,

Gave the series another try, and there was some minor issues caused by commit
5d8357976a8 (configure: Support symbol visibility when available). Did not see
any of the originally mentioned issues. Are you sure that you've tried it on
top of fd.o/drm/master ?

Do you have any comments, would like to do any testing (note it will not work
due to the mmap/mmap64 bionic issue, to be addressed next) or should I go
ahead and commit the series ?

Thanks
Emil

The series:
http://lists.freedesktop.org/archives/dri-devel/2014-July/064952.html

Patchv3 3/8:
http://lists.freedesktop.org/archives/dri-devel/2014-August/066748.html


On 31/07/14 19:32, Emil Velikov wrote:
> Strange, I've explicitly made sure that it's rebased on top of libdrm/master.
> I will give it another try in a moment.
> 
> FWIW, for Intel at least a mmap/mmap64 would be needed due to the bionic
> shortage of their original implementation.
> 
> As mentioned earlier, I'm seeking for a few acked/reviewed-by and the rest of
> the fixes will follow in due time. Can I consider this acked-by ?
> 
> Thanks for having a look
> -Emil
> 
> On 31/07/14 16:33, Gore, Tim wrote:
>> Ok, I still had to manually apply some of patch 3/8 as it was corrupted
>> And would not apply, but after this I was able to build within one of 
>> My android trees. I have not tested the resulting libraries yet, but the
>> Overall build process seems ok.
>>
>>   Tim
>>
>>> -----Original Message-----
>>> From: Emil Velikov [mailto:emil.l.velikov@gmail.com]
>>> Sent: Tuesday, July 29, 2014 6:27 PM
>>> To: dri-devel@lists.freedesktop.org
>>> Cc: Gore, Tim
>>> Subject: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
>>>
>>> Changes since the orignal posting:
>>>  - Rebased on top of master.
>>>  - Used _H_FILES for header lists (_HEADERS is a no-go with autotools)
>>>  - Install the freedreno headers to {include_dir}/freedreno, similar to the
>>> automake builds.
>>>  - Correctly include $(hw)/Android.mk
>>>
>>> The series is also available at the fixes+android-v2 branch in
>>> https://github.com/evelikov/libdrm.
>>>
>>> -Emil
>>
> 

^ permalink raw reply	[flat|nested] 31+ messages in thread

* RE: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
  2014-08-24 18:39       ` Emil Velikov
@ 2014-08-29  9:44         ` Gore, Tim
  2014-08-29 10:02           ` Emil Velikov
  0 siblings, 1 reply; 31+ messages in thread
From: Gore, Tim @ 2014-08-29  9:44 UTC (permalink / raw)
  To: Emil Velikov, dri-devel@lists.freedesktop.org

Hi Emil, sorry for the delay.
I still see the same patch error for patch 3/8. The patch diff
for intel/makefile.am has as part of its context:

#    Eric Anholt <eric at anholt.net>

Whereas the source file has

#    Eric Anholt <eric@anholt.net>

So the patch fails. Its trivial of course. Perhaps there is some automatic
Substitution getting done by some tool. Maybe git-am will automatically
Fix this, not sure, I don't have a workflow for git-am.
My source comes from
   Git://anongit.freedesktop.org/git/mesa/drm
Remote =origin
Merge = refs/heads/master

Other than that, as I say the patches look fine, and I have successfully built
Libdrm in an Android tree using these patches and "mm".
I am out of the office from 12:00 until Thurs 4th Sept now.

  Tim

> -----Original Message-----
> From: Emil Velikov [mailto:emil.l.velikov@gmail.com]
> Sent: Sunday, August 24, 2014 7:40 PM
> To: Gore, Tim; dri-devel@lists.freedesktop.org
> Cc: emil.l.velikov@gmail.com; Daniel Vetter (daniel@ffwll.ch)
> Subject: Re: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
> 
> Hi Tim,
> 
> Gave the series another try, and there was some minor issues caused by
> commit
> 5d8357976a8 (configure: Support symbol visibility when available). Did not
> see any of the originally mentioned issues. Are you sure that you've tried it
> on top of fd.o/drm/master ?
> 
> Do you have any comments, would like to do any testing (note it will not
> work due to the mmap/mmap64 bionic issue, to be addressed next) or
> should I go ahead and commit the series ?
> 
> Thanks
> Emil
> 
> The series:
> http://lists.freedesktop.org/archives/dri-devel/2014-July/064952.html
> 
> Patchv3 3/8:
> http://lists.freedesktop.org/archives/dri-devel/2014-August/066748.html
> 
> 
> On 31/07/14 19:32, Emil Velikov wrote:
> > Strange, I've explicitly made sure that it's rebased on top of libdrm/master.
> > I will give it another try in a moment.
> >
> > FWIW, for Intel at least a mmap/mmap64 would be needed due to the
> > bionic shortage of their original implementation.
> >
> > As mentioned earlier, I'm seeking for a few acked/reviewed-by and the
> > rest of the fixes will follow in due time. Can I consider this acked-by ?
> >
> > Thanks for having a look
> > -Emil
> >
> > On 31/07/14 16:33, Gore, Tim wrote:
> >> Ok, I still had to manually apply some of patch 3/8 as it was
> >> corrupted And would not apply, but after this I was able to build
> >> within one of My android trees. I have not tested the resulting
> >> libraries yet, but the Overall build process seems ok.
> >>
> >>   Tim
> >>
> >>> -----Original Message-----
> >>> From: Emil Velikov [mailto:emil.l.velikov@gmail.com]
> >>> Sent: Tuesday, July 29, 2014 6:27 PM
> >>> To: dri-devel@lists.freedesktop.org
> >>> Cc: Gore, Tim
> >>> Subject: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
> >>>
> >>> Changes since the orignal posting:
> >>>  - Rebased on top of master.
> >>>  - Used _H_FILES for header lists (_HEADERS is a no-go with
> >>> autotools)
> >>>  - Install the freedreno headers to {include_dir}/freedreno, similar
> >>> to the automake builds.
> >>>  - Correctly include $(hw)/Android.mk
> >>>
> >>> The series is also available at the fixes+android-v2 branch in
> >>> https://github.com/evelikov/libdrm.
> >>>
> >>> -Emil
> >>
> >

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCHv2 0/8] Upstreaming the Android build and misc fixes
  2014-08-29  9:44         ` Gore, Tim
@ 2014-08-29 10:02           ` Emil Velikov
  0 siblings, 0 replies; 31+ messages in thread
From: Emil Velikov @ 2014-08-29 10:02 UTC (permalink / raw)
  To: Gore, Tim, dri-devel@lists.freedesktop.org; +Cc: emil.l.velikov

Hi Tim,

On 29/08/14 10:44, Gore, Tim wrote:
> Hi Emil, sorry for the delay.
> I still see the same patch error for patch 3/8. The patch diff
> for intel/makefile.am has as part of its context:
> 
> #    Eric Anholt <eric at anholt.net>
> 
> Whereas the source file has
> 
> #    Eric Anholt <eric@anholt.net>
> 
> So the patch fails. Its trivial of course. Perhaps there is some automatic
> Substitution getting done by some tool.
The issue you're seeing here is (afaik) an anti-spam feature. The ML
software/parser automatically substitutes/obscures email addresses.

For any future case, I would recommend adding a remote branch rather than
picking patches from mailling-lists - not all of them play nice :\

> Maybe git-am will automatically
> Fix this, not sure, I don't have a workflow for git-am.
> My source comes from
>    Git://anongit.freedesktop.org/git/mesa/drm
> Remote =origin
> Merge = refs/heads/master
> 
> Other than that, as I say the patches look fine, and I have successfully built
> Libdrm in an Android tree using these patches and "mm".
> I am out of the office from 12:00 until Thurs 4th Sept now.
> 
Nice. They build fine on my end as well. I've even had a couple of people test
them (with a mmap patch on top) alongside mesa 10.2 :)

I was hoping for an acked-by/reviewed-by, but it seems like I'll push the
series as is.

Thanks
Emil

>   Tim
> 

^ permalink raw reply	[flat|nested] 31+ messages in thread

end of thread, other threads:[~2014-08-29 10:03 UTC | newest]

Thread overview: 31+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
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   ` [PATCH 3/8] libdrm, freedreno, intel, nouveau, radeon: add Makefile.sources Emil Velikov
2014-08-24 18:28     ` [PATCHv3 " 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
  -- strict thread matches above, loose matches on Subject: below --
2014-07-29 16:43 [PATCH " Gore, Tim

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).