diff --git a/android/libs/MobileAppTracker.jar b/android/3rd_party/MobileAppTracker.jar
similarity index 100%
rename from android/libs/MobileAppTracker.jar
rename to android/3rd_party/MobileAppTracker.jar
diff --git a/android/3rd_party/external_styles/AndroidManifest.xml b/android/3rd_party/external_styles/AndroidManifest.xml
index 365d42cc51..81ecabfd2c 100644
--- a/android/3rd_party/external_styles/AndroidManifest.xml
+++ b/android/3rd_party/external_styles/AndroidManifest.xml
@@ -4,8 +4,4 @@
android:versionCode="1005000"
android:versionName="1.5.0" >
-
-
\ No newline at end of file
diff --git a/android/3rd_party/external_styles/build.gradle b/android/3rd_party/external_styles/build.gradle
new file mode 100644
index 0000000000..caeda6c88a
--- /dev/null
+++ b/android/3rd_party/external_styles/build.gradle
@@ -0,0 +1,19 @@
+apply plugin: 'android-library'
+
+android {
+ compileSdkVersion propTargetSdkVersion.toInteger()
+ buildToolsVersion propBuildToolsVersion
+
+ // Uses properties defined in the root android folder
+ defaultConfig {
+ minSdkVersion propMinSdkVersion.toInteger()
+ targetSdkVersion propTargetSdkVersion.toInteger()
+ }
+
+ sourceSets {
+ main {
+ manifest.srcFile 'AndroidManifest.xml'
+ res.srcDirs = ['res']
+ }
+ }
+}
diff --git a/android/3rd_party/external_styles/build.xml b/android/3rd_party/external_styles/build.xml
deleted file mode 100644
index 2f6f323a25..0000000000
--- a/android/3rd_party/external_styles/build.xml
+++ /dev/null
@@ -1,92 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/3rd_party/external_styles/custom_rules.xml b/android/3rd_party/external_styles/custom_rules.xml
deleted file mode 100644
index 1b816f40a1..0000000000
--- a/android/3rd_party/external_styles/custom_rules.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
diff --git a/android/3rd_party/external_styles/proguard-project.txt b/android/3rd_party/external_styles/proguard-project.txt
deleted file mode 100644
index f2fe1559a2..0000000000
--- a/android/3rd_party/external_styles/proguard-project.txt
+++ /dev/null
@@ -1,20 +0,0 @@
-# To enable ProGuard in your project, edit project.properties
-# to define the proguard.config property as described in that file.
-#
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in ${sdk.dir}/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the ProGuard
-# include property in project.properties.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
diff --git a/android/3rd_party/external_styles/project.properties b/android/3rd_party/external_styles/project.properties
deleted file mode 100644
index 8e4bc5fdce..0000000000
--- a/android/3rd_party/external_styles/project.properties
+++ /dev/null
@@ -1,12 +0,0 @@
-# This file is automatically generated by Android Tools.
-# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
-#
-# This file must be checked in Version Control Systems.
-#
-# To customize properties used by the Ant build system use,
-# "ant.properties", and override values to adapt the script to your
-# project structure.
-
-# Project target.
-target=android-19
-android.library=true
diff --git a/android/3rd_party/external_styles/src/.gitignore b/android/3rd_party/external_styles/src/.gitignore
deleted file mode 100644
index 02336ca90e..0000000000
--- a/android/3rd_party/external_styles/src/.gitignore
+++ /dev/null
@@ -1 +0,0 @@
-# This file is needed to commit empty folder
diff --git a/android/3rd_party/facebook-android-sdk/build.gradle b/android/3rd_party/facebook-android-sdk/build.gradle
deleted file mode 100644
index 2d3bec743b..0000000000
--- a/android/3rd_party/facebook-android-sdk/build.gradle
+++ /dev/null
@@ -1,9 +0,0 @@
-// Top-level build file where you can add configuration options common to all sub-projects/modules.
-buildscript {
- repositories {
- mavenCentral()
- }
- dependencies {
- classpath 'com.android.tools.build:gradle:0.7.+'
- }
-}
diff --git a/android/3rd_party/facebook-android-sdk/facebook/build.gradle b/android/3rd_party/facebook-android-sdk/facebook/build.gradle
index ea2914c498..bb4c17db35 100644
--- a/android/3rd_party/facebook-android-sdk/facebook/build.gradle
+++ b/android/3rd_party/facebook-android-sdk/facebook/build.gradle
@@ -1,16 +1,16 @@
apply plugin: 'android-library'
dependencies {
- compile 'com.android.support:support-v4:13.0.+'
+ compile 'com.android.support:support-v4:19.1.+'
}
android {
- compileSdkVersion 19
- buildToolsVersion "19"
+ compileSdkVersion propTargetSdkVersion.toInteger()
+ buildToolsVersion propBuildToolsVersion
defaultConfig {
- minSdkVersion 8
- targetSdkVersion 19
+ minSdkVersion propMinSdkVersion.toInteger()
+ targetSdkVersion propTargetSdkVersion.toInteger()
}
sourceSets {
@@ -20,4 +20,8 @@ android {
res.srcDirs = ['res']
}
}
+
+ lintOptions {
+ abortOnError false
+ }
}
diff --git a/android/libs/FlurryAnalytics_3.3.0.jar b/android/3rd_party/flurryAnalytics_3.4.0.jar
old mode 100644
new mode 100755
similarity index 50%
rename from android/libs/FlurryAnalytics_3.3.0.jar
rename to android/3rd_party/flurryAnalytics_3.4.0.jar
index 946714f7ce..7a314945fd
Binary files a/android/libs/FlurryAnalytics_3.3.0.jar and b/android/3rd_party/flurryAnalytics_3.4.0.jar differ
diff --git a/android/AndroidManifest.xml b/android/AndroidManifest.xml
index f1b2c39d66..06402714f8 100644
--- a/android/AndroidManifest.xml
+++ b/android/AndroidManifest.xml
@@ -1,23 +1,145 @@
-
-
-
-
-
-
-
-
+
-
-
-
-
-
-
-
-
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/android/MapsWithMeLite.Samsung/AndroidManifest.xml b/android/MapsWithMeLite.Samsung/AndroidManifest.xml
deleted file mode 100644
index 9f718fe1c0..0000000000
--- a/android/MapsWithMeLite.Samsung/AndroidManifest.xml
+++ /dev/null
@@ -1,182 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMeLite.Samsung/README.txt b/android/MapsWithMeLite.Samsung/README.txt
deleted file mode 100644
index 8ea6b84441..0000000000
--- a/android/MapsWithMeLite.Samsung/README.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-# To build Lite version for Samsung (new one, which is actively supported, with package com.mapswithme.maps.samsung
-# on corp account sams-appstore@mapswithme.com)
-$ ant samsung-production
\ No newline at end of file
diff --git a/android/MapsWithMeLite.Samsung/build.xml b/android/MapsWithMeLite.Samsung/build.xml
deleted file mode 100644
index d5428eb9a6..0000000000
--- a/android/MapsWithMeLite.Samsung/build.xml
+++ /dev/null
@@ -1,96 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMeLite.Samsung/custom_rules.xml b/android/MapsWithMeLite.Samsung/custom_rules.xml
deleted file mode 100644
index caf3bbb5c6..0000000000
--- a/android/MapsWithMeLite.Samsung/custom_rules.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- *************************************************
- **** Android Manifest has debuggable=true ****
- ** Doing DEBUG packaging with PRODUCTION keys ***
- *************************************************
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Signing final apk...
-
-
-
-
- Release Package: ${out.final.file}
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMeLite.Samsung/proguard-project.txt b/android/MapsWithMeLite.Samsung/proguard-project.txt
deleted file mode 100644
index f2fe1559a2..0000000000
--- a/android/MapsWithMeLite.Samsung/proguard-project.txt
+++ /dev/null
@@ -1,20 +0,0 @@
-# To enable ProGuard in your project, edit project.properties
-# to define the proguard.config property as described in that file.
-#
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in ${sdk.dir}/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the ProGuard
-# include property in project.properties.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
diff --git a/android/MapsWithMeLite.Samsung/project.properties b/android/MapsWithMeLite.Samsung/project.properties
deleted file mode 100644
index f341956381..0000000000
--- a/android/MapsWithMeLite.Samsung/project.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-# This file is automatically generated by Android Tools.
-# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
-#
-# This file must be checked in Version Control Systems.
-#
-# To customize properties used by the Ant build system edit
-# "ant.properties", and override values to adapt the script to your
-# project structure.
-#
-# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
-#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
-
-# Project target.
-target=android-19
-android.library.reference.1=..
diff --git a/android/MapsWithMeLite.Samsung/res/values/styles.xml b/android/MapsWithMeLite.Samsung/res/values/styles.xml
deleted file mode 100644
index 4dba0d0a4c..0000000000
--- a/android/MapsWithMeLite.Samsung/res/values/styles.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/android/MapsWithMeLite.Samsung/src/.gitignore b/android/MapsWithMeLite.Samsung/src/.gitignore
deleted file mode 100644
index cda0aa634a..0000000000
--- a/android/MapsWithMeLite.Samsung/src/.gitignore
+++ /dev/null
@@ -1,5 +0,0 @@
-# This file is needed to keep directory in git.
-# Ignore everything in this directory
-*
-# Except this file
-!.gitignore
\ No newline at end of file
diff --git a/android/MapsWithMeLite/AndroidManifest.xml b/android/MapsWithMeLite/AndroidManifest.xml
deleted file mode 100644
index 59f49931e8..0000000000
--- a/android/MapsWithMeLite/AndroidManifest.xml
+++ /dev/null
@@ -1,208 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMeLite/README.txt b/android/MapsWithMeLite/README.txt
deleted file mode 100644
index 918aab2e3b..0000000000
--- a/android/MapsWithMeLite/README.txt
+++ /dev/null
@@ -1,16 +0,0 @@
-# To build Lite version for Google Play
-$ ant google-production
-
-# For Samsung Store (old version, not supported any more,
-# which is registered to sams-apps@mapswithme.com with package com.mapswithme.maps
-# and should redirect users to new version with package com.mapswithme.maps.samsung
-$ ant samsung-production
-
-For Amazon market
-$ ant amazon-production
-
-For LG store
-$ ant lg-production
-
-For korean TStore
-$ ant tstore-production
\ No newline at end of file
diff --git a/android/MapsWithMeLite/build.xml b/android/MapsWithMeLite/build.xml
deleted file mode 100644
index d5428eb9a6..0000000000
--- a/android/MapsWithMeLite/build.xml
+++ /dev/null
@@ -1,96 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMeLite/custom_rules.xml b/android/MapsWithMeLite/custom_rules.xml
deleted file mode 100644
index caf3bbb5c6..0000000000
--- a/android/MapsWithMeLite/custom_rules.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- *************************************************
- **** Android Manifest has debuggable=true ****
- ** Doing DEBUG packaging with PRODUCTION keys ***
- *************************************************
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Signing final apk...
-
-
-
-
- Release Package: ${out.final.file}
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMeLite/proguard-project.txt b/android/MapsWithMeLite/proguard-project.txt
deleted file mode 100644
index f2fe1559a2..0000000000
--- a/android/MapsWithMeLite/proguard-project.txt
+++ /dev/null
@@ -1,20 +0,0 @@
-# To enable ProGuard in your project, edit project.properties
-# to define the proguard.config property as described in that file.
-#
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in ${sdk.dir}/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the ProGuard
-# include property in project.properties.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
diff --git a/android/MapsWithMeLite/project.properties b/android/MapsWithMeLite/project.properties
deleted file mode 100644
index f341956381..0000000000
--- a/android/MapsWithMeLite/project.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-# This file is automatically generated by Android Tools.
-# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
-#
-# This file must be checked in Version Control Systems.
-#
-# To customize properties used by the Ant build system edit
-# "ant.properties", and override values to adapt the script to your
-# project structure.
-#
-# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
-#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
-
-# Project target.
-target=android-19
-android.library.reference.1=..
diff --git a/android/MapsWithMeLite/res/values/strings.xml b/android/MapsWithMeLite/res/values/strings.xml
deleted file mode 100644
index 3b2c7416f9..0000000000
--- a/android/MapsWithMeLite/res/values/strings.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
- MapsWithMe
- GZZ684W5DV22GRH6D7Z3
-
diff --git a/android/MapsWithMeLite/res/values/styles.xml b/android/MapsWithMeLite/res/values/styles.xml
deleted file mode 100644
index 4dba0d0a4c..0000000000
--- a/android/MapsWithMeLite/res/values/styles.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/android/MapsWithMeLite/src/.gitignore b/android/MapsWithMeLite/src/.gitignore
deleted file mode 100644
index cda0aa634a..0000000000
--- a/android/MapsWithMeLite/src/.gitignore
+++ /dev/null
@@ -1,5 +0,0 @@
-# This file is needed to keep directory in git.
-# Ignore everything in this directory
-*
-# Except this file
-!.gitignore
\ No newline at end of file
diff --git a/android/MapsWithMePro/AndroidManifest.xml b/android/MapsWithMePro/AndroidManifest.xml
deleted file mode 100644
index 07c1949350..0000000000
--- a/android/MapsWithMePro/AndroidManifest.xml
+++ /dev/null
@@ -1,246 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMePro/README.txt b/android/MapsWithMePro/README.txt
deleted file mode 100644
index 927032169a..0000000000
--- a/android/MapsWithMePro/README.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-# To build Pro version for all markets
-$ ant production
diff --git a/android/MapsWithMePro/build.xml b/android/MapsWithMePro/build.xml
deleted file mode 100644
index bbe27c9455..0000000000
--- a/android/MapsWithMePro/build.xml
+++ /dev/null
@@ -1,96 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMePro/custom_rules.xml b/android/MapsWithMePro/custom_rules.xml
deleted file mode 100644
index caf3bbb5c6..0000000000
--- a/android/MapsWithMePro/custom_rules.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- *************************************************
- **** Android Manifest has debuggable=true ****
- ** Doing DEBUG packaging with PRODUCTION keys ***
- *************************************************
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Signing final apk...
-
-
-
-
- Release Package: ${out.final.file}
-
-
-
-
-
-
-
-
-
diff --git a/android/MapsWithMePro/proguard-project.txt b/android/MapsWithMePro/proguard-project.txt
deleted file mode 100644
index f2fe1559a2..0000000000
--- a/android/MapsWithMePro/proguard-project.txt
+++ /dev/null
@@ -1,20 +0,0 @@
-# To enable ProGuard in your project, edit project.properties
-# to define the proguard.config property as described in that file.
-#
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in ${sdk.dir}/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the ProGuard
-# include property in project.properties.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
diff --git a/android/MapsWithMePro/project.properties b/android/MapsWithMePro/project.properties
deleted file mode 100644
index f341956381..0000000000
--- a/android/MapsWithMePro/project.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-# This file is automatically generated by Android Tools.
-# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
-#
-# This file must be checked in Version Control Systems.
-#
-# To customize properties used by the Ant build system edit
-# "ant.properties", and override values to adapt the script to your
-# project structure.
-#
-# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
-#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
-
-# Project target.
-target=android-19
-android.library.reference.1=..
diff --git a/android/MapsWithMePro/res/values-v13/styles.xml b/android/MapsWithMePro/res/values-v13/styles.xml
deleted file mode 100644
index 2868a579bc..0000000000
--- a/android/MapsWithMePro/res/values-v13/styles.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-
diff --git a/android/MapsWithMePro/res/values/styles.xml b/android/MapsWithMePro/res/values/styles.xml
deleted file mode 100644
index 4dba0d0a4c..0000000000
--- a/android/MapsWithMePro/res/values/styles.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/android/MapsWithMePro/src/.gitignore b/android/MapsWithMePro/src/.gitignore
deleted file mode 100644
index cda0aa634a..0000000000
--- a/android/MapsWithMePro/src/.gitignore
+++ /dev/null
@@ -1,5 +0,0 @@
-# This file is needed to keep directory in git.
-# Ignore everything in this directory
-*
-# Except this file
-!.gitignore
\ No newline at end of file
diff --git a/android/YoPme/build.gradle b/android/YoPme/build.gradle
index 148896e795..93be7f8ddf 100644
--- a/android/YoPme/build.gradle
+++ b/android/YoPme/build.gradle
@@ -1,20 +1,32 @@
+buildscript {
+ repositories {
+ mavenCentral()
+ }
+
+ dependencies {
+ classpath 'com.android.tools.build:gradle:0.9.2'
+ }
+}
+
apply plugin: 'android'
dependencies {
- compile fileTree(dir: 'libs', include: '*.jar')
- compile project(':3rd_party:yota_sdk')
+ compile project(':yota_sdk')
}
apply plugin:'base'
+Properties properties = new Properties()
+properties.load(project.rootProject.file('local.properties').newDataInputStream())
+def NDK_BUILD = properties.getProperty('ndk.dir') + '/ndk-build'
+
task ndkBuild(type:Exec) {
- def clParts = (['ndk-build', '-j', Runtime.runtime.availableProcessors() + 1] + propNdkFlags.split(' ')).flatten()
- println(clParts.join(" "))
+ def clParts = ([NDK_BUILD, '-j', Runtime.runtime.availableProcessors() + 1] + propNdkFlags.split(' ')).flatten()
commandLine clParts
}
-task ndkBuildClean(type:Exec, description: 'Cleaning native libraries.') {
- commandLine 'ndk-build','clean'
+task ndkBuildClean(type:Exec, description: 'Clean native libraries') {
+ commandLine NDK_BUILD, 'clean'
}
task copyNativeLibs(type: Copy, dependsOn: 'ndkBuild', description: 'Copying native libraries.') {
@@ -29,7 +41,8 @@ clean.dependsOn 'cleanCopyNativeLibs'
clean.dependsOn 'ndkBuildClean'
tasks.withType(com.android.build.gradle.tasks.PackageApplication) { pkgTask ->
- pkgTask.jniDir new File(buildDir, 'native-libs')
+ pkgTask.jniFolders = new HashSet()
+ pkgTask.jniFolders.add(new File(buildDir, 'native-libs'))
}
def getVersionName() { propVersionName }
@@ -38,45 +51,51 @@ def getBaseName() { getApkName() + "_" + getVersionName() }
android {
- compileSdkVersion 19
- buildToolsVersion "19.0.0"
- project.archivesBaseName = getBaseName()
-
- signingConfigs {
- yopme {
- storeFile file("key/android.key")
- storePassword "***REMOVED***"
- keyAlias "yopme"
- keyPassword "***REMOVED***"
- }
- }
-
- buildTypes {
- debug { jniDebugBuild true }
- release { signingConfig signingConfigs.yopme }
- }
-
- defaultConfig {
- versionCode = propVersionCode
- versionName = propVersionName
- minSdkVersion 17
- targetSdkVersion 19
- }
+ // All properties are read from gradle.properties file
+ // Should we use "Yota Platinum:Platinum Add-On:17" as compile SDK version?
+ compileSdkVersion propTargetSdkVersion.toInteger()
+ buildToolsVersion propBuildToolsVersion
- sourceSets {
- main {
- manifest.srcFile 'AndroidManifest.xml'
- java.srcDirs = ['src']
- resources.srcDirs = ['src']
- aidl.srcDirs = ['src']
- renderscript.srcDirs = ['src']
- res.srcDirs = ['res']
- assets.srcDirs = ['assets']
- }
+ defaultConfig {
+ versionCode propVersionCode.toInteger()
+ versionName propVersionName
+ minSdkVersion propMinSdkVersion.toInteger()
+ targetSdkVersion propTargetSdkVersion.toInteger()
+ }
- instrumentTest.setRoot('tests')
+ project.archivesBaseName = getBaseName()
- debug.setRoot('build-types/debug')
- release.setRoot('build-types/release')
+ signingConfigs {
+ yopme {
+ storeFile file("key/android.key")
+ storePassword "***REMOVED***"
+ keyAlias "yopme"
+ keyPassword "***REMOVED***"
}
+ }
+
+ buildTypes {
+ debug {
+ jniDebugBuild true
+ }
+
+ release {
+ signingConfig signingConfigs.yopme
+ }
+ }
+
+ sourceSets {
+ main {
+ manifest.srcFile 'AndroidManifest.xml'
+ java.srcDirs = ['src']
+ res.srcDirs = ['res']
+ assets.srcDirs = ['assets']
+ }
+ }
+
+ // We don't compress these extensions in assets/ because our random FileReader can't read zip-compressed files from apk
+ aaptOptions {
+ noCompress 'txt', 'bin', 'skn', 'html', 'png', 'json', 'mwm', 'ttf'
+ ignoreAssetsPattern "!.svn:!.git:!.DS_Store:!*.scc:.*:_*:!CVS:!thumbs.db:!picasa.ini:!*~"
+ }
}
diff --git a/android/YoPme/gradle.properties b/android/YoPme/gradle.properties
index ffb5baeac2..86f44b762a 100644
--- a/android/YoPme/gradle.properties
+++ b/android/YoPme/gradle.properties
@@ -1,4 +1,7 @@
-propVersionCode=7
-propVersionName=1.1.0
+propMinSdkVersion=17
+propTargetSdkVersion=19
+propBuildToolsVersion=19.0.3
+propVersionCode=8
+propVersionName=1.1.1
propApkName=YoPMe_mobile_maps
propNdkFlags=V=0 NDK_DEBUG=0 PRODUCTION=1
diff --git a/android/YoPme/gradle/wrapper/gradle-wrapper.jar b/android/YoPme/gradle/wrapper/gradle-wrapper.jar
new file mode 100644
index 0000000000..3c7abdf127
Binary files /dev/null and b/android/YoPme/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/android/YoPme/gradle/wrapper/gradle-wrapper.properties b/android/YoPme/gradle/wrapper/gradle-wrapper.properties
new file mode 100644
index 0000000000..8eb8c856b8
--- /dev/null
+++ b/android/YoPme/gradle/wrapper/gradle-wrapper.properties
@@ -0,0 +1,6 @@
+#Thu Apr 24 20:55:59 FET 2014
+distributionBase=GRADLE_USER_HOME
+distributionPath=wrapper/dists
+zipStoreBase=GRADLE_USER_HOME
+zipStorePath=wrapper/dists
+distributionUrl=http\://services.gradle.org/distributions/gradle-1.11-bin.zip
diff --git a/android/YoPme/gradlew b/android/YoPme/gradlew
new file mode 100755
index 0000000000..91a7e269e1
--- /dev/null
+++ b/android/YoPme/gradlew
@@ -0,0 +1,164 @@
+#!/usr/bin/env bash
+
+##############################################################################
+##
+## Gradle start up script for UN*X
+##
+##############################################################################
+
+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+DEFAULT_JVM_OPTS=""
+
+APP_NAME="Gradle"
+APP_BASE_NAME=`basename "$0"`
+
+# Use the maximum available, or set MAX_FD != -1 to use that value.
+MAX_FD="maximum"
+
+warn ( ) {
+ echo "$*"
+}
+
+die ( ) {
+ echo
+ echo "$*"
+ echo
+ exit 1
+}
+
+# OS specific support (must be 'true' or 'false').
+cygwin=false
+msys=false
+darwin=false
+case "`uname`" in
+ CYGWIN* )
+ cygwin=true
+ ;;
+ Darwin* )
+ darwin=true
+ ;;
+ MINGW* )
+ msys=true
+ ;;
+esac
+
+# For Cygwin, ensure paths are in UNIX format before anything is touched.
+if $cygwin ; then
+ [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
+fi
+
+# Attempt to set APP_HOME
+# Resolve links: $0 may be a link
+PRG="$0"
+# Need this for relative symlinks.
+while [ -h "$PRG" ] ; do
+ ls=`ls -ld "$PRG"`
+ link=`expr "$ls" : '.*-> \(.*\)$'`
+ if expr "$link" : '/.*' > /dev/null; then
+ PRG="$link"
+ else
+ PRG=`dirname "$PRG"`"/$link"
+ fi
+done
+SAVED="`pwd`"
+cd "`dirname \"$PRG\"`/" >&-
+APP_HOME="`pwd -P`"
+cd "$SAVED" >&-
+
+CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
+
+# Determine the Java command to use to start the JVM.
+if [ -n "$JAVA_HOME" ] ; then
+ if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
+ # IBM's JDK on AIX uses strange locations for the executables
+ JAVACMD="$JAVA_HOME/jre/sh/java"
+ else
+ JAVACMD="$JAVA_HOME/bin/java"
+ fi
+ if [ ! -x "$JAVACMD" ] ; then
+ die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+ fi
+else
+ JAVACMD="java"
+ which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+
+Please set the JAVA_HOME variable in your environment to match the
+location of your Java installation."
+fi
+
+# Increase the maximum file descriptors if we can.
+if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
+ MAX_FD_LIMIT=`ulimit -H -n`
+ if [ $? -eq 0 ] ; then
+ if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
+ MAX_FD="$MAX_FD_LIMIT"
+ fi
+ ulimit -n $MAX_FD
+ if [ $? -ne 0 ] ; then
+ warn "Could not set maximum file descriptor limit: $MAX_FD"
+ fi
+ else
+ warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
+ fi
+fi
+
+# For Darwin, add options to specify how the application appears in the dock
+if $darwin; then
+ GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
+fi
+
+# For Cygwin, switch paths to Windows format before running java
+if $cygwin ; then
+ APP_HOME=`cygpath --path --mixed "$APP_HOME"`
+ CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
+
+ # We build the pattern for arguments to be converted via cygpath
+ ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
+ SEP=""
+ for dir in $ROOTDIRSRAW ; do
+ ROOTDIRS="$ROOTDIRS$SEP$dir"
+ SEP="|"
+ done
+ OURCYGPATTERN="(^($ROOTDIRS))"
+ # Add a user-defined pattern to the cygpath arguments
+ if [ "$GRADLE_CYGPATTERN" != "" ] ; then
+ OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
+ fi
+ # Now convert the arguments - kludge to limit ourselves to /bin/sh
+ i=0
+ for arg in "$@" ; do
+ CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
+ CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
+
+ if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
+ eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
+ else
+ eval `echo args$i`="\"$arg\""
+ fi
+ i=$((i+1))
+ done
+ case $i in
+ (0) set -- ;;
+ (1) set -- "$args0" ;;
+ (2) set -- "$args0" "$args1" ;;
+ (3) set -- "$args0" "$args1" "$args2" ;;
+ (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
+ (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
+ (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
+ (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
+ (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
+ (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
+ esac
+fi
+
+# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
+function splitJvmOpts() {
+ JVM_OPTS=("$@")
+}
+eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
+JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
+
+exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
diff --git a/android/YoPme/gradlew.bat b/android/YoPme/gradlew.bat
new file mode 100644
index 0000000000..8a0b282aa6
--- /dev/null
+++ b/android/YoPme/gradlew.bat
@@ -0,0 +1,90 @@
+@if "%DEBUG%" == "" @echo off
+@rem ##########################################################################
+@rem
+@rem Gradle startup script for Windows
+@rem
+@rem ##########################################################################
+
+@rem Set local scope for the variables with windows NT shell
+if "%OS%"=="Windows_NT" setlocal
+
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+set DEFAULT_JVM_OPTS=
+
+set DIRNAME=%~dp0
+if "%DIRNAME%" == "" set DIRNAME=.
+set APP_BASE_NAME=%~n0
+set APP_HOME=%DIRNAME%
+
+@rem Find java.exe
+if defined JAVA_HOME goto findJavaFromJavaHome
+
+set JAVA_EXE=java.exe
+%JAVA_EXE% -version >NUL 2>&1
+if "%ERRORLEVEL%" == "0" goto init
+
+echo.
+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:findJavaFromJavaHome
+set JAVA_HOME=%JAVA_HOME:"=%
+set JAVA_EXE=%JAVA_HOME%/bin/java.exe
+
+if exist "%JAVA_EXE%" goto init
+
+echo.
+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:init
+@rem Get command-line arguments, handling Windowz variants
+
+if not "%OS%" == "Windows_NT" goto win9xME_args
+if "%@eval[2+2]" == "4" goto 4NT_args
+
+:win9xME_args
+@rem Slurp the command line arguments.
+set CMD_LINE_ARGS=
+set _SKIP=2
+
+:win9xME_args_slurp
+if "x%~1" == "x" goto execute
+
+set CMD_LINE_ARGS=%*
+goto execute
+
+:4NT_args
+@rem Get arguments from the 4NT Shell from JP Software
+set CMD_LINE_ARGS=%$
+
+:execute
+@rem Setup the command line
+
+set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
+
+@rem Execute Gradle
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
+
+:end
+@rem End local scope for the variables with windows NT shell
+if "%ERRORLEVEL%"=="0" goto mainEnd
+
+:fail
+rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
+rem the _cmd.exe /c_ return code!
+if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
+exit /b 1
+
+:mainEnd
+if "%OS%"=="Windows_NT" endlocal
+
+:omega
diff --git a/android/YoPme/proguard-project.txt b/android/YoPme/proguard-project.txt
deleted file mode 100644
index f2fe1559a2..0000000000
--- a/android/YoPme/proguard-project.txt
+++ /dev/null
@@ -1,20 +0,0 @@
-# To enable ProGuard in your project, edit project.properties
-# to define the proguard.config property as described in that file.
-#
-# Add project specific ProGuard rules here.
-# By default, the flags in this file are appended to flags specified
-# in ${sdk.dir}/tools/proguard/proguard-android.txt
-# You can edit the include path and order by changing the ProGuard
-# include property in project.properties.
-#
-# For more details, see
-# http://developer.android.com/guide/developing/tools/proguard.html
-
-# Add any project specific keep options here:
-
-# If your project uses WebView with JS, uncomment the following
-# and specify the fully qualified class name to the JavaScript interface
-# class:
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
-# public *;
-#}
diff --git a/android/YoPme/project.properties b/android/YoPme/project.properties
deleted file mode 100644
index 0c93370d1f..0000000000
--- a/android/YoPme/project.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-# This file is automatically generated by Android Tools.
-# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
-#
-# This file must be checked in Version Control Systems.
-#
-# To customize properties used by the Ant build system edit
-# "ant.properties", and override values to adapt the script to your
-# project structure.
-#
-# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
-#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
-
-# Project target.
-target=Yota Platinum:Platinum Add-On:17
-android.library.reference.1=../3rd_party/yota_sdk
diff --git a/android/YoPme/settings.gradle b/android/YoPme/settings.gradle
new file mode 100644
index 0000000000..dd390fea0f
--- /dev/null
+++ b/android/YoPme/settings.gradle
@@ -0,0 +1,2 @@
+include ':yota_sdk'
+project(':yota_sdk').projectDir = new File(settingsDir, '../3rd_party/yota_sdk')
diff --git a/android/build.gradle b/android/build.gradle
index 360b69278e..6bb5644132 100644
--- a/android/build.gradle
+++ b/android/build.gradle
@@ -1,9 +1,231 @@
-// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
- repositories {
- mavenCentral()
- }
- dependencies {
- classpath 'com.android.tools.build:gradle:0.5.+'
- }
+ repositories {
+ mavenCentral()
+ }
+
+ dependencies {
+ classpath 'com.android.tools.build:gradle:0.9.2'
+ }
}
+
+apply plugin: 'android'
+
+dependencies {
+ compile propAndroidSupportLibrary, propGooglePlayServices
+ compile project(':3rd_party:external_styles')
+ compile project(':3rd_party:facebook-android-sdk:facebook')
+ compile fileTree(dir: '3rd_party', include: '*.jar')
+}
+
+def getDate() {
+ def date = new Date()
+ def formattedDate = date.format('yyMMdd')
+ return formattedDate
+}
+
+android {
+ // All properties are read from gradle.properties file
+ compileSdkVersion propTargetSdkVersion.toInteger()
+ buildToolsVersion propBuildToolsVersion
+
+ defaultConfig {
+ // Default package name is taken from the manifest and should be com.mapswithme.maps
+ versionCode propVersionCode.toInteger()
+ versionName propVersionName
+ minSdkVersion propMinSdkVersion.toInteger()
+ targetSdkVersion propTargetSdkVersion.toInteger()
+ }
+
+ sourceSets.main {
+ manifest.srcFile 'AndroidManifest.xml'
+ java.srcDirs = ['src']
+ res.srcDirs = ['res']
+ assets.srcDirs = ['assets']
+ }
+
+ flavorDimensions 'store'
+ productFlavors {
+ pro {
+ packageName 'com.mapswithme.maps.pro'
+ buildConfigField 'String', 'PRO_URL', '""' // Empty url string for the pro version
+ android.sourceSets.pro.setRoot('flavors/pro')
+ }
+
+ google {
+ flavorDimension 'store'
+ buildConfigField 'String', 'PRO_URL', '"market://details?id=com.mapswithme.maps.pro"'
+ android.sourceSets.google.setRoot('flavors/lite')
+ }
+
+ // Linked to the Pro version on Samsung Apps
+ samsung {
+ flavorDimension 'store'
+ packageName 'com.mapswithme.maps.samsung' // Custom package name for Samsung Lite version - due to historical reasons
+ buildConfigField 'String', 'PRO_URL', '"samsungapps://ProductDetail/com.mapswithme.maps.pro"'
+ android.sourceSets.samsung.setRoot('flavors/lite')
+ }
+
+ // Linked to the Pro version on Amazon Apps
+ amazon {
+ flavorDimension 'store'
+ buildConfigField 'String', 'PRO_URL', '"amzn://apps/android?p=com.mapswithme.maps.pro"'
+ android.sourceSets.amazon.setRoot('flavors/lite')
+ }
+
+ // Linked to the Pro version on AndroidPit store
+ androidpit {
+ flavorDimension 'store'
+ buildConfigField 'String', 'PRO_URL', '"appcenter://package/com.mapswithme.maps.pro"'
+ android.sourceSets.androidpit.setRoot('flavors/lite')
+ }
+ // Linked to the Pro version on SlideMe store
+ slideme {
+ flavorDimension 'store'
+ buildConfigField 'String', 'PRO_URL', '"sam://details?bundleId=5eed1b74-8c8b-11e2-8af8-1670ef61174f"'
+ android.sourceSets.slideme.setRoot('flavors/lite')
+ }
+
+ // Linked to the Pro version on Yandex store
+ yandex {
+ flavorDimension 'store'
+ buildConfigField 'String', 'PRO_URL', '"yastore://details?id=com.mapswithme.maps.pro"'
+ android.sourceSets.yandex.setRoot('flavors/lite')
+ }
+ }
+
+ // TODO: Fix a lot of lint errors in our code
+ lintOptions {
+ abortOnError false
+ }
+
+ applicationVariants.all { variant ->
+ // This is an annoying hack to get around the fact that the Gradle plugin does not support
+ // having libraries with different minSdkVersions. Play Services has a min version of 9 but we support 7 still
+ variant.processManifest.doFirst {
+ File manifestFile = file("${buildDir}/exploded-aar/com.google.android.gms/play-services/4.3.23/AndroidManifest.xml")
+ if (manifestFile.exists()) {
+ println("Replacing minSdkVersion in Google Play Services")
+ String content = manifestFile.getText('UTF-8')
+ content = content.replaceAll(/minSdkVersion="9"/, 'minSdkVersion=\"7\"')
+ manifestFile.write(content, 'UTF-8')
+ println(content)
+ }
+ }
+
+ // Also add version at the end of each built apk
+ def file = variant.outputFile
+ variant.outputFile = new File(file.parent, file.name.replace(".apk", "-" + defaultConfig.versionName + "-" + getDate() + ".apk"))
+ }
+
+ signingConfigs {
+ mapswithme {
+ storeFile file('../tools/android/mapswithme.keystore')
+ storePassword '***REMOVED***'
+ keyAlias 'mapswithme'
+ keyPassword '***REMOVED***'
+ }
+
+ yopme {
+ storeFile file('YopMe/key/android.keystore')
+ storePassword '***REMOVED***'
+ keyAlias 'yopme'
+ keyPassword '***REMOVED***'
+ }
+ }
+
+ buildTypes {
+ debug {
+ packageNameSuffix '.debug' // Allows to install debug and release builds together
+ versionNameSuffix '-debug'
+ jniDebugBuild true // Enable jni debug build
+ }
+
+ release {
+ signingConfig signingConfigs.mapswithme
+ }
+
+ beta {
+ packageNameSuffix '.beta'
+ versionNameSuffix '-beta'
+ signingConfig signingConfigs.mapswithme
+ }
+ }
+
+ // We don't compress these extensions in assets/ because our random FileReader can't read zip-compressed files from apk
+ aaptOptions {
+ noCompress 'txt', 'bin', 'skn', 'html', 'png', 'json', 'mwm', 'ttf'
+ ignoreAssetsPattern "!.svn:!.git:!.DS_Store:!*.scc:.*:_*:!CVS:!thumbs.db:!picasa.ini:!*~"
+ }
+
+ // Enables new Java features in KitKat+ but needs Java 1.7 installed
+ //compileOptions {
+ // sourceCompatibility JavaVersion.VERSION_1_7
+ // targetCompatibility JavaVersion.VERSION_1_7
+ //}
+}
+
+
+//@{ Below are tasks needed to compile our NDK part
+apply plugin:'base'
+
+task cppLibsBuildDebug(type:Exec, description: 'Building DEBUG version of static C++ libraries') {
+ commandLine 'bash', '../tools/autobuild/android.sh', 'debug'
+}
+
+task cppLibsBuildRelease(type:Exec, description: 'Building RELEASE/PRODUCTION version of static C++ libraries') {
+ commandLine 'bash', '../tools/autobuild/android.sh', 'production'
+}
+
+def NUM_OF_PARALLEL_MAKE_TASKS = Runtime.runtime.availableProcessors() + 1
+Properties properties = new Properties()
+properties.load(project.rootProject.file('local.properties').newDataInputStream())
+def NDK_BUILD = properties.getProperty('ndk.dir') + '/ndk-build'
+
+task ndkBuildDebug(type:Exec, dependsOn: 'cppLibsBuildDebug', description: 'Building DEBUG jni sources') {
+ def clArgs = ([NDK_BUILD, '-j' + NUM_OF_PARALLEL_MAKE_TASKS] + propDebugNdkFlags.split(' ')).flatten()
+ commandLine clArgs
+}
+
+task ndkBuildRelease(type:Exec, dependsOn: 'cppLibsBuildRelease', description: 'Building RELEASE/PRODUCTION jni sources') {
+ def clArgs = ([NDK_BUILD, '-j' + NUM_OF_PARALLEL_MAKE_TASKS] + propReleaseNdkFlags.split(' ')).flatten()
+ commandLine clArgs
+}
+
+task ndkBuildClean(type:Exec, description: 'Clean native libraries') {
+ commandLine NDK_BUILD, 'clean'
+}
+
+// This one is needed for clean task
+task copyNativeLibs(type:Copy, description: 'Copy native libraries') {
+ from(new File('libs')) { include '**/*.so' }
+ into new File(buildDir, 'native-libs')
+}
+
+// TODO: avoid copypaste and resolve tasks dependencies in more convenient way
+task copyNativeLibsRelease(type:Copy, dependsOn: ndkBuildRelease, description: 'Copy native libraries') {
+ from(new File('libs')) { include '**/*.so' }
+ into new File(buildDir, 'native-libs')
+}
+
+task copyNativeLibsDebug(type:Copy, dependsOn: ndkBuildDebug, description: 'Copy native libraries') {
+ from(new File('libs')) { include '**/*.so' }
+ into new File(buildDir, 'native-libs')
+}
+
+tasks.withType(Compile) { compileTask ->
+ if (compileTask.name.contains('Release')) {
+ compileTask.dependsOn copyNativeLibsRelease
+ } else {
+ compileTask.dependsOn copyNativeLibsDebug
+ }
+}
+
+clean.dependsOn 'cleanCopyNativeLibs'
+clean.dependsOn 'ndkBuildClean'
+
+tasks.withType(com.android.build.gradle.tasks.PackageApplication) { pkgTask ->
+ pkgTask.jniFolders = new HashSet()
+ pkgTask.jniFolders.add(new File(buildDir, 'native-libs'))
+}
+
+//@} End of tasks needed to compile our NDK part
diff --git a/android/build.xml b/android/build.xml
deleted file mode 100644
index 3a927c5b45..0000000000
--- a/android/build.xml
+++ /dev/null
@@ -1,98 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/change_version.sh b/android/change_version.sh
deleted file mode 100755
index 2e43ab2f71..0000000000
--- a/android/change_version.sh
+++ /dev/null
@@ -1,41 +0,0 @@
-#!/bin/bash
-##########################################
-#
-# This script changes version code and version name in AndroidManifest.xml.
-# Must be run from omim/android directory.
-#
-##########################################
-
-while :
-do
- case $1 in
- -h)
- echo "Usage: change_version.sh -vn -vc "
- exit 0
- ;;
- -vn)
- VERSION_NAME=$2
- echo "Version name: $VERSION_NAME"
- shift 2
- ;;
- -vc)
- VERSION_CODE=$2
- echo "Version code: $VERSION_CODE"
- shift 2
- ;;
- *) # no more options
- break
- ;;
- esac
-done
-
-set -e -u -x
-
-AM_DIRS=(MapsWithMeLite MapsWithMeLite.Samsung MapsWithMePro MapsWithMeTest)
-for DIR in ${AM_DIRS[*]}
-do
- sed -i '' "s/versionName=\"[0-9\.]*\"/versionName=\"${VERSION_NAME}\"/g" \
- ${DIR}/AndroidManifest.xml
- sed -i '' "s/versionCode=\"[0-9]*\"/versionCode=\"${VERSION_CODE}\"/g" \
- ${DIR}/AndroidManifest.xml
-done
diff --git a/android/common_custom_rules.xml b/android/common_custom_rules.xml
deleted file mode 100644
index 44d341e437..0000000000
--- a/android/common_custom_rules.xml
+++ /dev/null
@@ -1,100 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/custom_rules.xml b/android/custom_rules.xml
deleted file mode 100644
index bfea1bef6d..0000000000
--- a/android/custom_rules.xml
+++ /dev/null
@@ -1,118 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- *************************************************
- **** Android Manifest has debuggable=true ****
- ** Doing DEBUG packaging with PRODUCTION keys ***
- *************************************************
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Signing final apk...
-
-
-
-
- Release Package: ${out.final.file}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/android/flavors/lite/AndroidManifest.xml b/android/flavors/lite/AndroidManifest.xml
new file mode 100644
index 0000000000..b4eed2e7cf
--- /dev/null
+++ b/android/flavors/lite/AndroidManifest.xml
@@ -0,0 +1,73 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/android/MapsWithMeLite/res/values/fb.xml b/android/flavors/lite/res/values/fb.xml
similarity index 100%
rename from android/MapsWithMeLite/res/values/fb.xml
rename to android/flavors/lite/res/values/fb.xml
diff --git a/android/MapsWithMeLite/res/values/mat.xml b/android/flavors/lite/res/values/mat.xml
similarity index 100%
rename from android/MapsWithMeLite/res/values/mat.xml
rename to android/flavors/lite/res/values/mat.xml
diff --git a/android/MapsWithMeLite.Samsung/res/values/strings.xml b/android/flavors/lite/res/values/strings.xml
similarity index 100%
rename from android/MapsWithMeLite.Samsung/res/values/strings.xml
rename to android/flavors/lite/res/values/strings.xml
diff --git a/android/flavors/pro/AndroidManifest.xml b/android/flavors/pro/AndroidManifest.xml
new file mode 100644
index 0000000000..5ab01fe886
--- /dev/null
+++ b/android/flavors/pro/AndroidManifest.xml
@@ -0,0 +1,111 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/android/MapsWithMePro/res/drawable-hdpi/ic_launcher.png b/android/flavors/pro/res/drawable-hdpi/ic_launcher.png
similarity index 100%
rename from android/MapsWithMePro/res/drawable-hdpi/ic_launcher.png
rename to android/flavors/pro/res/drawable-hdpi/ic_launcher.png
diff --git a/android/MapsWithMePro/res/drawable-ldpi/ic_launcher.png b/android/flavors/pro/res/drawable-ldpi/ic_launcher.png
similarity index 100%
rename from android/MapsWithMePro/res/drawable-ldpi/ic_launcher.png
rename to android/flavors/pro/res/drawable-ldpi/ic_launcher.png
diff --git a/android/MapsWithMePro/res/drawable-mdpi/ic_launcher.png b/android/flavors/pro/res/drawable-mdpi/ic_launcher.png
similarity index 100%
rename from android/MapsWithMePro/res/drawable-mdpi/ic_launcher.png
rename to android/flavors/pro/res/drawable-mdpi/ic_launcher.png
diff --git a/android/MapsWithMePro/res/drawable-xhdpi/ic_launcher.png b/android/flavors/pro/res/drawable-xhdpi/ic_launcher.png
similarity index 100%
rename from android/MapsWithMePro/res/drawable-xhdpi/ic_launcher.png
rename to android/flavors/pro/res/drawable-xhdpi/ic_launcher.png
diff --git a/android/MapsWithMePro/res/drawable-xxhdpi/ic_launcher.png b/android/flavors/pro/res/drawable-xxhdpi/ic_launcher.png
similarity index 100%
rename from android/MapsWithMePro/res/drawable-xxhdpi/ic_launcher.png
rename to android/flavors/pro/res/drawable-xxhdpi/ic_launcher.png
diff --git a/android/MapsWithMePro/res/values/fb.xml b/android/flavors/pro/res/values/fb.xml
similarity index 100%
rename from android/MapsWithMePro/res/values/fb.xml
rename to android/flavors/pro/res/values/fb.xml
diff --git a/android/MapsWithMePro/res/values/mat.xml b/android/flavors/pro/res/values/mat.xml
similarity index 100%
rename from android/MapsWithMePro/res/values/mat.xml
rename to android/flavors/pro/res/values/mat.xml
diff --git a/android/MapsWithMePro/res/values/strings.xml b/android/flavors/pro/res/values/strings.xml
similarity index 74%
rename from android/MapsWithMePro/res/values/strings.xml
rename to android/flavors/pro/res/values/strings.xml
index eaa5dd7b53..3a81555cfd 100644
--- a/android/MapsWithMePro/res/values/strings.xml
+++ b/android/flavors/pro/res/values/strings.xml
@@ -1,5 +1,4 @@
- MapsWithMe
***REMOVED***
diff --git a/android/gradle.properties b/android/gradle.properties
new file mode 100644
index 0000000000..a0f85c6ed6
--- /dev/null
+++ b/android/gradle.properties
@@ -0,0 +1,9 @@
+propMinSdkVersion=7
+propTargetSdkVersion=19
+propBuildToolsVersion=19.0.3
+propVersionCode=263
+propVersionName=2.6.3
+propDebugNdkFlags=V=1 NDK_DEBUG=1 DEBUG=1
+propReleaseNdkFlags=V=1 NDK_DEBUG=0 PRODUCTION=1
+propAndroidSupportLibrary=com.android.support:support-v4:19.1.+
+propGooglePlayServices=com.google.android.gms:play-services:4.3.+
\ No newline at end of file
diff --git a/android/gradle/wrapper/gradle-wrapper.jar b/android/gradle/wrapper/gradle-wrapper.jar
index 8c0fb64a86..3c7abdf127 100644
Binary files a/android/gradle/wrapper/gradle-wrapper.jar and b/android/gradle/wrapper/gradle-wrapper.jar differ
diff --git a/android/gradle/wrapper/gradle-wrapper.properties b/android/gradle/wrapper/gradle-wrapper.properties
index 5c22dec064..06b73ae6f0 100644
--- a/android/gradle/wrapper/gradle-wrapper.properties
+++ b/android/gradle/wrapper/gradle-wrapper.properties
@@ -1,6 +1,6 @@
-#Wed Apr 10 15:27:10 PDT 2013
+#Thu Apr 24 20:54:57 FET 2014
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
-distributionUrl=http\://services.gradle.org/distributions/gradle-1.6-bin.zip
+distributionUrl=http\://services.gradle.org/distributions/gradle-1.11-bin.zip
diff --git a/android/gradlew.bat b/android/gradlew.bat
new file mode 100644
index 0000000000..8a0b282aa6
--- /dev/null
+++ b/android/gradlew.bat
@@ -0,0 +1,90 @@
+@if "%DEBUG%" == "" @echo off
+@rem ##########################################################################
+@rem
+@rem Gradle startup script for Windows
+@rem
+@rem ##########################################################################
+
+@rem Set local scope for the variables with windows NT shell
+if "%OS%"=="Windows_NT" setlocal
+
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
+set DEFAULT_JVM_OPTS=
+
+set DIRNAME=%~dp0
+if "%DIRNAME%" == "" set DIRNAME=.
+set APP_BASE_NAME=%~n0
+set APP_HOME=%DIRNAME%
+
+@rem Find java.exe
+if defined JAVA_HOME goto findJavaFromJavaHome
+
+set JAVA_EXE=java.exe
+%JAVA_EXE% -version >NUL 2>&1
+if "%ERRORLEVEL%" == "0" goto init
+
+echo.
+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:findJavaFromJavaHome
+set JAVA_HOME=%JAVA_HOME:"=%
+set JAVA_EXE=%JAVA_HOME%/bin/java.exe
+
+if exist "%JAVA_EXE%" goto init
+
+echo.
+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
+echo.
+echo Please set the JAVA_HOME variable in your environment to match the
+echo location of your Java installation.
+
+goto fail
+
+:init
+@rem Get command-line arguments, handling Windowz variants
+
+if not "%OS%" == "Windows_NT" goto win9xME_args
+if "%@eval[2+2]" == "4" goto 4NT_args
+
+:win9xME_args
+@rem Slurp the command line arguments.
+set CMD_LINE_ARGS=
+set _SKIP=2
+
+:win9xME_args_slurp
+if "x%~1" == "x" goto execute
+
+set CMD_LINE_ARGS=%*
+goto execute
+
+:4NT_args
+@rem Get arguments from the 4NT Shell from JP Software
+set CMD_LINE_ARGS=%$
+
+:execute
+@rem Setup the command line
+
+set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
+
+@rem Execute Gradle
+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
+
+:end
+@rem End local scope for the variables with windows NT shell
+if "%ERRORLEVEL%"=="0" goto mainEnd
+
+:fail
+rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
+rem the _cmd.exe /c_ return code!
+if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
+exit /b 1
+
+:mainEnd
+if "%OS%"=="Windows_NT" endlocal
+
+:omega
diff --git a/android/prepare_release.sh b/android/prepare_release.sh
deleted file mode 100755
index 588e1b4fff..0000000000
--- a/android/prepare_release.sh
+++ /dev/null
@@ -1,68 +0,0 @@
-#!/bin/bash
-
-set -e -u -x
-
-OUTPUT_DIR=RELEASE
-# clean up output
-mkdir -p $OUTPUT_DIR
-rm $OUTPUT_DIR/* || true
-
-# create version tag
-VERSION=$1
-DATE=$(date "+%y%m%d")
-VERSION_TAG=$(echo "$VERSION-$DATE")
-
-echo "Build as: $VERSION $OUTPUT_DIR $DATE"
-
-##
-# Clean targets once
-##
-CLEAN_DIRS=(MapsWithMeLite MapsWithMeLite.Samsung MapsWithMePro)
-for DIR in ${CLEAN_DIRS[*]}
- do
- pushd $DIR
- ant clean
- popd
- done
-
-##
-# MapsWithMeLite: Google, Amazon, Yandex, SlideMe, AndroidPit
-##
-SOURCE_DIR=MapsWithMeLite
-LITE_TARGETS=(google amazon yandex slideme androidpit)
-BASE_NAME=MapsWithMeLite
-
-pushd $SOURCE_DIR
- for TARGET in ${LITE_TARGETS[*]}
- do
- ant ${TARGET}-production
- SRC_NAME=${BASE_NAME}-${TARGET}-production.apk
- DEST_NAME=${BASE_NAME}-${VERSION_TAG}-${TARGET}.apk
- cp bin/$SRC_NAME ../$OUTPUT_DIR/$DEST_NAME
- done
-popd
-
-##
-# MapsWithMeLite: Samsung
-##
-SOURCE_DIR=MapsWithMeLite.Samsung
-TARGET=samsung
-pushd $SOURCE_DIR
- ant ${TARGET}-production
- NAME=$(echo "${BASE_NAME}-${VERSION_TAG}-${TARGET}")
- cp bin/*-production.apk ../$OUTPUT_DIR/${NAME}.apk
-popd
-
-##
-# MapsWithMePro: common version
-##
-SOURCE_DIR=MapsWithMePro
-BASE_NAME=MapsWithMePro
-pushd $SOURCE_DIR
- ant production
- NAME=$(echo "${BASE_NAME}-${VERSION_TAG}")
- cp bin/*-production.apk ../$OUTPUT_DIR/${NAME}.apk
-popd
-
-echo "Builded!"
-ls -lh $OUTPUT_DIR
diff --git a/android/proguard.cfg b/android/proguard.cfg
deleted file mode 100644
index 4dc32b1029..0000000000
--- a/android/proguard.cfg
+++ /dev/null
@@ -1,36 +0,0 @@
--optimizationpasses 5
--dontusemixedcaseclassnames
--dontskipnonpubliclibraryclasses
--dontpreverify
--verbose
--optimizations !code/simplification/arithmetic,!field/*,!class/merging/*
-
--keep public class * extends android.app.Activity
--keep public class * extends android.app.Application
--keep public class * extends android.app.Service
--keep public class * extends android.content.BroadcastReceiver
--keep public class * extends android.content.ContentProvider
--keep public class * extends android.app.backup.BackupAgentHelper
--keep public class * extends android.preference.Preference
--keep public class com.android.vending.licensing.ILicensingService
-
--keepclasseswithmembers class * {
- native ;
-}
-
--keepclasseswithmembers class * {
- public (android.content.Context, android.util.AttributeSet);
-}
-
--keepclasseswithmembers class * {
- public (android.content.Context, android.util.AttributeSet, int);
-}
-
--keepclassmembers enum * {
- public static **[] values();
- public static ** valueOf(java.lang.String);
-}
-
--keep class * implements android.os.Parcelable {
- public static final android.os.Parcelable$Creator *;
-}
diff --git a/android/project.properties b/android/project.properties
deleted file mode 100644
index 889aa4479c..0000000000
--- a/android/project.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-# This file is automatically generated by Android Tools.
-# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
-#
-# This file must be checked in Version Control Systems.
-#
-# To customize properties used by the Ant build system use,
-# "ant.properties", and override values to adapt the script to your
-# project structure.
-
-# Project target.
-target=android-19
-android.library=true
-android.library.reference.1=3rd_party/facebook-android-sdk/facebook
-android.library.reference.2=3rd_party/external_styles
-android.library.reference.3=3rd_party/google-play-services_lib
diff --git a/android/res/values/fb.xml b/android/res/values/fb.xml
deleted file mode 100644
index 7d0b1edd49..0000000000
--- a/android/res/values/fb.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
- NOT_REALLY_KEY
-
\ No newline at end of file
diff --git a/android/res/values/mat.xml b/android/res/values/mat.xml
deleted file mode 100644
index 382066987c..0000000000
--- a/android/res/values/mat.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
- FALSE
- FALSE
-
\ No newline at end of file
diff --git a/android/res/values/styles.xml b/android/res/values/styles.xml
index 5639d9f36e..7eb5f2c2df 100644
--- a/android/res/values/styles.xml
+++ b/android/res/values/styles.xml
@@ -1,6 +1,8 @@
+
+
sans-serif-light
"sans-serif"
diff --git a/android/settings.gradle b/android/settings.gradle
index 8176d8e18c..04d3d978e8 100644
--- a/android/settings.gradle
+++ b/android/settings.gradle
@@ -1,3 +1 @@
-include ':YoPme'
-include ':3rd_party:api-android:lib'
-include ':3rd_party:yota_sdk'
+include ':3rd_party:external_styles', ':3rd_party:facebook-android-sdk:facebook'
\ No newline at end of file
diff --git a/android/src/com/mapswithme/maps/MWMApplication.java b/android/src/com/mapswithme/maps/MWMApplication.java
index aa3e16346c..fdeb1d01ef 100644
--- a/android/src/com/mapswithme/maps/MWMApplication.java
+++ b/android/src/com/mapswithme/maps/MWMApplication.java
@@ -14,6 +14,7 @@ import android.os.Environment;
import android.util.Log;
import android.widget.Toast;
+import com.mapswithme.maps.BuildConfig;
import com.mapswithme.maps.MapStorage.Index;
import com.mapswithme.maps.background.Notifier;
import com.mapswithme.maps.bookmarks.data.BookmarkManager;
@@ -121,24 +122,8 @@ public class MWMApplication extends android.app.Application implements MapStorag
// get url for PRO version
if (!m_isPro)
{
- final AssetManager assets = getAssets();
- InputStream stream = null;
- try
- {
- stream = assets.open("app_info.txt");
- final BufferedReader reader = new BufferedReader(new InputStreamReader(stream));
-
- final String s = reader.readLine();
- if (s.length() > 0)
- m_proVersionURL = s;
-
- Log.i(TAG, "Pro version url: " + m_proVersionURL);
- }
- catch (final IOException ex)
- {
- // suppress exceptions - pro version doesn't need app_info.txt
- }
- Utils.closeStream(stream);
+ m_proVersionURL = BuildConfig.PRO_URL;
+ Log.i(TAG, "Pro version url: " + m_proVersionURL);
}
final String extStoragePath = getDataStoragePath();
diff --git a/tools/android/aapt b/tools/android/aapt
deleted file mode 100755
index 72972262d9..0000000000
--- a/tools/android/aapt
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/bash
-
-# This script should replace original aapt tool,
-# which should be renamed to aapt2, see below:
-
-# Main purpose is transparently disable compression
-# for given file types inside .zip (.apk) file
-
-${0}2 "$@" -0 txt -0 bin -0 skn -0 html -0 png -0 json -0 mwm -0 ttf
diff --git a/tools/android/aapt.exe b/tools/android/aapt.exe
deleted file mode 100644
index 21e94a99dd..0000000000
Binary files a/tools/android/aapt.exe and /dev/null differ
diff --git a/tools/android/set_up_android.py b/tools/android/set_up_android.py
index 363a369470..2a7551ba1e 100755
--- a/tools/android/set_up_android.py
+++ b/tools/android/set_up_android.py
@@ -36,28 +36,6 @@ def update_assets():
return os.system('./update_assets.sh')
-def replace_aapt(sdkDir, oldAaptName='aapt2'):
- buildToolsPath = os.path.join(sdkDir, 'build-tools')
- # Build tools now are in different folders for each version
- for buildToolsVersion in os.listdir(buildToolsPath):
- if not os.path.isdir(os.path.join(buildToolsPath, buildToolsVersion)):
- continue
- aaptPath = os.path.join(buildToolsPath, buildToolsVersion, 'aapt')
- aaptRealPath = os.path.join(buildToolsPath, buildToolsVersion, oldAaptName)
-
- # handle case of non-existing file
- if not os.path.exists(aaptRealPath):
- os.rename(aaptPath, aaptRealPath)
- else:
- print 'aapt2 already exists, skipping'
-
- # copy new hacked aapt version
- curDir = os.getcwd()
- hackedAaptPath = os.path.join(curDir, 'aapt')
- print 'hacked path; %s' % hackedAaptPath
- print 'copied: %s' % shutil.copy(hackedAaptPath, aaptPath)
-
-
def write_local_properties(sdkDir, ndkDir):
locPropsContent = ('# Autogenerated file\n' +
'# Do not add it to version control\n' +
@@ -74,10 +52,9 @@ def write_local_properties(sdkDir, ndkDir):
file.close()
# copy files to folders
- subfolders = ['MapsWithMeLite', 'MapsWithMeLite.Samsung', 'MapsWithMePro',
- '3rd_party/external_styles',
- '3rd_party/facebook-android-sdk/facebook',
- '3rd_party/google-play-services_lib']
+ subfolders = ['YoPme',
+ '3rd_party/external_styles',
+ '3rd_party/facebook-android-sdk/facebook']
for folder in subfolders:
dst = os.path.join(androidRoot, folder, 'local.properties')
@@ -110,8 +87,6 @@ def run():
sdkDir = locate_sdk(sdk)
ndkDir = locate_ndk(ndk)
- print '>>> Replacing aapt'
- replace_aapt(sdkDir)
print '>>> Updating assets'
update_assets()
print '>>> Writing local.properties'
diff --git a/tools/android/update_assets.sh b/tools/android/update_assets.sh
index d3545f32c0..8fbc83eaca 100755
--- a/tools/android/update_assets.sh
+++ b/tools/android/update_assets.sh
@@ -1,5 +1,2 @@
-./update_assets_for_version.sh ../../android/MapsWithMePro/assets
-./update_assets_for_version.sh ../../android/MapsWithMeLite/assets
-./update_assets_for_version.sh ../../android/MapsWithMeLite.Samsung/assets
-
+./update_assets_for_version.sh ../../android/assets
./update_flags.sh
diff --git a/tools/android/update_assets_for_version.sh b/tools/android/update_assets_for_version.sh
index 4530fac6e9..a0fdbc7217 100755
--- a/tools/android/update_assets_for_version.sh
+++ b/tools/android/update_assets_for_version.sh
@@ -1,7 +1,7 @@
#!/bin/bash
set -x -u
-SRC=../../../data
+SRC=../../data
DST=$1
# Remove old links