Titanium JIRA Archive
Appcelerator Community (AC)

[AC-736] Android: Problem detecting Android SDK

GitHub Issuen/a
TypeBug
Priorityn/a
StatusResolved
ResolutionFixed
Resolution Date2014-06-13T18:38:07.000+0000
Affected Version/sn/a
Fix Version/sn/a
Componentsn/a
Labelsn/a
ReporterFlorian Erfurth
AssigneeChris Barber
Created2014-05-04T15:06:52.000+0000
Updated2016-03-08T07:36:59.000+0000

Description

Steps to Reproduce

Using Kubuntu 14.04 64Bit (same issue when I first tried on 13.10). See Screenshot: A) Just start Titanium and start pages has a red cross next to Android SDK (see screenshot on left side) B) Menu > Preference > Studio > Platforms > Android (See screenshot on right side) There it says there is a Problem

Actual Result

Android SDK not working

Expected Result

Find Android SDK (see screenshot right upper corner, there ARE android SDK properly installed!)

Attachments

FileDateSize
.log2014-05-04T15:06:54.000+000018273
diagnostic8985887684628278040.log2014-05-04T15:06:58.000+000017299
k3b-tool-checklist.png2014-06-13T10:00:24.000+0000149103
TitaniumAndroidSDK.png2014-05-04T15:07:02.000+0000395923
TitaniumAndroidSDK1.png2014-06-13T06:22:04.000+0000418912
TitaniumAndroidSDK2.png2014-06-13T06:22:04.000+0000415580
titanium-config.txt2014-05-16T07:30:29.000+0000931
titanium-info_beforeconfig.txt2014-05-16T07:30:29.000+00003009
titanium-info_current.txt2014-05-16T07:30:29.000+00007836
titanium-sdk.txt2014-05-16T07:30:29.000+0000464

Comments

  1. Ritu Agrawal 2014-05-15

    Please attach the output of the following commands to investigate further 1. Titanium info 2. Titanium config 3. Titanium sdk
  2. Florian Erfurth 2014-05-15

    Hi Ritu, where should I enter those commands? I don't have Titanium binary but TitaniumStudio. Am I missing somewhat? I have Titanium SDK 3.2.3GA installed. cu Floh
  3. Ritu Agrawal 2014-05-15

    You can go to the terminal and type the commands.
  4. Florian Erfurth 2014-05-16

    Sorry, I just found it in node-path. Didn't know that node installed titanium-cli. I entered 'titanium info' and got Issues, see Attachment titanium-info_beforeconfig.txt. Then I did './titanium config android.sdkPath /home/f.erfurth/Development/android-sdks' and redo 'titanium info', see Attachment titanium-info_current.txt. There the issue about not finding android-sdk disappeared but still Titanium_Studio complains... I also attached result of 'titanium config' and 'titanium sdk'. cu Floh
  5. Ritu Agrawal 2014-05-19

    "titanium-info" shows your Android SDK directory as "/home/f.erfurth/Development/android-sdks" but your Studio dialog box shows the path as "/home/f.erfurth/Development/android-sdk-home" so there is a discrepancy here. Which one is correct? Can you try setting "/home/f.erfurth/Development/android-sdks" in Studio and see if it works?
  6. Florian Erfurth 2014-05-19

    Hi, sorry for confusing you but I'm using '/home/f.erfurth/Development/android-sdks'. When I took screenshot and report bug here the directory was called android-sdk-home because I tried that after reading this: https://developer.appcelerator.com/question/147158/configuring-titanium-for-android-development But renaming the folder to one which contains the string 'home' didn't help so I renamed back to android-sdks. Short answer to your last question if this works: Unfortunatelly no. cu Floh
  7. Ritu Agrawal 2014-05-21

    Thanks for confirmation. What information do you see in this case when you click on "Click for Details" link?
  8. Florian Erfurth 2014-05-21

    Hi, no problem. Details only says: "An error was detected with the SDKs configuration. Reason: [Android SDK Home] No Android SDKs were found under the specified SDK location" Well I dunno why Android SDKs is not found. cu Floh
  9. Chris Barber 2014-06-12

    [~f.erfurth] Your Android SDK path in the Titanium CLI differs from the one in Titanium Studio. The CLI is pointing to the correct location:
       /home/f.erfurth/Development/android-sdks
       
    However, Studio is pointing to:
       /home/f.erfurth/Development/android-sdk-home
       
    Which may exist, but needs to be the same as the Titanium CLI. Please update the Android SDK path in Studio to point to the same one as the Titanium CLI:
       /home/f.erfurth/Development/android-sdks
       
  10. Florian Erfurth 2014-06-13

  11. Florian Erfurth 2014-06-13

    Added 2 Screenshots TitaniumAndroidSDK1.png and TitaniumAndroidSDK2.png. These Paths are same as I said in last comment and still not working. UPDATE: TitaniumAndroidSDK1.png: Sorry, I just saw I accidentally marked ndk-path but right above there is sdk-path.
  12. Chris Barber 2014-06-13

    [~f.erfurth] Hmm, sorry I closed it. Reopened it until we solve this. :) So, what we need to do is first verify that the Titanium CLI can see the Android SDK and the targets. You can do this by running:
        ti info -t android
        
    I saw in the attached titanium-info_current.txt that the CLI indeed did find the Android SDKs. To test that the Titanium CLI can build apps just fine, go to any Titanium app, then run the following:
        ti build -p android --build-only
        
    If the app builds fine, then we can safely say the issue is in Titanium Studio, not the Titanium CLI build system. The next thing to do is to set the Android SDK path in Studio to the correct location. You just need the Android SDK. You do not need the Android NDK for building apps. If Studio is complaining still, then we need to further investigate. Sorry to make you run around, but I want to make sure you can get up and running. :)
  13. Florian Erfurth 2014-06-13

    Oh well... I found a solution. Thank you Chris Barber, because of your hint I noticed one weird behaviour (Titanium CLI not found... while trying to create App). Because I didn't create new Project yet I never got this error. Result: ti & titanium was missing in $PATH-Directory, so I symlinked there and voilá... Android-SDK => Check! :) I'd suggest: Titanium Studio should check, if all neccessary tools is installed *and runable* at start. Also I'd suggest, if I go to menu: Help > Studio > Run diagnostic Test... I expect from running diagnostic test complaining about missing Titanium-CLI. (diagnostic never complaint before :-O ) I think this would help many Titanium-beginners and I was only looking, whats wrong about Android, but not if Titanium CLI is found by Titanium Studio. I'd suggest if you could implement a checklist-dialog (if already, where is it?). Similiar like the one from k3b (burning software) I'll attach a screenshot how it looks like. This helps much for beginners if they're unsure if every tools is setup properly. If you think, my installed instance Titanium Studio may have bug because it didn't report about missing Titanium SDK, I'm willing help you giving more feedback you want know. Just let me know please. Still, I'm sorry making such fuss, but I'm happy to try out Titanium Studio. Thank you very much! cu Floh
  14. Florian Erfurth 2014-06-13

    Attachment k3b-tool-checklist.png This is the checklist of k3b-burning software which tells user if tools are installed/configured properly. Just a idea.
  15. Chris Barber 2014-06-13

    [~f.erfurth] Great! Glad you solved the problem. :) We do have a checklist, but it's only in the CLI, not in Studio. You simply run:
        ti setup check
        
    It's not comprehensive, but it does check the obvious stuff.
  16. Florian Erfurth 2014-06-15

    I see... thank you very much! :)

JSON Source