[TIMOB-24751] Windows: Cannot build for Android if Windows SDK is not installed
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2017-06-09T15:17:54.000+0000 |
Affected Version/s | Release 6.1.0 |
Fix Version/s | Release 6.1.1 |
Components | Android, Windows |
Labels | n/a |
Reporter | Gary Mathews |
Assignee | Gary Mathews |
Created | 2017-05-30T18:29:58.000+0000 |
Updated | 2017-07-04T13:16:42.000+0000 |
Description
Unable to build Android projects if the Windows SDK is not installed.
appc run -p android --build-only
TypeError: Cannot read property 'sdks' of undefined
at WindowsBuilder.configOptionSDK (C:\ProgramData\Titanium\mobilesdk\win32\6.1.0.GA\windows\cli\commands\_build\config\wpSDK.js:24:71)
at WindowsBuilder.<anonymous> (C:\ProgramData\Titanium\mobilesdk\win32\6.1.0.GA\windows\cli\commands\_build\config.js:124:23)
master: https://github.com/appcelerator/titanium_mobile_windows/pull/1006
6_1_X: https://github.com/appcelerator/titanium_mobile_windows/pull/1007
Am unable to successfully build under Windows machine where Visual studio has never been installed using Ti SDK v6.2.0, v6.1.1, 6.1.0.GA, 6.0.4.GA. Successfully able to build using Ti SDK v6.0.3.GA and older. Trying to build using an Android emulator with API 23 . {noformat} 2017-06-12T18:50:38.042Z | ERROR | An uncaught exception was thrown! Cannot read property 'sdks' of undefined 2017-06-12T18:50:38.043Z | ERROR | Cannot read property 'sdks' of undefined 2017-06-12T18:50:38.043Z | TRACE | TypeError: Cannot read property 'sdks' of undefined at WindowsBuilder.configOptionSDK (C:\ProgramData\Titanium\mobilesdk\win32\6.2.0.v20170609085413\windows\cli\commands\_build\config\wpSDK.js:24:71) at WindowsBuilder.
[~mpappalardo] Try with
6.2.0.v20170612114319
?Thanks Gary, I tried the new build 6.2.0.v20170612114319 but am still getting the same error. I restarted appcelerator after the install. My Check Environment output has the following errors with this build:
fsevents missing
android" executable not found; please reinstall Android SDK
{noformat} Node.js √ node installed (v6.11.0) √ npm installed (v3.10.10) Titanium CLI √ cli bleeding edge (v5.0.14) Titanium CLI Dependencies √ acs up-to-date (v2.0.5) √ alloy up-to-date (v1.9.11) √ appc-cli-titanium up-to-date (v4.3.6) √ appc-inquirer up-to-date (v0.1.10) √ appc-logger up-to-date (v1.1.27) √ appc-platform-sdk up-to-date (v2.3.0) √ arrow up-to-date (v2.0.2) √ async up-to-date (v1.5.2) √ chalk up-to-date (v1.1.3) √ char-spinner up-to-date (v1.0.1) √ columnify up-to-date (v1.5.4) √ commander up-to-date (v2.9.0) √ debug up-to-date (v2.6.8) √ ejs up-to-date (v2.5.6) √ fields up-to-date (v0.1.24) √ fs-extra up-to-date (v0.26.7) × fsevents missing √ inquirer up-to-date (v0.11.4) √ ip up-to-date (v1.1.5) √ jwt-simple up-to-date (v0.3.1) √ lodash up-to-date (v3.10.1) √ mkdirp up-to-date (v0.5.1) √ node-appc up-to-date (v0.2.43) √ node-forge up-to-date (v0.6.49) √ npmconf up-to-date (v2.1.2) √ plural up-to-date (v0.2.0) √ progress up-to-date (v1.1.8) √ recursive-readdir up-to-date (v2.2.1) √ request up-to-date (v2.81.0) √ semver up-to-date (v5.3.0) √ tar up-to-date (v2.2.1) √ tar.gz up-to-date (v1.0.5) √ tiapp.xml up-to-date (v0.2.2) √ titanium up-to-date (v5.0.14) √ which up-to-date (v1.2.14) √ wrench up-to-date (v1.5.9) Titanium SDK √ latest sdk installed (v6.2.0.v20170612114319) √ selected sdk up-to-date (v6.2.0.v20170612114319) Android Environment √ sdk installed (C:\android-sdk-win) √ tools installed (v25.2.5) ! platform tools untested version 26; may or may not work √ build tools installed (v23.0.3) √ adb installed C:\android-sdk-win\platform-tools\adb.exe × android "android" executable not found; please reinstall Android SDK √ emulator installed C:\android-sdk-win\tools\emulator.exe √ mksdcard installed C:\android-sdk-win\tools\mksdcard.exe √ zipalign installed C:\android-sdk-win\build-tools\23.0.3\zipalign.exe √ aapt installed C:\android-sdk-win\build-tools\23.0.3\aapt.exe √ aidl installed C:\android-sdk-win\build-tools\23.0.3\aidl.exe √ targets installed (8 found) √ avds installed (2 found) √ ndk installed (14.1.3816874) √ ndk-build installed (C:\android-ndk-win\android-ndk-r14b\ndk-build.cmd) Java Development Kit √ jdk installed (v1.8.0) √ java installed C:\Program Files (x86)\Java\jdk1.8.0_112\bin\java.exe √ javac installed C:\Program Files (x86)\Java\jdk1.8.0_112\bin\javac.exe √ keytool installed C:\Program Files (x86)\Java\jdk1.8.0_112\bin\keytool.exe √ jarsigner installed C:\Program Files (x86)\Java\jdk1.8.0_112\bin\jarsigner.exe Intel® Hardware Accelerated Execution Manager (HAXM) √ compatible ! installed not found; install HAXM to use Android x86 emulator Network √ online - no proxy server configured √ Network connection test √ Java-based connection test Directory Permissions √ home directory √ titanium config directory √ titanium sdk install directory √ temp directory {noformat}Hi, I deleted all versions of Node.js on my Windows machine and reinstalled Node v4.8.3 with npm v2.15.11, rebooted and tried building with Titanium SDK v6.1.1.v20170612141743. I am still getting the error, "Cannot read property 'sdks' of undefined. Please see my log and dev environment settings below. {noformat} Appcelerator Command-Line Interface, version 6.2.2 Copyright (c) 2014-2017, Appcelerator, Inc. All Rights Reserved. 2017-06-13T14:54:47.015Z | TRACE | set environment to {"registry":"https://software.appcelerator.com","baseurl":"https://platform.appcelerator.com"} 2017-06-13T14:54:47.029Z | TRACE | checking credentials for existing session 2017-06-13T14:54:47.285Z | TRACE | Attempting to load session info from config file 2017-06-13T14:54:47.301Z | TRACE | check if session is invalidated 2017-06-13T14:54:47.778Z | TRACE | refresh session expiry to: 1497970487911 2017-06-13T14:54:47.778Z | TRACE | session expiry 1497970487911 false 2017-06-13T14:54:47.778Z | TRACE | Arrow Cloud config file: C:\Users\accmpp\.acs 2017-06-13T14:54:47.778Z | TRACE | found Arrow Cloud login { mid: 'e8ad5c85388e249f39d6110bc41e7420d442a440', publishPort: 443, publishHost: 'https://admin.cloudapp-enterprise.appcelerator.com', username: 'accmpp@hofstra.edu', cookie: [ 'connect.sid=s%3A5%2FnurF14vou5bi9JuYqG4Ap7.Bg0y7eudA9N%2FEIQ4oO1%2FcbIQUZv%2BSHk1YChEpHY%2Fa%2Bs; Path=/; Expires=Mon, 26 Jun 2017 18:36:14 GMT; HttpOnly' ], defaultEP: { publishHost: 'https://admin.cloudapp-enterprise.appcelerator.com', publishPort: 443 } } , checking nodeACSEndpoint= https://admin.cloudapp-enterprise.appcelerator.com 2017-06-13T14:54:47.778Z | TRACE | Arrow Cloud cookie expiry [ 1498502174000 ] 2017-06-13T14:54:47.778Z | TRACE | session already loaded in opts.session 2017-06-13T14:54:47.778Z | TRACE | getCredentials() session: { "ipaddress": "147.4.77.177", "username": "accmpp@hofstra.edu", "password": "
Hey [~mpappalardo], I've just reviewed the build servers, there's been a little instability in the build jobs so this change hasn't bubbled up to a published SDK yet, a build is currently underway and I'm hopeful that it should be published soon. I'll give you a ping on this ticket once the change has made it through. Apologies for this!
[~mpappalardo], looks like the build just succeeded. I just double checked the download and the changed are there,
appc ti sdk install --branch 6_1_X 6.1.1.v20170613083237
should get you the buildHi Ewan, Thanks for the update. I installed the new build and was successfully able to build and run my project on the emulator without the error mentioned above! There is still an issue when I run 'appc ti setup check', it still says "android executable not found; please reinstall Android SDK" and also "fsevents missing".
Closing ticket as fix verified by reporter.
[~mpappalardo], my apologies in taking so long to get back to you. You can safely ignore those errors, the android executable has been deprecated and is no longer required, and the fsevents missing error it misleading. I've filed TIMOB-24891 and TIMOB-24892 to deal with those issues. Thanks for letting us know!