Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

/usr/include missing from NDK (r16b)

I've just installed NDK (r16b) using the SDK manager, but is ~/Library/Android/sdk/ndk-bundle/platforms/android-24/arch-x86/usr/include (I'm on OS X) supposed to exist? I can't seem to find it. I have ~/Library/Android/sdk/ndk-bundle/platforms/android-24/arch-x86/usr/lib. The following is the result from running tree at /arch-x86:

arch-x86 tree
.
└── usr
    └── lib
        ├── crtbegin_dynamic.o
        ├── crtbegin_so.o
        ├── crtbegin_static.o
        ├── crtend_android.o
        ├── crtend_so.o
        ├── libEGL.so
        ├── libGLESv1_CM.so
        ├── libGLESv2.so
        ├── libGLESv3.so
        ├── libOpenMAXAL.so
        ├── libOpenSLES.so
        ├── libandroid.so
        ├── libc.a
        ├── libc.so
        ├── libcamera2ndk.so
        ├── libdl.so
        ├── libjnigraphics.so
        ├── liblog.so
        ├── libm.a
        ├── libm.so
        ├── libmediandk.so
        ├── libstdc++.a
        ├── libstdc++.so
        ├── libvulkan.so
        ├── libz.a
        └── libz.so

2 directories, 26 files

Is there a way to generate the include directory? I'm actually looking for the file ~/Library/Android/sdk/ndk-bundle/platforms/android-24/arch-x86/usr/include/android/api-level.h

like image 523
John M. Avatar asked Dec 31 '17 10:12

John M.


1 Answers

In the latest SDK, api-level.h is located at

~/Library/Android/sdk/ndk-bundle/sysroot/usr/include/android/api-level.h

In the future, if you can not find one file due to the directory hierarchy changed, you can do like following to find out

$ cd ~/Library/Android/sdk/ndk-bundle
$ find . -name "api-level.h"
like image 52
alijandro Avatar answered Oct 26 '22 08:10

alijandro