blob: e1fd48b7fa98ec65a2da67dd76ec3ece17a11b45 [file] [log] [blame]
The Android Open Source Project9066cfe2009-03-03 19:31:44 -08001LOCAL_PATH:= $(call my-dir)
2
Mathias Agopian2820bd42009-05-27 20:38:06 -07003###############################################################################
The Android Open Source Project9066cfe2009-03-03 19:31:44 -08004# Build META EGL library
5#
6
7include $(CLEAR_VARS)
8
9LOCAL_SRC_FILES:= \
Mathias Agopian1473f462009-04-10 14:24:30 -070010 EGL/egl.cpp \
Mathias Agopian9d17c052009-05-28 17:39:03 -070011 EGL/hooks.cpp \
12 EGL/Loader.cpp \
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080013#
14
Mathias Agopian9d17c052009-05-28 17:39:03 -070015LOCAL_SHARED_LIBRARIES += libcutils libutils
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080016LOCAL_LDLIBS := -lpthread -ldl
17LOCAL_MODULE:= libEGL
18
19# needed on sim build because of weird logging issues
20ifeq ($(TARGET_SIMULATOR),true)
21else
22 LOCAL_SHARED_LIBRARIES += libdl
Mathias Agopianb4b4c112009-06-03 18:26:58 -070023 # we need to access the private Bionic header <bionic_tls.h>
24 LOCAL_C_INCLUDES += bionic/libc/private
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080025endif
26
Mathias Agopian1473f462009-04-10 14:24:30 -070027LOCAL_CFLAGS += -DLOG_TAG=\"libEGL\"
28LOCAL_CFLAGS += -DGL_GLEXT_PROTOTYPES -DEGL_EGLEXT_PROTOTYPES
Mathias Agopiancb29e622009-05-08 15:23:38 -070029LOCAL_CFLAGS += -fvisibility=hidden
Mathias Agopian1473f462009-04-10 14:24:30 -070030
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080031include $(BUILD_SHARED_LIBRARY)
Mathias Agopian9d17c052009-05-28 17:39:03 -070032installed_libEGL := $(LOCAL_INSTALLED_MODULE)
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080033
34
Mathias Agopian9d17c052009-05-28 17:39:03 -070035# OpenGL drivers config file
36ifneq ($(BOARD_EGL_CFG),)
37
38include $(CLEAR_VARS)
39LOCAL_MODULE := egl.cfg
40LOCAL_MODULE_TAGS := optional
41LOCAL_MODULE_CLASS := ETC
42LOCAL_MODULE_PATH := $(TARGET_OUT)/lib/egl
43LOCAL_SRC_FILES := ../../../../$(BOARD_EGL_CFG)
44include $(BUILD_PREBUILT)
45
46# make sure we depend on egl.cfg, so it gets installed
47$(installed_libEGL): | egl.cfg
48
49endif
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080050
Mathias Agopian2820bd42009-05-27 20:38:06 -070051###############################################################################
52# Build the wrapper OpenGL ES 1.x library
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080053#
54
55include $(CLEAR_VARS)
56
Mathias Agopian2820bd42009-05-27 20:38:06 -070057LOCAL_SRC_FILES:= \
58 GLES_CM/gl.cpp.arm \
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080059#
60
Mathias Agopian11be99d2009-05-17 18:50:16 -070061LOCAL_SHARED_LIBRARIES += libcutils libEGL
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080062LOCAL_LDLIBS := -lpthread -ldl
63LOCAL_MODULE:= libGLESv1_CM
64
65# needed on sim build because of weird logging issues
66ifeq ($(TARGET_SIMULATOR),true)
67else
68 LOCAL_SHARED_LIBRARIES += libdl
Mathias Agopianb4b4c112009-06-03 18:26:58 -070069 # we need to access the private Bionic header <bionic_tls.h>
70 LOCAL_C_INCLUDES += bionic/libc/private
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080071endif
72
Mathias Agopian1473f462009-04-10 14:24:30 -070073LOCAL_CFLAGS += -DLOG_TAG=\"libGLESv1\"
74LOCAL_CFLAGS += -DGL_GLEXT_PROTOTYPES -DEGL_EGLEXT_PROTOTYPES
Mathias Agopiancb29e622009-05-08 15:23:38 -070075LOCAL_CFLAGS += -fvisibility=hidden
Mathias Agopian1473f462009-04-10 14:24:30 -070076
The Android Open Source Project9066cfe2009-03-03 19:31:44 -080077include $(BUILD_SHARED_LIBRARY)
Mathias Agopian2820bd42009-05-27 20:38:06 -070078
79
80###############################################################################
81# Build the wrapper OpenGL ES 2.x library
82#
83
84include $(CLEAR_VARS)
85
86LOCAL_SRC_FILES:= \
87 GLES2/gl2.cpp.arm \
88#
89
90LOCAL_SHARED_LIBRARIES += libcutils libEGL
91LOCAL_LDLIBS := -lpthread -ldl
92LOCAL_MODULE:= libGLESv2
93
94# needed on sim build because of weird logging issues
95ifeq ($(TARGET_SIMULATOR),true)
96else
97 LOCAL_SHARED_LIBRARIES += libdl
Mathias Agopianb4b4c112009-06-03 18:26:58 -070098 # we need to access the private Bionic header <bionic_tls.h>
99 LOCAL_C_INCLUDES += bionic/libc/private
Mathias Agopian2820bd42009-05-27 20:38:06 -0700100endif
101
102LOCAL_CFLAGS += -DLOG_TAG=\"libGLESv2\"
103LOCAL_CFLAGS += -DGL_GLEXT_PROTOTYPES -DEGL_EGLEXT_PROTOTYPES
104LOCAL_CFLAGS += -fvisibility=hidden
105
106include $(BUILD_SHARED_LIBRARY)