taka-no-me / android-cmake

CMake toolchain file and other scripts for the Android NDK
1.22k stars 438 forks source link

Add NDK r10, arm64-v8a, x86_64, mips64 support. #23

Closed gongminmin closed 9 years ago

Sonicadvance1 commented 10 years ago

Should the CMAKE_SYSTEM_PROCESSOR variable be "aarch64" instead of "armv8-a" to match what it is set to when natively compiling on a aarch64 target?

Sonicadvance1 commented 10 years ago

Line 1211: "set( CMAKE_C_SIZEOF_DATA_PTR 4 )" Line 1219: "set( CMAKE_CXX_SIZEOF_DATA_PTR 4 )"

These need to be set to 8 on 64bit targets (MIPS64, x86_64, AArch64) in order for commonly used 64bit architecture detection to work. These variables are later used to set CMAKE_SIZEOF_VOID_P which is commonly used to determine 32bit or 64 bit architecture compiling.

gongminmin commented 10 years ago

Thanks for your reviewing. I have a new iteration contains those changes.

Sonicadvance1 commented 10 years ago

Awesome, my project now compiles with x86_64 and AArch64 with this. I think the Android L NDK has issues with its MIPS64 target currently, because I don't see any issues with android-cmake that cause the issues I'm seeing.

Sonicadvance1 commented 10 years ago

Awesome, that looks like it fixes all the little annoying bits that happened to crop up.

cmaughan commented 10 years ago

One thing missing from this PR is support for the new C++_static and C++_shared libraries in r10.

opatry commented 10 years ago

The NDK 10 C now provides platforms from 9 to 21 and no more only 'L'. The cmake script might be updated for 10c and the 10b might be no more supported as it was something packaging preview?

birarda commented 9 years ago

Would love to support for 10c merged into master here - for now am using the toolchain found at commit from @weitjong's project above

weitjong commented 9 years ago

I referred to this PR while I was discussing the diffs between this PR and the ndk-r10c branch. Our project actually uses the toolchain from the ndk-r10c branch now. GitHub auto cross-referencing feature can be a nuisance sometimes.

Sorry for any confusion has caused.

opatry commented 9 years ago

do you guys plan to add extra work for r10d ? (not so much changes, just the -r10d to be added to the list of available NDK versions)

taka-no-me commented 9 years ago

Support for r10* NDKs in merged into the master. This thread can be closed now.