I am trying to setup an environment to build android and run it on an emulator. I've gotten into AOSP very recently and currently reading a few books about it. Wanting to mess around with it myself I got the following error:
external/libcxx/include/cmath:1345:9: error: no member named 'llrint' in the global namespace; did you mean 'lrint'?
external/libcxx/include/cmath:1348:91: error: use of undeclared identifier 'llrintf'
external/libcxx/include/cmath:1349:91: error: use of undeclared identifier 'llrintl'
external/libcxx/include/cmath:1358:9: error: no member named 'llround' in the global namespace; did you mean 'lround'?
12 errors generated.
make: *** [out/host/darwin-x86/obj/STATIC_LIBRARIES/libc++_static_intermediates/src/hash.o] Error 1
make: *** Waiting for unfinished jobs....
12 errors generated.
make: *** [out/host/darwin-x86/obj/STATIC_LIBRARIES/libc++_static_intermediates/src/debug.o] Error 1
12 errors generated.
make: *** [out/host/darwin-x86/obj/STATIC_LIBRARIES/libc++_static_intermediates/src/random.o] Error 1
12 errors generated.
make: *** [out/host/darwin-x86/obj/STATIC_LIBRARIES/libc++_static_intermediates/src/algorithm.o] Error 1
In total twelve of these errors, with text in between but I haven't copied them all because they are quite the same. (all of them are: error no member named "{double L}[SOMETHING]"; did you mean: {single L}[SOMETHING])
This is the result of running: 1: source build/envsetup.sh 2: lunch 3: sudo make -j4
I am using El Capitan and have followed the official instructions. The only problem I encountered was that XCode didn't create a /developer/SDKs folder with the proper SDK in it so I manually downloaded the SDK from Github and put it in de SDKs folder (which I made). Is it possible that this is the problem?
The code that I am trying to build is un-modified android 6.0.1_r1. I tried running repo-init and repo sync again (to maybe fix the code) but with no effect.
I realise it's quite a stretch to ask, but I have no clue how to fix this. Thanks in advance.
you can try to use MacOSX10.11.sdk as your MacOSX-SDK
you can download MacOSX10.11.sdk from GitHub: https://github.com/phracker/MacOSX-SDKs
copy the MacOSX10.11.sdk to a particular path(such as ~/lib) and create a soft link to /Applications/XCode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
$ ln -s ~/lib/MacOSX10.11.sdk /Applications/XCode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk
(I also copy the MacOSX10.11.sdk to /Developer/SDKs/)
and modify the file int android source code: build/core/combo/mac_version.mk
mac_sdk_versions_supported := 10.9 10.10 10.11
done! try to compile the source code again!
OS: macOS Sierra 10.12
Android Source Code: android6.0.1_r1C
XCode: Version 8.2.1
JDK: java version "1.8.0_101"