New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
compiling error with NDK r12b: relocation overflow in R_ARM_THM_CALL #152
Comments
$ cocos compile -p android
Building mode: debug
Using Eclipse project : /work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android
Android platform not specified, searching a default one...
running: '/usr/local/google/home/danalbert/android-sdk-linux/tools/android update project -t android-10 -p /work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android'
Updated project.properties
Updated local.properties
Updated file /work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android/proguard-project.txt
Android platform not specified, searching a default one...
running: '/usr/local/google/home/danalbert/android-sdk-linux/tools/android update lib-project -p /work/src/cocos2d-x-3.12/cocos/platform/android/java -t android-19'
Updated project.properties
Updated local.properties
Updated file /work/src/cocos2d-x-3.12/cocos/platform/android/java/proguard-project.txt
Building native...
NDK build mode: debug
running: '/work/src/android-ndk-r12b/ndk-build -C /work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android -j48 NDK_MODULE_PATH=/work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android/../../..:/work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android/../../../cocos:/work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android/../../../external NDK_TOOLCHAIN_VERSION=clang NDK_DEBUG=1'
Android NDK: ERROR:/work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android/../../../external/freetype2/prebuilt/android/Android.mk:cocos_freetype2_static: LOCAL_SRC_FILES points to a missing file
Android NDK: Check that /work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android/../../../external/freetype2/prebuilt/android/arm64-v8a/libfreetype.a exists or that its path is correct
make: Entering directory `/work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android'
/work/src/android-ndk-r12b/build/core/prebuilt-library.mk:45: *** Android NDK: Aborting . Stop.
make: Leaving directory `/work/src/cocos2d-x-3.12/tests/cpp-tests/proj.android' |
That error usually means that one of the binaries being linked is simply too large and that jump/relocation address simply can't fit in the instruction. |
@DanAlbert thanks for testing, it is strange, all developers and me don't meet the compiling error. Now i added |
@DanAlbert Could you please use |
fixed in #16223 |
@shenhanc78: repros for me with both gold and bfd. Is there anything that can be done about this? @minggo: I don't have this problem when building for armeabi-v7a. This might just be a matter of Thumb-1 being insufficient (in which case I think the |
@DanAlbert yep, it seems only has problem with |
Yeah, but you might want to do that only for armeabi, not armeabi-v7a. Thumb-2 can encode much larger offsets. |
@DanAlbert thanks. But i don't quite understand that |
arm/thumb/thumb2 are different instruction sets. see "branch" on page 3 of http://infocenter.arm.com/help/topic/com.arm.doc.qrc0001l/QRC0001_UAL.pdf for the ranges of the available branch instructions. (T being thumb and T2 thumb2.) |
Yep, i know they are different instructions set. I just want to know what will happen if i use |
steps to reproduce it
./setup.py
to set up some environment (doesn't support python 3)cocos2d-x/tests/cpp-tests
cocos compile -p android
My environment:
The text was updated successfully, but these errors were encountered: