1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-09-15 18:57:08 +00:00

Android: fix horrible libiconv build

Before, our libiconv build was a joke. We first called configure for our own build host system,
then called make, before we executed a Android.mk script we provided as patch. The first "native make"
always failed, and the LIBICONV_LIB file setting in our Makefile didn't match the built one,
resulting in an always-rebuild of iconv.

This commit cleans up this total mess, removes the double-build, and the Android.mk, and properly calls
./configure with the according target platform, and uses a built toolchain.

As we have to deal with the android bug "NDK: Support for prebuild libs with full sonames"
https://code.google.com/p/android/issues/detail?id=55868
as the 2013 patch
https://lists.gnu.org/archive/html/libtool-patches/2013-06/msg00002.html
by Google's David Turner wasn't inside the 2011 libtool, we pass -avoid-version to
libtool.

Thanks to the proper build, wide_to_utf8 works for android now, removing us of the need to disable it.
This commit is contained in:
est31 2015-07-29 11:54:27 +02:00
parent f97c2702a2
commit eb3aac20c8
5 changed files with 47 additions and 104 deletions

View file

@ -26,8 +26,8 @@ include $(PREBUILT_STATIC_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := iconv
LOCAL_SRC_FILES := deps/libiconv/obj/local/$(TARGET_ARCH_ABI)/libiconv.a
include $(PREBUILT_STATIC_LIBRARY)
LOCAL_SRC_FILES := deps/libiconv/lib/.libs/libiconv.so
include $(PREBUILT_SHARED_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := openal
@ -355,8 +355,8 @@ LOCAL_SRC_FILES += \
# json
LOCAL_SRC_FILES += jni/src/json/jsoncpp.cpp
LOCAL_SHARED_LIBRARIES := openal ogg vorbis gmp
LOCAL_STATIC_LIBRARIES := Irrlicht iconv freetype curl ssl crypto android_native_app_glue $(PROFILER_LIBS)
LOCAL_SHARED_LIBRARIES := iconv openal ogg vorbis gmp
LOCAL_STATIC_LIBRARIES := Irrlicht freetype curl ssl crypto android_native_app_glue $(PROFILER_LIBS)
ifeq ($(HAVE_LEVELDB), 1)
LOCAL_STATIC_LIBRARIES += LevelDB