解決問題的終極大發,直接更換版本這個是必定可以成功的。php
問題出現老是有緣由的,就是緣由太多沒法解決,那麼主要從兩個方面解決。第一個是更新操做平臺,軟件平臺之間的版本關係影響很大。前提是主要平臺版本必須高於插件的版本,要不問題不減反增。第二就是對於工程所有采用新建而後在去配置相應的文件和環境。不要再原有的工程文件上修改。html
解決辦法:java
解決辦法:設置代理更新,下載本身須要的版本問題android
Eclipse->Windows->Install New Software->Work With添加以下路徑,並點擊添加,勾選全部的文件,進行更新操做。ios
相應的CDT版本參見:http://www.eclipse.org/cdt/downloads.phpgit
Helios版本: http://download.eclipse.org/tools/cdt/releases/heliosgithub
Mars版本: http://download.eclipse.org/tools/cdt/releases/8.8windows
解決辦法1:app
解決辦法1:谷歌被牆提供國內下載的網址eclipse
http://www.androiddevtools.cn/
下載對應的離線包,而後相似更新CDT方式更新ADT
描述:Eclipse啓動SDK Manager報錯
解決辦法:在path環境變量下加上C:\WINDOWS\system32;或將C:\WINDOWS\system32\xcopy.exe拷貝到android sdk目錄的tools下面便可正常運行
描述:NDK開發中顯示,windows環境下NDK開發
解決辦法:查找系統環境變量,找到關於Cygwin的環境變量或其餘無效的環境變量刪除處理。
描述:控制檯顯示Make.exe: *** [libs/armabi-v7a/gdbserver] Error 1
圖片:
解決辦法1:安裝ndk和eclipse修改成x86操做系統
解決辦法2:下降更換NDK版本
描述:Eclipse C/C++編譯出現大量相似的提示
解決辦法1:代碼來源可能不是本軟件編寫,建議從新編寫
解決辦法2:檢查使用的NDK版本是針對32位仍是64位,32位正常執行,64位異常
解決辦法3:軟件應用系統使用了文件加密,將加密文件增長NDK編譯使用的進程
描述:工程打開提示Unable to resolve target android-3
解決辦法1:修改工程使用的Android平臺包
解決辦法2:增長Android對應的平臺
解決辦法3:
描述:Windows的
解決辦法:下載ndk pulgin插件,並將文件放置在\eclipse\plugins路徑下
描述:控制檯報出了一個錯誤:「Unable to launch cygpath. Is Cygwin on the path?] java.io.IOException: Cannot run program "cygpath": CreateProcess error=2」,由於個人ndk是以前安裝的,並無專門設置環境變量。
圖片:
解決辦法1:
一、Head to the project's properties. If you're using Windows, the shortcut is Alt + Enter; or simply right-click the project name to find its properties.
Go to the C/C++ Build section; under Builder Settings tab in Build command: text box you're likely to find something similar to that below, if it's empty then type in the similar text - namely:${NDKROOT}/ndk-buildNaNd where NDKROOT, as its name implies, refers to the path where your NDK root folder exists.
二、Now you must inform eclipse what NDKROOT equates to; as in, where is the NDK root path. You can do this by heading to (in your project's properties) C/C++ Build > Environment > press Add…
Now add your environment variable named NDKROOT (the Name) with the relevant path (Value). Note that you're to repeat this per NDK project. You would get a window similar to that below.
Press OK to the New variable input window and then OK again to the properties window.
解決辦法2:更新eclipse
建議方法3:不要使用導入文件方式,直接採用新建,而後拷貝相應的文件到對應的目錄
Eclipse->Window->Customize Prespective->Command Groups Availability-》check Android SDK and AVD Manager-》OK
描述:執行設置完成NDK配置後,執行編譯操做,控制檯提示
解決辦法:檢查ndk路徑是否有空格,若是有刪除或用其餘符號替換
描述:編譯調試時,控制檯顯示以下信息
解決辦法:工程屬性-->C/C++ General-->Paths and Symbols-->Include-->Add
設置JDK中JRE的include路徑。
相似的解決辦法:
Multiple markers at this line
- Syntax error
- Type 'JNIEnv' could not be resolved
- Type 'JNICALL' could not be resolved
是因爲沒有將jni.h導入的緣故,而這個文件在ndk的目錄下面。因此,參照如下步驟:
Project Properties -> C/C++ General -> Path and Symbols
選擇include標籤,Add -> $Android_NDK_HOME/platforms/android-14/arch-arm/usr/include
且選中All languages.
最後Apply -> OK
解決辦法1:只是不顯示問題
Go to the project's Properties -> C/C++ General -> Code Analysis. Click the "Use project settings" radio button (or "Configure Workspace Settings..." button). Disable (uncheck) the "Method cannot be resolved" checkbox. Click "Apply," "OK." Then for your project, refresh, clean, refresh, build.
There must have been something I did differently in creating the new project. Or maybe it was because of the locations of the projects, or the fact that the previous was a Library. Maybe it really is an Eclipse bug? For reference, I'm using ADT v21.1.0-569685 and NDK r8e for Windows。
解決辦法2:只是不顯示問題
將錯誤刪除,並關閉C代碼窗口
解決辦法3:代碼編寫風格問題
Just switch to the right syntax and Problem will be solved C syntax
return (*env)->NewStringUTF(env, "Hello from JNI !");
C++ Syntax
return (env)->NewStringUTF("Hello from JNI !");
After switching from C to C++ syntax my problem got solved.
描述:
解決辦法1:檢查NDKBUILDER這個路徑配置是否正確,尤爲是NDK的路徑信息
描述:
解決辦法1:檢查文件是否正確安裝NDK開發編寫相應的代碼
解決辦法2:在C++文件中的函數前添加extern 「C」修飾,例如:
使用extern 「C」
描述:編譯過程當中提示
解決辦法:./AndroidManifest.xml文件中的minSdkVersion屬性強制修改到對應的版本便可
描述:斷點提示
解決辦法:GDB在Eclipse中的BUG,暫時不知道如何解決
描述:編譯NDK文件,而後點擊取消,將會顯示上述問題
解決辦法1:工程-->properties-->C++ Builder-->Builder setting-->Build Common
取消use default build common,build common設置爲ndk-build NDK_DEBUG=1
解決方法2:在系統的環境變量中添加上對應的路徑,例如NDKROOT。那麼在使用過程當中修改build common爲${NDKROOT}/ndk-build NDK_DEBUG=1
問題描述:
解決辦法1:在system-images中刪除對應的系統鏡像,在SDK Manager裏刪除Android-wear相關的image
解決方法2:進入sdk目錄下,把..\android-sdk\system-images\android-22\android-wear\armeabi-v7a\devices.xml和..\android-sdk\system-images\android-22\android-wear\x86\devices.xml文件刪除,再把sdk裏面..\android-sdk\tools\lib\下的devices.xml拷貝到上述兩個文件夾裏,重啓eclipse便可
解決方法3:更新eclipse版本,以便支持高版本鏡像文件
描述:
解決方法1:egit是eclipse支持github的插件,裝一個git for windows就好
解決方法2:勾選Do not warn again if Git cannot be found
解決辦法3:
Check home directiory
解決辦法1:勾選Do not show again