diff options
author | Chia-I Wu <olvaffe@gmail.com> | 2011-03-19 21:20:49 +0800 |
---|---|---|
committer | Chia-I Wu <olvaffe@gmail.com> | 2011-03-25 03:30:43 +0800 |
commit | f84d94632227ace654d3f9e7e0e4a686ef906483 (patch) | |
tree | 4eef3995ac38f7fb4cde46624000d1d8b02e9543 /src | |
parent | 66c6b2520d0b51b51e9632146db92ab4cad30762 (diff) |
android: fix building
Diffstat (limited to 'src')
-rw-r--r-- | src/Android.mk | 11 | ||||
-rw-r--r-- | src/egl/Android.mk | 4 | ||||
-rw-r--r-- | src/gallium/drivers/r600/Android.mk | 43 | ||||
-rw-r--r-- | src/gallium/state_trackers/Android.mk | 1 | ||||
-rw-r--r-- | src/gallium/targets/Android.mk | 12 | ||||
-rw-r--r-- | src/gallium/winsys/r600/Android.mk | 38 | ||||
-rw-r--r-- | src/gralloc/Android.mk | 59 |
7 files changed, 132 insertions, 36 deletions
diff --git a/src/Android.mk b/src/Android.mk index 7c306dd953..204b380e7d 100644 --- a/src/Android.mk +++ b/src/Android.mk @@ -40,10 +40,12 @@ MESA_BUILD_I965C := false # Gallium drivers MESA_BUILD_GALLIUM := false MESA_BUILD_I915G := false +MESA_BUILD_R600G := false MESA_BUILD_SWRAST := false # gralloc modules MESA_BUILD_INTEL := false +MESA_BUILD_RADEON := false MESA_BUILD_VMWGFX := false MESA_DO_BUILD := false @@ -75,6 +77,15 @@ MESA_BUILD_INTEL := true MESA_DO_BUILD := true endif +ifeq ($(strip $(BOARD_USES_R600G)),true) +MESA_BUILD_GALLIUM := true +MESA_BUILD_R600G := true +# gralloc +MESA_BUILD_RADEON := true + +MESA_DO_BUILD := true +endif + ifeq ($(strip $(BOARD_USES_VMWGFX)),true) MESA_BUILD_GALLIUM := true MESA_BUILD_SWRAST := true diff --git a/src/egl/Android.mk b/src/egl/Android.mk index 143531ad6a..f1cedc0792 100644 --- a/src/egl/Android.mk +++ b/src/egl/Android.mk @@ -72,7 +72,9 @@ LOCAL_C_INCLUDES := \ external/mesa/src/gralloc \ external/drm \ external/drm/include/drm \ - external/mesa/src/mesa/drivers + external/mesa/src/mesa/drivers \ + external/mesa/src/gallium/include \ + external/mesa/src/gallium/winsys LOCAL_MODULE := libmesa_classic_egl diff --git a/src/gallium/drivers/r600/Android.mk b/src/gallium/drivers/r600/Android.mk new file mode 100644 index 0000000000..b76a78810f --- /dev/null +++ b/src/gallium/drivers/r600/Android.mk @@ -0,0 +1,43 @@ +ifeq ($(strip $(MESA_BUILD_R600G)),true) + +LOCAL_PATH := $(call my-dir) + +# from Makefile +C_SOURCES = \ + r600_asm.c \ + r600_blit.c \ + r600_buffer.c \ + r600_helper.c \ + r600_pipe.c \ + r600_query.c \ + r600_resource.c \ + r600_shader.c \ + r600_state.c \ + r600_texture.c \ + r700_asm.c \ + evergreen_state.c \ + eg_asm.c \ + r600_translate.c \ + r600_state_common.c + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := \ + $(C_SOURCES) + +LOCAL_CFLAGS := \ + -std=c99 \ + -fvisibility=hidden \ + -Wno-sign-compare + +LOCAL_C_INCLUDES := \ + external/mesa/src/gallium/include \ + external/mesa/src/gallium/auxiliary \ + external/drm \ + external/drm/include/drm + +LOCAL_MODULE := libmesa_pipe_r600 + +include $(BUILD_STATIC_LIBRARY) + +endif # MESA_BUILD_R600G diff --git a/src/gallium/state_trackers/Android.mk b/src/gallium/state_trackers/Android.mk index e0ae537505..65588694d6 100644 --- a/src/gallium/state_trackers/Android.mk +++ b/src/gallium/state_trackers/Android.mk @@ -28,6 +28,7 @@ LOCAL_C_INCLUDES := \ external/mesa/src/gallium/auxiliary \ external/mesa/src/egl/main \ external/mesa/src/gallium/state_trackers/egl \ + external/mesa/src/gallium/winsys \ external/mesa/src/gallium/winsys/sw \ external/mesa/src/gralloc \ external/drm \ diff --git a/src/gallium/targets/Android.mk b/src/gallium/targets/Android.mk index f37ed1e6a2..2101cd3495 100644 --- a/src/gallium/targets/Android.mk +++ b/src/gallium/targets/Android.mk @@ -36,7 +36,6 @@ LOCAL_STATIC_LIBRARIES := \ libmesa_st_mesa \ libmesa_glsl \ libmesa_st_mesa \ - libmesa_talloc \ libmesa_gallium LOCAL_WHOLE_STATIC_LIBRARIES := \ @@ -67,6 +66,17 @@ LOCAL_SHARED_LIBRARIES += \ libdrm_intel endif # MESA_BUILD_I915G +ifeq ($(strip $(MESA_BUILD_R600G)),true) +LOCAL_CFLAGS += -D_EGL_PIPE_R600 +LOCAL_STATIC_LIBRARIES := \ + libmesa_pipe_r600 \ + libmesa_winsys_r600 \ + $(LOCAL_STATIC_LIBRARIES) +LOCAL_SHARED_LIBRARIES += \ + libdrm \ + libdrm_radeon +endif # MESA_BUILD_R600G + LOCAL_MODULE := libGLES_mesa LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/egl diff --git a/src/gallium/winsys/r600/Android.mk b/src/gallium/winsys/r600/Android.mk new file mode 100644 index 0000000000..643a59dc42 --- /dev/null +++ b/src/gallium/winsys/r600/Android.mk @@ -0,0 +1,38 @@ +ifeq ($(strip $(MESA_BUILD_R600G)),true) + +LOCAL_PATH := $(call my-dir) + +# from drm/Makefile +C_SOURCES = \ + bof.c \ + evergreen_hw_context.c \ + radeon_bo.c \ + radeon_pciid.c \ + r600_bo.c \ + r600_drm.c \ + r600_hw_context.c \ + r600_bomgr.c + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := \ + $(addprefix drm/, $(C_SOURCES)) + +LOCAL_CFLAGS := \ + -std=c99 \ + -fvisibility=hidden \ + -Wno-sign-compare + +LOCAL_C_INCLUDES := \ + external/mesa/include \ + external/mesa/src/gallium/include \ + external/mesa/src/gallium/auxiliary \ + external/mesa/src/gallium/drivers/r600 \ + external/drm \ + external/drm/include/drm + +LOCAL_MODULE := libmesa_winsys_r600 + +include $(BUILD_STATIC_LIBRARY) + +endif # MESA_BUILD_R600G diff --git a/src/gralloc/Android.mk b/src/gralloc/Android.mk index cf85517d6d..e50060ee65 100644 --- a/src/gralloc/Android.mk +++ b/src/gralloc/Android.mk @@ -1,56 +1,47 @@ # Android.mk for gralloc LOCAL_PATH := $(call my-dir) +include $(CLEAR_VARS) -common_SRC_FILES := \ +LOCAL_SRC_FILES := \ gralloc_gem.c \ gralloc_kms.c \ gralloc_mod.c -common_C_INCLUDES := \ +LOCAL_C_INCLUDES := \ external/drm \ external/drm/include/drm -common_SHARED_LIBRARIES := \ +LOCAL_SHARED_LIBRARIES := \ libdrm \ liblog \ - libcutils - -ifeq ($(strip $(MESA_BUILD_INTEL)),true) -include $(CLEAR_VARS) - -LOCAL_SRC_FILES := \ - $(common_SRC_FILES) \ - gralloc_gem_i915.c - -LOCAL_C_INCLUDES := \ - $(common_C_INCLUDES) \ - external/drm/intel - -LOCAL_SHARED_LIBRARIES := \ - $(common_SHARED_LIBRARIES) \ - libdrm_intel \ + libcutils \ libEGL -LOCAL_MODULE := gralloc.mesa -LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw - -include $(BUILD_SHARED_LIBRARY) +ifeq ($(strip $(MESA_BUILD_INTEL)),true) +LOCAL_SRC_FILES += gralloc_gem_intel.c +LOCAL_C_INCLUDES += external/drm/intel +LOCAL_CFLAGS += -DENABLE_INTEL +LOCAL_SHARED_LIBRARIES += libdrm_intel endif # MESA_BUILD_INTEL -ifeq ($(strip $(MESA_BUILD_GALLIUM)),true) -include $(CLEAR_VARS) - -LOCAL_SRC_FILES := \ - $(common_SRC_FILES) \ - gralloc_gem_pipe.c +ifeq ($(strip $(MESA_BUILD_RADEON)),true) +LOCAL_SRC_FILES += gralloc_gem_radeon.c +LOCAL_C_INCLUDES += external/drm/radeon +LOCAL_CFLAGS += -DENABLE_RADEON +LOCAL_SHARED_LIBRARIES += libdrm_radeon +endif # MESA_BUILD_INTEL -LOCAL_C_INCLUDES := \ - $(common_C_INCLUDES) \ +# this is broken +ifeq ($(strip $(MESA_BUILD_VMWGFX)),true) +LOCAL_SRC_FILES += gralloc_gem_pipe.c +LOCAL_C_INCLUDES += \ external/mesa/src/gallium/include \ external/mesa/src/gallium/auxiliary +LOCAL_CFLAGS += -DENABLE_VMWGFX +endif # MESA_BUILD_VMWGFX -LOCAL_MODULE := libmesa_st_gralloc +LOCAL_MODULE := gralloc.mesa +LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw -include $(BUILD_STATIC_LIBRARY) -endif # MESA_BUILD_GALLIUM +include $(BUILD_SHARED_LIBRARY) |