简体   繁体   中英

Android NDK Include Path In Eclipse

I have an Android NDK project that builds fine in cygwin using ndk-build.

However, I wanted to have it build in eclipse, so I installed C/C++ Development tools into my ADT version of eclipse and added native support to the project in eclipse. However, after building, I get the following error:

fatal error: timer.h: No such file or directory

In my original Android.mk file, I have the following include that lets it work in cygwin:

LOCAL_C_INCLUDES := /cygdrive/c/ADT/includes/

I tried adding a similar include path (C:\\ADT\\includes) to Project->Properties->C/C++ General->Paths and Symbols, but still no luck. Any suggestions?

The fix was to use windows paths LOCAL_C_INCLUDES := C:/ADT/includes/

Note that using the following works as well (per cpu2's answer)

LOCAL_CFLAGS := -IC:/ADT/includes/

-I/path/to/includes到您的标志中。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM