1ifneq (false,$(BUILD_EMULATOR_OPENGL_DRIVER)) 2 3LOCAL_PATH := $(call my-dir) 4 5$(call emugl-begin-shared-library,libEGL_emulation) 6$(call emugl-import,libOpenglSystemCommon) 7$(call emugl-set-shared-library-subpath,egl) 8 9ifeq (true,$(GOLDFISH_OPENGL_BUILD_FOR_HOST)) 10$(call emugl-import,libqemupipe$(GOLDFISH_OPENGL_LIB_SUFFIX)) 11else 12$(call emugl-export,STATIC_LIBRARIES,libqemupipe.ranchu) 13endif 14 15LOCAL_CFLAGS += -DLOG_TAG=\"EGL_emulation\" -DEGL_EGLEXT_PROTOTYPES -DWITH_GLES2 16LOCAL_CFLAGS += -Wno-gnu-designator 17 18LOCAL_SRC_FILES := \ 19 eglDisplay.cpp \ 20 egl.cpp \ 21 ClientAPIExts.cpp 22 23ifneq (true,$(GOLDFISH_OPENGL_BUILD_FOR_HOST)) 24 25LOCAL_SHARED_LIBRARIES += libdl 26ifeq (true,$(BUILD_EMULATOR_VULKAN)) 27LOCAL_CFLAGS += -DVIRTIO_GPU 28LOCAL_C_INCLUDES += external/libdrm 29LOCAL_SHARED_LIBRARIES += libdrm 30endif # BUILD_EMULATOR_VULKAN 31endif # GOLDFISH_OPENGL_BUILD_FOR_HOST 32 33ifneq (true,$(GOLDFISH_OPENGL_BUILD_FOR_HOST)) 34ifdef IS_AT_LEAST_OPM1 35LOCAL_HEADER_LIBRARIES += libui_headers 36endif 37 38ifdef IS_AT_LEAST_OPD1 39LOCAL_HEADER_LIBRARIES += libnativebase_headers 40LOCAL_STATIC_LIBRARIES += libarect 41LOCAL_SHARED_LIBRARIES += libnativewindow 42endif 43 44endif # !GOLDFISH_OPENGL_BUILD_FOR_HOST 45 46$(call emugl-end-module) 47 48#### egl.cfg #### 49 50# Ensure that this file is only copied to emulator-specific builds. 51# Other builds are device-specific and will provide their own 52# version of this file to point to the appropriate HW EGL libraries. 53# 54ifneq (,$(filter aosp_arm aosp_x86 aosp_mips full full_x86 full_mips sdk sdk_x86 sdk_mips google_sdk google_sdk_x86 google_sdk_mips,$(TARGET_PRODUCT))) 55include $(CLEAR_VARS) 56 57LOCAL_MODULE := egl.cfg 58LOCAL_SRC_FILES := $(LOCAL_MODULE) 59 60LOCAL_MODULE_PATH := $(TARGET_OUT)/lib/egl 61LOCAL_MODULE_CLASS := ETC 62 63ifeq ($(shell test $(PLATFORM_SDK_VERSION) -lt 19 && echo PreKitkat),PreKitkat) 64 LOCAL_MODULE_TAGS := debug 65endif 66 67include $(BUILD_PREBUILT) 68endif # TARGET_PRODUCT in 'full full_x86 full_mips sdk sdk_x86 sdk_mips google_sdk google_sdk_x86 google_sdk_mips') 69 70endif # BUILD_EMULATOR_OPENGL_DRIVER != false 71