diff options
author | Kishore Kadiyala <[email protected]> | 2019-03-11 11:23:03 +0200 |
---|---|---|
committer | Tapani Pälli <[email protected]> | 2019-03-25 10:11:57 +0200 |
commit | e1d80571606684af869317837902abc6f6e82017 (patch) | |
tree | d354842603413e81f8df7e5e99d257fd9b5c186e /src/intel | |
parent | 01cf39003517c6842ad8684e5ba30552d54e3570 (diff) |
android: static link with libexpat with Android O+
In Android O, MESA needs to statically link libexpat so that
it's in same VNDK namespace.
v2: apply change also to anv driver (Tapani)
v3: use += in anv change (Eric Engestrom)
Change-Id: I82b0be5c817c21e734dfdf5bfb6a9aa1d414ab33
Signed-off-by: Kishore Kadiyala <[email protected]>
Signed-off-by: Tapani Pälli <[email protected]>
Reviewed-by: Eric Engestrom <[email protected]>
Diffstat (limited to 'src/intel')
-rw-r--r-- | src/intel/Android.common.mk | 12 | ||||
-rw-r--r-- | src/intel/Android.vulkan.mk | 11 |
2 files changed, 21 insertions, 2 deletions
diff --git a/src/intel/Android.common.mk b/src/intel/Android.common.mk index faec6b3ea4e..79d9f1284a0 100644 --- a/src/intel/Android.common.mk +++ b/src/intel/Android.common.mk @@ -38,7 +38,17 @@ LOCAL_C_INCLUDES := \ $(MESA_TOP)/src/mapi \ $(MESA_TOP)/src/mesa -LOCAL_SHARED_LIBRARIES := libexpat libz liblog +LOCAL_SHARED_LIBRARIES := libz liblog + +# If Android version >=8 MESA should static link libexpat else should dynamic link +ifeq ($(shell test $(PLATFORM_SDK_VERSION) -ge 27; echo $$?), 0) +LOCAL_STATIC_LIBRARIES := \ + libexpat +else +LOCAL_SHARED_LIBRARIES += \ + libexpat +endif + LOCAL_WHOLE_STATIC_LIBRARIES := libmesa_genxml diff --git a/src/intel/Android.vulkan.mk b/src/intel/Android.vulkan.mk index f38decbf308..05922afdbe0 100644 --- a/src/intel/Android.vulkan.mk +++ b/src/intel/Android.vulkan.mk @@ -337,8 +337,17 @@ LOCAL_WHOLE_STATIC_LIBRARIES := \ libmesa_intel_compiler \ libmesa_anv_entrypoints -LOCAL_SHARED_LIBRARIES := $(ANV_SHARED_LIBRARIES) libexpat libz libsync liblog +LOCAL_SHARED_LIBRARIES := $(ANV_SHARED_LIBRARIES) libz libsync liblog LOCAL_HEADER_LIBRARIES += $(VULKAN_COMMON_HEADER_LIBRARIES) +# If Android version >=8 MESA should static link libexpat else should dynamic link +ifeq ($(shell test $(PLATFORM_SDK_VERSION) -ge 27; echo $$?), 0) +LOCAL_STATIC_LIBRARIES := \ + libexpat +else + LOCAL_SHARED_LIBRARIES += \ + libexpat +endif + include $(MESA_COMMON_MK) include $(BUILD_SHARED_LIBRARY) |