Return-Path: X-Original-To: apmail-cordova-issues-archive@minotaur.apache.org Delivered-To: apmail-cordova-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2D0AA18B86 for ; Mon, 20 Jul 2015 11:54:09 +0000 (UTC) Received: (qmail 17784 invoked by uid 500); 20 Jul 2015 11:54:06 -0000 Delivered-To: apmail-cordova-issues-archive@cordova.apache.org Received: (qmail 17767 invoked by uid 500); 20 Jul 2015 11:54:06 -0000 Mailing-List: contact issues-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@cordova.apache.org Received: (qmail 17670 invoked by uid 99); 20 Jul 2015 11:54:06 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Jul 2015 11:54:06 +0000 Date: Mon, 20 Jul 2015 11:54:05 +0000 (UTC) From: "Sergey Grebnov (JIRA)" To: issues@cordova.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CB-9389) Android. Fix Gradle requirements test MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CB-9389?page=3Dcom.atlassian.ji= ra.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1463347= 0#comment-14633470 ]=20 Sergey Grebnov commented on CB-9389: ------------------------------------ I think we should add logic to check whether Gradle_Home is set and use cor= responding value to test gradle version instead of default location. > Android. Fix Gradle requirements test > ------------------------------------- > > Key: CB-9389 > URL: https://issues.apache.org/jira/browse/CB-9389 > Project: Apache Cordova > Issue Type: Bug > Components: Android > Reporter: Sergey Grebnov > > Cordova Android on Windows10: > After switching to the latest Cordova from master I noticed that Android = build hangs after the following line > JAVA_HOME=3Dc:\Program Files (x86)\Java\jdk1.8.0_11 > After adding additional logging I found out that it hangs internally on t= he following check: > {code} > tryCommand: "c:\tools\android-sdk\sdk\tools\templates\gradle\wrapper\grad= lew" -v > {code} > Looks like this command tries to download gradle wrapper (PS. version als= o looks old) > {code} > =CE=BB "c:\tools\android-sdk\sdk\tools\templates\gradle\wrapper\gradlew"= -v > Downloading http://services.gradle.org/distributions/gradle-1.12-all.zip > .........................................................................= ............................................ > {code} > even if I have gradle tools installed and correctly set GRADLE_HOME envir= onment variable: > {code} > C:\Users\Sergei > =CE=BB echo %gradle_home% > C:\tools\gradle-2.3\ > {code} > Here is corresponding logic in check_regs.js: > {code} > // Returns a promise. Called only by build and clean commands. > module.exports.check_gradle =3D function() { > var sdkDir =3D process.env['ANDROID_HOME']; > var message =3D 'Could not find gradle wrapper within Android SDK. '; > if (!sdkDir) return Q.reject(message + 'Might need to install Android= SDK or set up \'ADROID_HOME\' env variable.'); > var wrapper =3D path.join(sdkDir, 'tools', 'templates', 'gradle', 'wr= apper', 'gradlew'); > return tryCommand('"' + wrapper + '" -v', message + 'Might need to up= date your Android SDK.\n' + > 'Looked here: ' + path.dirname(wrapper)) > .then(function (output) { > // Parse Gradle version from command output > return/^gradle ((?:\d+\.)+(?:\d+))/gim.exec(output)[1]; > }); > }; > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org For additional commands, e-mail: issues-help@cordova.apache.org