@@ -22,11 +22,27 @@ ifneq ($(HOST),$(TARGET))
22
22
endif
23
23
24
24
ifeq (android,$(findstring android,$(TARGET)))
25
- CONFIGURE_FLAGS += \
26
- --with-android-ndk=$(ANDROID_NDK) \
27
- --with-android-toolchain=$(ANDROID_TOOLCHAIN) \
28
- --with-android-version=$(NDK_ANDROID_VERSION) \
29
- $(NULL)
25
+ ifneq (,$(STLPORT_CPPFLAGS))
26
+ CONFIGURE_FLAGS += STLPORT_CPPFLAGS="$(STLPORT_CPPFLAGS)"
27
+ endif
28
+ ifneq (,$(ANDROID_NDK))
29
+ CONFIGURE_FLAGS += --with-android-ndk=$(ANDROID_NDK)
30
+ endif
31
+ ifneq (,$(ANDROID_NDK_VERSION))
32
+ CONFIGURE_FLAGS += --with-android-ndk-version=$(ANDROID_NDK_VERSION)
33
+ endif
34
+ ifneq (,$(ANDROID_VERSION))
35
+ CONFIGURE_FLAGS += --with-android-version=$(ANDROID_VERSION)
36
+ endif
37
+ ifneq (,$(ANDROID_PLATFORM_DIR))
38
+ CONFIGURE_FLAGS += --with-android-platform=$(ANDROID_PLATFORM_DIR)
39
+ endif
40
+ ifneq (,$(ANDROID_TOOLCHAIN_DIR))
41
+ CONFIGURE_FLAGS += --with-android-toolchain=$(ANDROID_TOOLCHAIN_DIR)
42
+ endif
43
+ ifneq (,$(ANDROID_CLANG))
44
+ CONFIGURE_FLAGS += --with-android-clang=$(ANDROID_CLANG)
45
+ endif
30
46
endif
31
47
32
48
CC ?= $(TARGET)-gcc
@@ -143,6 +159,10 @@ maybe-configure:
143
159
if [[ $(JSSRC)/configure -nt $(OUT_DIR)/config.status ]] ; then \
144
160
cd $(OUT_DIR) && \
145
161
PYTHON="$(PYTHON)" MOZ_TOOLS="$(MOZ_TOOLS)" \
146
- CC="$(CC)" CPP="$(CPP)" CXX="$(CXX)" AR="$(AR)" \
162
+ CC="$(CC)" CFLAGS="$(CFLAGS)" \
163
+ CPP="$(CPP)" CPPFLAGS="$(CPPFLAGS)" \
164
+ CXX="$(CXX)" CXXFLAGS="$(CXXFLAGS)" \
165
+ AS="$(AS)" AR="$(AR)" \
166
+ STLPORT_LIBS="$(STLPORT_LIBS)" \
147
167
$(JSSRC)/configure $(strip $(CONFIGURE_FLAGS)) || (cat config.log && exit 1) ; \
148
168
fi
0 commit comments