changeset 454:7492d2cb7b75

update to latest toolchain, gradle 4.10.2
author Carl Byington <carl@five-ten-sg.com>
date Wed, 07 Nov 2018 17:13:10 -0800
parents f65d8bb11eb0
children 3f24984b435f
files Makefile app/build.gradle app/src/main/jni/Application.mk app/src/main/res/drawable/btn_close.xml app/src/main/res/layout/act_console.xml app/src/main/res/layout/item_host.xml build.gradle gradle/wrapper/gradle-wrapper.properties
diffstat 8 files changed, 143 insertions(+), 74 deletions(-) [+]
line wrap: on
line diff
--- a/Makefile	Mon Mar 21 09:50:22 2016 -0700
+++ b/Makefile	Wed Nov 07 17:13:10 2018 -0800
@@ -28,8 +28,8 @@
 	rm -rf app/build/*
 	echo -e "$(version)" >app/src/main/res/values/version.xml
 	cat app/src/main/res/values/version.xml
-	./gradlew $(task)
-	mv app/build/outputs/apk/app-arm-$(style).apk $(apk)
+	ANDROID_HOME=/home/carl/Android/Sdk ANDROID_NDK_HOME=/home/carl/Android/Sdk/ndk-bundle ./gradlew $(task)
+	mv app/build/outputs/apk/arm/$(style)/app-arm-$(style).apk $(apk)
 	ls -al app/build/outputs/apk
 
 prep:
--- a/app/build.gradle	Mon Mar 21 09:50:22 2016 -0700
+++ b/app/build.gradle	Wed Nov 07 17:13:10 2018 -0800
@@ -19,70 +19,71 @@
 }
 
 
-apply plugin: 'com.android.model.application'
+apply plugin: 'com.android.application'
 
-model {
-    android {
-        compileSdkVersion = 16
-        buildToolsVersion = "23.0.2"
-        buildTypes {
-            release {
-                minifyEnabled = false
-                signingConfig = $("android.signingConfigs.release")
-            }
-            debug {
-                debuggable = true
-                ndk {
-                    debuggable = true
-                }
-            }
-        }
-        productFlavors {
-            create("arm") {
-                ndk.abiFilters.add("armeabi")
-            }
-            create("x86") {
-                ndk.abiFilters.add("x86")
-            }
-        }
-        ndk {
-            moduleName = "com_google_ase_Exec"
-            cppFlags.add("-Werror")
-            ldLibs.add("log")
-        }
-        sources {
-            main {
-                jni {
-                    source {
-                        srcDir "Exec"
-                    }
-                }
-            }
-        }
-        defaultConfig.with {
-            applicationId = "com.five_ten_sg.connectbot"
-            minSdkVersion.apiLevel = 8
-            targetSdkVersion.apiLevel = 15
-        }
-    }
-
-    android.signingConfigs {
-        create("release") {
-            def console = System.console()
-            if (console) {
-                storePassword = new String(console.readPassword("\nkey store password: "))
-                keyPassword   = new String(console.readPassword("\nkey alias password: "))
-            }
-            else {
-                def read = System.in.newReader().&readLine
-                print "\nkey store password"
-                storePassword = read()
-                print "\nkey alias password"
-                keyPassword   = read()
-            }
+android {
+    signingConfigs {
+        release {
+            print "\nNo Console\n"
+            def read = System.in.newReader().&readLine
+            print "\nkey store password"
+            storePassword = read()
+            print "\nkey alias password"
+            keyPassword   = read()
+            print "\nDone\n"
             storeFile = file("../510Connectbot.keystore")
             storeType = "jks"
             keyAlias  = "510Connectbot"
         }
     }
+    compileSdkVersion = 16
+    buildTypes {
+        release {
+            minifyEnabled = false
+            signingConfig = signingConfigs.release
+            ndk {
+                debuggable = false
+                abiFilters 'armeabi-v7a'
+            }
+        }
+        debug {
+            debuggable = true
+            ndk {
+                debuggable = true
+                abiFilters 'armeabi-v7a'
+            }
+        }
+    }
+    flavorDimensions "arch"
+    productFlavors {
+        arm {
+            dimension "arch"
+        }
+        x86 {
+            dimension "arch"
+        }
+    }
+    sourceSets {
+        main {
+            jni {
+                srcDir "Exec"
+            }
+        }
+    }
+
+    defaultConfig {
+        applicationId = "com.five_ten_sg.connectbot"
+        minSdkVersion = 8
+        targetSdkVersion = 15
+        ndk {
+            moduleName = "com_google_ase_Exec"
+        }
+    }
+
+    externalNativeBuild {
+        ndkBuild {
+            path "src/main/jni/Android.mk"
+        }
+    }
+
 }
--- a/app/src/main/jni/Application.mk	Mon Mar 21 09:50:22 2016 -0700
+++ b/app/src/main/jni/Application.mk	Wed Nov 07 17:13:10 2018 -0800
@@ -1,2 +1,2 @@
 # Build both ARMv5TE and x86-32 machine code.
-APP_ABI := armeabi x86
+APP_ABI := armeabi-v7a x86
--- a/app/src/main/res/drawable/btn_close.xml	Mon Mar 21 09:50:22 2016 -0700
+++ b/app/src/main/res/drawable/btn_close.xml	Wed Nov 07 17:13:10 2018 -0800
@@ -17,11 +17,11 @@
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
 
     <item android:state_pressed="false" android:state_focused="false"
-        android:drawable="@+drawable/btn_close_normal" />
+        android:drawable="@drawable/btn_close_normal" />
 
     <item android:state_pressed="true"
-        android:drawable="@+drawable/btn_close_pressed" />
+        android:drawable="@drawable/btn_close_pressed" />
 
     <item android:state_focused="true"
-        android:drawable="@+drawable/btn_close_selected" />
+        android:drawable="@drawable/btn_close_selected" />
 </selector>
--- a/app/src/main/res/layout/act_console.xml	Mon Mar 21 09:50:22 2016 -0700
+++ b/app/src/main/res/layout/act_console.xml	Wed Nov 07 17:13:10 2018 -0800
@@ -133,7 +133,7 @@
 			android:layout_height="wrap_content"
 			android:layout_toRightOf="@+id/button_sym"
 			android:layout_alignParentBottom="true"
-			android:src="@+drawable/button_input"
+			android:src="@drawable/button_input"
 			android:contentDescription="@string/image_description_line_input"
 			/>
 
@@ -143,7 +143,7 @@
 			android:layout_height="wrap_content"
 			android:layout_alignParentBottom="true"
 			android:layout_alignParentRight="true"
-			android:src="@+drawable/button_keyboard"
+			android:src="@drawable/button_keyboard"
 			android:contentDescription="@string/image_description_show_keyboard"
 			/>
 
@@ -154,7 +154,7 @@
 			android:layout_height="wrap_content"
 			android:layout_alignParentLeft="true"
 			android:layout_alignParentBottom="true"
-			android:src="@+drawable/button_ctrl"
+			android:src="@drawable/button_ctrl"
 			android:contentDescription="@string/image_description_toggle_control_character"
 			/>
 
@@ -165,7 +165,7 @@
 			android:layout_height="wrap_content"
 			android:layout_toRightOf="@+id/button_ctrl"
 			android:layout_alignParentBottom="true"
-			android:src="@+drawable/button_esc"
+			android:src="@drawable/button_esc"
 			android:contentDescription="@string/image_description_send_escape_character"
 			/>
 
@@ -175,8 +175,8 @@
 			android:layout_width="wrap_content"
 			android:layout_height="wrap_content"
 			android:layout_alignParentBottom="true"
-			android:layout_toRightOf="@+id/button_esc"		
-			android:src="@+drawable/button_sym"
+			android:layout_toRightOf="@+id/button_esc"
+			android:src="@drawable/button_sym"
 			android:contentDescription="@string/image_description_sym"
 			/>
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/src/main/res/layout/item_host.xml	Wed Nov 07 17:13:10 2018 -0800
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+ * ConnectBot: simple, powerful, open-source SSH client for Android
+ * Copyright 2007 Kenny Root, Jeffrey Sharkey
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+-->
+
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+	android:id="@android:id/content"
+	android:layout_width="fill_parent"
+	android:layout_height="wrap_content"
+	android:padding="10dip"
+	>
+
+	<ImageView
+		android:id="@android:id/icon"
+		android:src="@drawable/connected"
+		android:contentDescription="@string/image_description_connected"
+		android:layout_width="wrap_content"
+		android:layout_height="wrap_content"
+		android:layout_alignParentRight="true"
+		android:paddingTop="5dip"
+		/>
+
+	<LinearLayout
+		android:orientation="horizontal"
+		android:layout_width="fill_parent"
+		android:layout_height="wrap_content"
+		>
+
+	<TextView
+		android:id="@android:id/text1"
+		android:layout_width="wrap_content"
+		android:layout_height="wrap_content"
+		android:singleLine="true"
+		android:ellipsize="end"
+		android:textAppearance="?android:attr/textAppearanceLarge"
+		/>
+
+	<TextView
+		android:id="@android:id/text2"
+		android:layout_width="wrap_content"
+		android:layout_height="wrap_content"
+		android:paddingLeft="10dip"
+		android:textAppearance="?android:attr/textAppearanceSmall"
+		/>
+
+		
+	</LinearLayout>
+
+</RelativeLayout>
\ No newline at end of file
--- a/build.gradle	Mon Mar 21 09:50:22 2016 -0700
+++ b/build.gradle	Wed Nov 07 17:13:10 2018 -0800
@@ -3,14 +3,16 @@
 buildscript {
     repositories {
         jcenter()
+        google()
     }
     dependencies {
-        classpath 'com.android.tools.build:gradle-experimental:0.7.0-alpha3'
+        classpath 'com.android.tools.build:gradle:3.2.1'
     }
 }
 
 allprojects {
     repositories {
         jcenter()
+        google()
     }
 }
--- a/gradle/wrapper/gradle-wrapper.properties	Mon Mar 21 09:50:22 2016 -0700
+++ b/gradle/wrapper/gradle-wrapper.properties	Wed Nov 07 17:13:10 2018 -0800
@@ -3,4 +3,6 @@
 distributionPath=wrapper/dists
 zipStoreBase=GRADLE_USER_HOME
 zipStorePath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
+#distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
+distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip
+