forked from Mirrorlandia_minetest/minetest
Android: fix sound issue, and gitignore
Previously, sound failed due to errors with hardfp abi build instructions. As the problem couldn't be found, the softfp compatible abi was chosen instead. This move will cause a small performance overhead, but due to the abi being armeabi-v7a, the internal calculations will still be done using the FPU. We also fix some issues with ABI information passing. However, the fixes aren't sufficient to get sound working. The patch also fixes an issue with the gitignore file.
This commit is contained in:
parent
a890c66bc0
commit
47225346be
2
.gitignore
vendored
2
.gitignore
vendored
@ -39,7 +39,7 @@ doc/doxygen_*
|
|||||||
CMakeFiles/*
|
CMakeFiles/*
|
||||||
src/CMakeFiles/*
|
src/CMakeFiles/*
|
||||||
src/Makefile
|
src/Makefile
|
||||||
src/android_config_githash.h
|
src/android_version_githash.h
|
||||||
src/android_version.h
|
src/android_version.h
|
||||||
src/cmake_config.h
|
src/cmake_config.h
|
||||||
src/cmake_config_githash.h
|
src/cmake_config_githash.h
|
||||||
|
@ -47,13 +47,11 @@ ANDROID_VERSION_CODE = 12
|
|||||||
# toolchain config for arm new processors
|
# toolchain config for arm new processors
|
||||||
################################################################################
|
################################################################################
|
||||||
TARGET_HOST = arm-linux
|
TARGET_HOST = arm-linux
|
||||||
TARGET_ABI = armeabi-v7a-hard
|
TARGET_ABI = armeabi-v7a
|
||||||
TARGET_LIBDIR = armeabi-v7a
|
TARGET_LIBDIR = armeabi-v7a
|
||||||
TARGET_TOOLCHAIN = arm-linux-androideabi-
|
TARGET_TOOLCHAIN = arm-linux-androideabi-
|
||||||
TARGET_CFLAGS_ADDON = -mfpu=vfpv3-d16 -D_NDK_MATH_NO_SOFTFP=1 \
|
TARGET_CFLAGS_ADDON = -mfloat-abi=softfp -mfpu=vfpv3
|
||||||
-mfloat-abi=hard -march=armv7-a
|
|
||||||
TARGET_CXXFLAGS_ADDON = $(TARGET_CFLAGS_ADDON)
|
TARGET_CXXFLAGS_ADDON = $(TARGET_CFLAGS_ADDON)
|
||||||
TARGET_LDFLAGS_ADDON = -Wl,--no-warn-mismatch -lm_hard
|
|
||||||
TARGET_ARCH = armv7
|
TARGET_ARCH = armv7
|
||||||
CROSS_PREFIX = arm-linux-androideabi-
|
CROSS_PREFIX = arm-linux-androideabi-
|
||||||
COMPILER_VERSION = 4.8
|
COMPILER_VERSION = 4.8
|
||||||
@ -241,8 +239,8 @@ $(OPENAL_LIB): $(OPENAL_TIMESTAMP)
|
|||||||
echo "changed timestamp for openal detected building..."; \
|
echo "changed timestamp for openal detected building..."; \
|
||||||
cd ${OPENAL_DIR}; \
|
cd ${OPENAL_DIR}; \
|
||||||
ndk-build NDEBUG=${NDEBUG} NDK_MODULE_PATH=${NDK_MODULE_PATH} \
|
ndk-build NDEBUG=${NDEBUG} NDK_MODULE_PATH=${NDK_MODULE_PATH} \
|
||||||
APP_ABI=${TARGET_ABI} APP_PLATFORM=${APP_PLATFORM} \
|
APP_ABI=${TARGET_ABI} TARGET_ARCH_ABI=${TARGET_ABI} \
|
||||||
TARGET_CFLAGS+="${TARGET_CFLAGS_ADDON}" \
|
APP_PLATFORM=${APP_PLATFORM} TARGET_CFLAGS+="${TARGET_CFLAGS_ADDON}" \
|
||||||
TARGET_LDFLAGS+="${TARGET_LDFLAGS_ADDON}" \
|
TARGET_LDFLAGS+="${TARGET_LDFLAGS_ADDON}" \
|
||||||
TARGET_CXXFLAGS+="${TARGET_CXXFLAGS_ADDON}" || exit 1; \
|
TARGET_CXXFLAGS+="${TARGET_CXXFLAGS_ADDON}" || exit 1; \
|
||||||
touch ${OPENAL_TIMESTAMP}; \
|
touch ${OPENAL_TIMESTAMP}; \
|
||||||
@ -268,6 +266,7 @@ ogg_download :
|
|||||||
git clone ${OGG_URL_GIT}|| exit 1; \
|
git clone ${OGG_URL_GIT}|| exit 1; \
|
||||||
cd libvorbis-libogg-android ; \
|
cd libvorbis-libogg-android ; \
|
||||||
patch -p1 < ../../libvorbis-libogg-fpu.patch || exit 1; \
|
patch -p1 < ../../libvorbis-libogg-fpu.patch || exit 1; \
|
||||||
|
sed -i 's-:-?-' jni/Application.mk; \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ogg : $(OGG_LIB)
|
ogg : $(OGG_LIB)
|
||||||
|
Loading…
Reference in New Issue
Block a user