Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android Support Library 41: error compiling #168

Closed
vaprea opened this issue Jan 9, 2017 · 26 comments
Closed

Android Support Library 41: error compiling #168

vaprea opened this issue Jan 9, 2017 · 26 comments
Labels
more info needed Further information is requested. If not provided, issue will be closed

Comments

@vaprea
Copy link

vaprea commented Jan 9, 2017

Hi,
i receive the following error compiling the project with Android Support Library version 41:
Error retrieving parent for item: No resource found that matches the given name 'android:TextAppearance.Material.Widget.Button.Borderless.Colored'.

Tnx

@dpa99c
Copy link
Owner

dpa99c commented Jan 9, 2017

Check target SDK version is 23 or above and that Android Support Library is up-to-date in Android SDK manager.

Check what version of cordova-android platform is installed: cordova platform ls.
The version must be 5 or greater, so if not: cordova platform rm android && cordova platform add android@5

See #87.

@dpa99c
Copy link
Owner

dpa99c commented Jan 9, 2017

See also #161

@vaprea
Copy link
Author

vaprea commented Jan 9, 2017

android 5.2.2

Support Library is the last available: 41
With previous version 40 everything was ok

@vaprea
Copy link
Author

vaprea commented Jan 9, 2017

If i use a specific version of support library replacing
<framework src="com.android.support:appcompat-v7:+" />
it works

@dpa99c
Copy link
Owner

dpa99c commented Jan 9, 2017

As you can see in #161, I was able to reproduce the issue with [email protected] - updating to latest cordova-android resolved the issue. Latest release is currently [email protected]

@vaprea
Copy link
Author

vaprea commented Jan 9, 2017

Tnx

@dpa99c
Copy link
Owner

dpa99c commented Jan 9, 2017

Let me know/close the issue if that works

@vaprea vaprea closed this as completed Jan 9, 2017
@vaprea vaprea reopened this Jan 9, 2017
@vaprea
Copy link
Author

vaprea commented Jan 9, 2017

Sorry but it doesn't works with latest [email protected], same error

@dpa99c
Copy link
Owner

dpa99c commented Jan 12, 2017

I'm not able to reproduce the issue with [email protected] - see the build output below:

build output

D:\Git\cordova-diagnostic-plugin-example>cordova -v
6.4.0

D:\Git\cordova-diagnostic-plugin-example>%ANDROID_HOME%\tools\bin\sdkmanager
--list
Installed packages:
  Path                              | Version | Description
     | Location
  -------                           | ------- | -------
     | -------
  add-ons;addon-g..._apis-google-15 | 3.0.0   | Google APIs, Android 15, rev
3    | add-ons\addon-g...apis-google-15\
  add-ons;addon-g..._apis-google-16 | 4.0.0   | Google APIs, Android 16, rev
4    | add-ons\addon-g...apis-google-16\
  add-ons;addon-g..._apis-google-17 | 4.0.0   | Google APIs, Android 17, rev
4    | add-ons\addon-g...apis-google-17\
  add-ons;addon-g..._apis-google-18 | 4.0.0   | Google APIs, Android 18, rev
4    | add-ons\addon-g...apis-google-18\
  add-ons;addon-g..._apis-google-21 | 1.0.0   | Google APIs, Android 21
     | add-ons\addon-g...apis-google-21\
  add-ons;addon-g..._apis-google-22 | 1.0.0   | Google APIs, Android 22
     | add-ons\addon-g...apis-google-22\
  add-ons;addon-g..._apis-google-23 | 1.0.0   | Google APIs, Android 23
     | add-ons\addon-g...apis-google-23\
  add-ons;addon-g...s_x86-google-19 | 18.0.0  | Google APIs (x86 System Image)... | add-ons\addon-g..._x86-google-19\
  build-tools;23.0.1                | 23.0.1  | Android SDK Build-Tools 23.0.1    | build-tools\23.0.1\
  build-tools;23.0.2                | 23.0.2  | Android SDK Build-Tools 23.0.2    | build-tools\23.0.2\
  build-tools;25.0.2                | 25.0.2  | Android SDK Build-Tools 25.0.2    | build-tools\25.0.2\
  docs                              | 1       | Documentation for Android SDK     | docs\
  extras;android;m2repository       | 41.0.0  | Android Support Repository, re... | extras\android\m2repository\
  extras;android;support            | 23.2.1  | Android Support Library, rev
2... | extras\android\support\
  extras;google;g...e_play_services | 38      | Google Play services
     | extras\google\g..._play_services\
  extras;google;m2repository        | 41.0.0  | Google Repository, rev 41
     | extras\google\m2repository\
  extras;google;usb_driver          | 11.0.0  | Google USB Driver, rev 11
     | extras\google\usb_driver\
  extras;intel;Ha...ecution_Manager | 6.0.5   | Intel x86 Emulator Accelerator... | extras\intel\Ha...cution_Manager\
  patcher;v4                        | 1       | SDK Patch Applier v4
     | patcher\v4\
  platform-tools                    | 25.0.3  | Android SDK Platform-Tools 25.0.3 | platform-tools\
  platforms;android-10              | 2       | Android SDK Platform 10, rev
2    | platforms\android-10\
  platforms;android-15              | 5       | Android SDK Platform 15, rev
5    | platforms\android-15\
  platforms;android-16              | 5       | Android SDK Platform 16, rev
5    | platforms\android-16\
  platforms;android-17              | 3       | Android SDK Platform 17, rev
3    | platforms\android-17\
  platforms;android-18              | 3       | Android SDK Platform 18, rev
3    | platforms\android-18\
  platforms;android-19              | 4       | Android SDK Platform 19, rev
4    | platforms\android-19\
  platforms;android-21              | 2       | Android SDK Platform 21, rev
2    | platforms\android-21\
  platforms;android-22              | 2       | Android SDK Platform 22, rev
2    | platforms\android-22\
  platforms;android-23              | 3       | Android SDK Platform 23, rev
3    | platforms\android-23\
  platforms;android-24              | 2       | Android SDK Platform 24
     | platforms\android-24\
  platforms;android-25              | 3       | Android SDK Platform 25
     | platforms\android-25\
  sources;android-21                | 1       | Sources for Android 21
     | sources\android-21\
  sources;android-23                | 1       | Sources for Android 23
     | sources\android-23\
  system-images;a...ult;armeabi-v7a | 4       | ARM EABI v7a System Image
     | system-images\a...lt\armeabi-v7a\
  system-images;a...-15;default;x86 | 4       | Intel x86 Atom System Image
     | system-images\a...15\default\x86\
  system-images;a...-16;default;x86 | 5       | Intel x86 Atom System Image
     | system-images\a...16\default\x86\
  system-images;a...-17;default;x86 | 3       | Intel x86 Atom System Image
     | system-images\a...17\default\x86\
  system-images;a...ult;armeabi-v7a | 4       | ARM EABI v7a System Image
     | system-images\a...lt\armeabi-v7a\
  system-images;a...-18;default;x86 | 3       | Intel x86 Atom System Image
     | system-images\a...18\default\x86\
  system-images;a...-19;default;x86 | 5       | Intel x86 Atom System Image
     | system-images\a...19\default\x86\
  system-images;a...;default;x86_64 | 4       | Intel x86 Atom_64 System Image    | system-images\a...default\x86_64\
  system-images;a...google_apis;x86 | 18      | Google APIs Intel x86 Atom Sys... | system-images\a...oogle_apis\x86\
  system-images;a...gle_apis;x86_64 | 18      | Google APIs Intel x86 Atom_64 ... | system-images\a...le_apis\x86_64\
  system-images;a...gle_apis;x86_64 | 12      | Google APIs Intel x86 Atom_64 ... | system-images\a...le_apis\x86_64\
  system-images;a...;default;x86_64 | 9       | Intel x86 Atom_64 System Image    | system-images\a...default\x86_64\
  system-images;a...google_apis;x86 | 19      | Google APIs Intel x86 Atom Sys... | system-images\a...oogle_apis\x86\
  system-images;a...gle_apis;x86_64 | 19      | Google APIs Intel x86 Atom_64 ... | system-images\a...le_apis\x86_64\
  system-images;a...;default;x86_64 | 7       | Intel x86 Atom_64 System Image    | system-images\a...default\x86_64\
  system-images;a...gle_apis;x86_64 | 3       | Google APIs Intel x86 Atom_64 ... | system-images\a...le_apis\x86_64\
  tools                             | 25.2.4  | Android SDK Tools 25.2.4
     | tools\

Available Packages:
  Path                              | Version      | Description

  -------                           | -------      | -------

  add-ons;addon-g..._apis-google-15 | 3            | Google APIs

  add-ons;addon-g..._apis-google-16 | 4            | Google APIs

  add-ons;addon-g..._apis-google-17 | 4            | Google APIs

  add-ons;addon-g..._apis-google-18 | 4            | Google APIs

  add-ons;addon-g..._apis-google-19 | 20           | Google APIs

  add-ons;addon-g..._apis-google-21 | 1            | Google APIs

  add-ons;addon-g..._apis-google-22 | 1            | Google APIs

  add-ons;addon-g..._apis-google-23 | 1            | Google APIs

  add-ons;addon-g..._apis-google-24 | 1            | Google APIs

  add-ons;addon-g...e_gdk-google-19 | 11           | Glass Development Kit Preview
  build-tools;19.1.0                | 19.1.0       | Android SDK Build-Tools
19.1
  build-tools;20.0.0                | 20.0.0       | Android SDK Build-Tools
20
  build-tools;21.1.2                | 21.1.2       | Android SDK Build-Tools
21.1.2
  build-tools;22.0.1                | 22.0.1       | Android SDK Build-Tools
22.0.1
  build-tools;23.0.1                | 23.0.1       | Android SDK Build-Tools
23.0.1
  build-tools;23.0.2                | 23.0.2       | Android SDK Build-Tools
23.0.2
  build-tools;23.0.3                | 23.0.3       | Android SDK Build-Tools
23.0.3
  build-tools;24.0.0                | 24.0.0       | Android SDK Build-Tools
24
  build-tools;24.0.1                | 24.0.1       | Android SDK Build-Tools
24.0.1
  build-tools;24.0.2                | 24.0.2       | Android SDK Build-Tools
24.0.2
  build-tools;24.0.3                | 24.0.3       | Android SDK Build-Tools
24.0.3
  build-tools;25.0.0                | 25.0.0       | Android SDK Build-Tools
25
  build-tools;25.0.1                | 25.0.1       | Android SDK Build-Tools
25.0.1
  build-tools;25.0.2                | 25.0.2       | Android SDK Build-Tools
25.0.2
  cmake;3.6.3155560                 | 3.6.3155560  | CMake 3.6.3155560

  docs                              | 1            | Documentation for Android SDK
  extras;android;gapid;1            | 1.0.3        | GPU Debugging tools

  extras;android;gapid;3            | 3.1.0        | GPU Debugging tools

  extras;android;m2repository       | 41.0.0       | Android Support Repository
  extras;google;auto                | 1.1          | Android Auto Desktop Head Unit...
  extras;google;g...e_play_services | 38           | Google Play services

  extras;google;m2repository        | 41           | Google Repository

  extras;google;m...t_apk_expansion | 1            | Google Play APK Expansion library
  extras;google;market_licensing    | 1            | Google Play Licensing Library
  extras;google;play_billing        | 5            | Google Play Billing Library
  extras;google;simulators          | 1            | Android Auto API Simulators
  extras;google;usb_driver          | 11           | Google USB Driver

  extras;google;webdriver           | 2            | Google Web Driver

  extras;intel;Ha...ecution_Manager | 6.0.5        | Intel x86 Emulator Accelerator...
  extras;m2reposi...er;1.0.0-alpha2 | 1            | com.android.support.constraint...
  extras;m2reposi...er;1.0.0-alpha3 | 1            | com.android.support.constraint...
  extras;m2reposi...er;1.0.0-alpha4 | 1            | com.android.support.constraint...
  extras;m2reposi...er;1.0.0-alpha5 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...er;1.0.0-alpha6 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...er;1.0.0-alpha7 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...er;1.0.0-alpha8 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...er;1.0.0-alpha9 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...ver;1.0.0-beta1 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...ver;1.0.0-beta2 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...ver;1.0.0-beta3 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...ver;1.0.0-beta4 | 1            | Solver for ConstraintLayout 1....
  extras;m2reposi...ut;1.0.0-alpha2 | 1            | com.android.support.constraint...
  extras;m2reposi...ut;1.0.0-alpha3 | 1            | com.android.support.constraint...
  extras;m2reposi...ut;1.0.0-alpha4 | 1            | com.android.support.constraint...
  extras;m2reposi...ut;1.0.0-alpha5 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...ut;1.0.0-alpha6 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...ut;1.0.0-alpha7 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...ut;1.0.0-alpha8 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...ut;1.0.0-alpha9 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...out;1.0.0-beta1 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...out;1.0.0-beta2 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...out;1.0.0-beta3 | 1            | ConstraintLayout for Android 1...
  extras;m2reposi...out;1.0.0-beta4 | 1            | ConstraintLayout for Android 1...
  lldb;2.0                          | 2.0.2558144  | LLDB 2.0

  lldb;2.1                          | 2.1.2852477  | LLDB 2.1

  lldb;2.2                          | 2.2.3271982  | LLDB 2.2

  ndk-bundle                        | 13.1.3345770 | NDK

  patcher;v4                        | 1            | SDK Patch Applier v4

  platform-tools                    | 25.0.3       | Android SDK Platform-Tools
  platforms;android-10              | 2            | Android SDK Platform 10

  platforms;android-11              | 2            | Android SDK Platform 11

  platforms;android-12              | 3            | Android SDK Platform 12

  platforms;android-13              | 1            | Android SDK Platform 13

  platforms;android-14              | 4            | Android SDK Platform 14

  platforms;android-15              | 5            | Android SDK Platform 15

  platforms;android-16              | 5            | Android SDK Platform 16

  platforms;android-17              | 3            | Android SDK Platform 17

  platforms;android-18              | 3            | Android SDK Platform 18

  platforms;android-19              | 4            | Android SDK Platform 19

  platforms;android-20              | 2            | Android SDK Platform 20

  platforms;android-21              | 2            | Android SDK Platform 21

  platforms;android-22              | 2            | Android SDK Platform 22

  platforms;android-23              | 3            | Android SDK Platform 23

  platforms;android-24              | 2            | Android SDK Platform 24

  platforms;android-25              | 3            | Android SDK Platform 25

  platforms;android-7               | 3            | Android SDK Platform 7

  platforms;android-8               | 3            | Android SDK Platform 8

  platforms;android-9               | 2            | Android SDK Platform 9

  sources;android-15                | 2            | Sources for Android 15

  sources;android-16                | 2            | Sources for Android 16

  sources;android-17                | 1            | Sources for Android 17

  sources;android-18                | 1            | Sources for Android 18

  sources;android-19                | 2            | Sources for Android 19

  sources;android-20                | 1            | Sources for Android 20

  sources;android-21                | 1            | Sources for Android 21

  sources;android-22                | 1            | Sources for Android 22

  sources;android-23                | 1            | Sources for Android 23

  sources;android-24                | 1            | Sources for Android 24

  sources;android-25                | 1            | Sources for Android 25

  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...-10;default;x86 | 4            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 2            | ARM EABI v7a System Image
  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...15;default;mips | 1            | MIPS System Image

  system-images;a...-15;default;x86 | 4            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...16;default;mips | 1            | MIPS System Image

  system-images;a...-16;default;x86 | 5            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 5            | ARM EABI v7a System Image
  system-images;a...17;default;mips | 1            | MIPS System Image

  system-images;a...-17;default;x86 | 3            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...-18;default;x86 | 3            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 5            | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 5            | Google APIs Intel x86 Atom Sys...
  system-images;a...ult;armeabi-v7a | 5            | ARM EABI v7a System Image
  system-images;a...-19;default;x86 | 5            | Intel x86 Atom System Image
  system-images;a...pis;armeabi-v7a | 26           | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 26           | Google APIs Intel x86 Atom Sys...
  system-images;a...ear;armeabi-v7a | 4            | Android Wear ARM EABI v7a Syst...
  system-images;a...ndroid-wear;x86 | 4            | Android Wear Intel x86 Atom Sy...
  system-images;a...-tv;armeabi-v7a | 3            | Android TV ARM EABI v7a
System...
  system-images;a...;android-tv;x86 | 3            | Android TV Intel x86 Atom Syst...
  system-images;a...ear;armeabi-v7a | 3            | Android Wear ARM EABI v7a Syst...
  system-images;a...ndroid-wear;x86 | 3            | Android Wear Intel x86 Atom Sy...
  system-images;a...ult;armeabi-v7a | 4            | ARM EABI v7a System Image
  system-images;a...-21;default;x86 | 4            | Intel x86 Atom System Image
  system-images;a...;default;x86_64 | 4            | Intel x86 Atom_64 System Image
  system-images;a...pis;armeabi-v7a | 18           | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 18           | Google APIs Intel x86 Atom Sys...
  system-images;a...gle_apis;x86_64 | 18           | Google APIs Intel x86 Atom_64 ...
  system-images;a...-tv;armeabi-v7a | 1            | Android TV ARM EABI v7a
System...
  system-images;a...;android-tv;x86 | 3            | Android TV Intel x86 Atom Syst...
  system-images;a...ear;armeabi-v7a | 7            | Android Wear ARM EABI v7a Syst...
  system-images;a...ndroid-wear;x86 | 7            | Android Wear Intel x86 Atom Sy...
  system-images;a...ult;armeabi-v7a | 2            | ARM EABI v7a System Image
  system-images;a...-22;default;x86 | 5            | Intel x86 Atom System Image
  system-images;a...;default;x86_64 | 5            | Intel x86 Atom_64 System Image
  system-images;a...pis;armeabi-v7a | 12           | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 12           | Google APIs Intel x86 Atom Sys...
  system-images;a...gle_apis;x86_64 | 12           | Google APIs Intel x86 Atom_64 ...
  system-images;a...-tv;armeabi-v7a | 3            | Android TV ARM EABI v7a
System...
  system-images;a...;android-tv;x86 | 8            | Android TV Intel x86 Atom Syst...
  system-images;a...ear;armeabi-v7a | 6            | Android Wear ARM EABI v7a Syst...
  system-images;a...ndroid-wear;x86 | 6            | Android Wear Intel x86 Atom Sy...
  system-images;a...ult;armeabi-v7a | 6            | ARM EABI v7a System Image
  system-images;a...-23;default;x86 | 9            | Intel x86 Atom System Image
  system-images;a...;default;x86_64 | 9            | Intel x86 Atom_64 System Image
  system-images;a...pis;armeabi-v7a | 19           | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 19           | Google APIs Intel x86 Atom Sys...
  system-images;a...gle_apis;x86_64 | 19           | Google APIs Intel x86 Atom_64 ...
  system-images;a...;android-tv;x86 | 9            | Android TV Intel x86 Atom Syst...
  system-images;a...fault;arm64-v8a | 7            | ARM 64 v8a System Image

  system-images;a...ult;armeabi-v7a | 7            | ARM EABI v7a System Image
  system-images;a...-24;default;x86 | 7            | Intel x86 Atom System Image
  system-images;a...;default;x86_64 | 7            | Intel x86 Atom_64 System Image
  system-images;a..._apis;arm64-v8a | 10           | Google APIs ARM 64 v8a System ...
  system-images;a...pis;armeabi-v7a | 10           | Google APIs ARM EABI v7a Syste...
  system-images;a...google_apis;x86 | 10           | Google APIs Intel x86 Atom Sys...
  system-images;a...gle_apis;x86_64 | 10           | Google APIs Intel x86 Atom_64 ...
  system-images;a...;android-tv;x86 | 2            | Android TV Intel x86 Atom Syst...
  system-images;a...ear;armeabi-v7a | 1            | Android Wear ARM EABI v7a Syst...
  system-images;a...ndroid-wear;x86 | 1            | Android Wear Intel x86 Atom Sy...
  system-images;a...google_apis;x86 | 3            | Google APIs Intel x86 Atom Sys...
  system-images;a...gle_apis;x86_64 | 3            | Google APIs Intel x86 Atom_64 ...
  tools                             | 25.2.5       | Android SDK Tools 25.2.5

Available Updates:
  ID    | Installed | Available
  ------- | -------   | -------
  tools | 25.2.4    | 25.2.5
done

D:\Git\cordova-diagnostic-plugin-example>cordova platform rm android && cordova platform add android@latest && cordova build android
Adding android project...
Creating Cordova project for the Android platform:
        Path: platforms\android
        Package: cordova.plugins.diagnostic.example
        Name: Diagnostic_plugin_example
        Activity: MainActivity
        Android target: android-25
Subproject Path: CordovaLib
Android project created with [email protected]
Installing "cordova-custom-config" for android
Installing "cordova-plugin-camera" for android
Installing "cordova-plugin-compat" for android
Dependent plugin "cordova-plugin-compat" already installed on android.
Installing "cordova-plugin-device" for android
Installing "cordova-plugin-geolocation" for android
Dependent plugin "cordova-plugin-compat" already installed on android.
Installing "cordova-plugin-whitelist" for android

               This plugin is only applicable for versions of cordova-android greater than 4.0. If you have a previous platform version, you do *not* need this plugin since the whitelist will be built in.

Installing "cordova.plugins.diagnostic" for android
Subproject Path: CordovaLib
cordova-custom-config: Skipping auto-restore of config file backup(s)
cordova-custom-config: Applied custom config from config.xml to D:\Git\cordova-diagnostic-plugin-example\platforms\android\AndroidManifest.xml
cordova-custom-config: Skipping auto-restore of config file backup(s)
cordova-custom-config: Applied custom config from config.xml to D:\Git\cordova-diagnostic-plugin-example\platforms\android\AndroidManifest.xml
ANDROID_HOME=G:\Users\dpa99_000\AppData\Local\Android\sdk
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_31
Subproject Path: CordovaLib
Parallel execution with configuration on demand is an incubating feature.
The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
        at build_6na8x8z22cx5xf5vxvmdmnbdv.run(D:\Git\cordova-diagnostic-plugin-example\platforms\android\build.gradle:137)
Incremental java compilation is an incubating feature.
The TaskInputs.source(Object) method has been deprecated and is scheduled to
be removed in Gradle 4.0. Please use TaskInputs.file(Object).skipWhenEmpty()
instead.
:preBuild UP-TO-DATE
:preDebugBuild
:CordovaLib:preBuild UP-TO-DATE
:preDebugBuild UP-TO-DATE
:checkDebugManifest
:preReleaseBuild UP-TO-DATE
:CordovaLib:preDebugBuild UP-TO-DATE
:generateDebugBuildConfig
:CordovaLib:checkDebugManifest
:CordovaLib:prepareDebugDependencies
:CordovaLib:compileDebugAidl
:CordovaLib:compileDebugNdk UP-TO-DATE
:CordovaLib:compileLint
:CordovaLib:copyDebugLint UP-TO-DATE
:CordovaLib:mergeDebugShaders
:generateDebugResValues
:incrementalDebugJavaCompilationSafeguard
:CordovaLib:compileDebugShaders
:CordovaLib:generateDebugAssets
:CordovaLib:mergeDebugAssets
:compileDebugNdk UP-TO-DATE
:mergeDebugShaders
:CordovaLib:mergeDebugProguardFiles
:CordovaLib:packageDebugRenderscript UP-TO-DATE
:CordovaLib:compileDebugRenderscript
:compileDebugShaders
:generateDebugAssets
:processDebugJavaRes UP-TO-DATE
:validateSigningDebug
:CordovaLib:generateDebugResValues
:CordovaLib:generateDebugResources
:CordovaLib:packageDebugResources
:CordovaLib:processDebugManifest
:CordovaLib:generateDebugBuildConfig
:CordovaLib:processDebugResources
:CordovaLib:generateDebugSources
:CordovaLib:incrementalDebugJavaCompilationSafeguard
:CordovaLib:compileDebugJavaWithJavac
:CordovaLib:compileDebugJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
:CordovaLib:processDebugJavaRes UP-TO-DATE
:CordovaLib:transformResourcesWithMergeJavaResForDebug
:CordovaLib:transformClassesAndResourcesWithSyncLibJarsForDebug
:CordovaLib:mergeDebugJniLibFolders
:CordovaLib:transformNative_libsWithMergeJniLibsForDebug
:CordovaLib:transformNative_libsWithSyncJniLibsForDebug
:CordovaLib:bundleDebug
:prepareAndroidCordovaLibUnspecifiedDebugLibrary
:CordovaLib:preReleaseBuild UP-TO-DATE
:CordovaLib:checkReleaseManifest
:CordovaLib:prepareReleaseDependencies
:CordovaLib:compileReleaseAidl
:CordovaLib:compileReleaseNdk UP-TO-DATE
:CordovaLib:copyReleaseLint UP-TO-DATE
:CordovaLib:mergeReleaseShaders
:CordovaLib:compileReleaseShaders
:CordovaLib:generateReleaseAssets
:CordovaLib:mergeReleaseAssets
:CordovaLib:mergeReleaseProguardFiles
:CordovaLib:packageReleaseRenderscript UP-TO-DATE
:CordovaLib:compileReleaseRenderscript
:CordovaLib:generateReleaseResValues
:CordovaLib:generateReleaseResources
:CordovaLib:packageReleaseResources
:CordovaLib:processReleaseManifest
:CordovaLib:generateReleaseBuildConfig
:CordovaLib:processReleaseResources
:CordovaLib:generateReleaseSources
:CordovaLib:incrementalReleaseJavaCompilationSafeguard
:CordovaLib:compileReleaseJavaWithJavac
:CordovaLib:compileReleaseJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
:CordovaLib:processReleaseJavaRes UP-TO-DATE
:CordovaLib:transformResourcesWithMergeJavaResForRelease
:CordovaLib:transformClassesAndResourcesWithSyncLibJarsForRelease
:CordovaLib:mergeReleaseJniLibFolders
:CordovaLib:transformNative_libsWithMergeJniLibsForRelease
:CordovaLib:transformNative_libsWithSyncJniLibsForRelease
:CordovaLib:bundleRelease
:prepareComAndroidSupportAnimatedVectorDrawable2510Library
:prepareComAndroidSupportAppcompatV72510Library
:prepareComAndroidSupportSupportCompat2510Library
:prepareComAndroidSupportSupportCoreUi2510Library
:prepareComAndroidSupportSupportCoreUtils2510Library
:prepareComAndroidSupportSupportFragment2510Library
:prepareComAndroidSupportSupportMediaCompat2510Library
:prepareComAndroidSupportSupportV42510Library
:prepareComAndroidSupportSupportVectorDrawable2510Library
:prepareDebugDependencies
:compileDebugAidl
:compileDebugRenderscript
:generateDebugResources
:mergeDebugResources
:processDebugManifest
:processDebugResources
:generateDebugSources
:compileDebugJavaWithJavac
:compileDebugJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
Note: D:\Git\cordova-diagnostic-plugin-example\platforms\android\src\org\apache\cordova\camera\ExifHelper.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: D:\Git\cordova-diagnostic-plugin-example\platforms\android\src\cordova\plugins\Diagnostic.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
:compileDebugSources
:mergeDebugAssets
:transformClassesWithDexForDebug
:mergeDebugJniLibFolders
:transformNative_libsWithMergeJniLibsForDebug
:transformResourcesWithMergeJavaResForDebug
:packageDebug
:assembleDebug
:cdvBuildDebug

BUILD SUCCESSFUL

Total time: 22.886 secs
Built the following apk(s):
        D:/Git/cordova-diagnostic-plugin-example/platforms/android/build/outputs/apk/android-debug.apk

D:\Git\cordova-diagnostic-plugin-example>


Can you try the following things:

@mlemanczyk
Copy link

mlemanczyk commented Jan 13, 2017

I'm impacted by this issue, too. [email protected], Android support repository is 41, Android Support Library is 23.2. You can find my build log on SO
http://stackoverflow.com/questions/41599927/no-resource-found-that-matches-the-given-name-androidtextappearance-material-w

@dpa99c
Copy link
Owner

dpa99c commented Jan 13, 2017

@mlemanczyk As I'm unable to reproduce the issue the using the same versions of the SDK components as you (see build output above) while building the example project, I would ask that you do the following:

  • Checkout and try building the example project
  • If the build fails, post the following details:
    • details of your installed Android SDK components
      • the output of $ANDROID_HOME/tools/bin/sdkmanager --list
    • the Cordova Android platform version
      • the output of cordova platform ls
    • the full console output from the failed build

Building the example project should eliminate the possibility of a conflict with another plugin in your project.

@dpa99c dpa99c added the more info needed Further information is requested. If not provided, issue will be closed label Jan 13, 2017
@mlemanczyk
Copy link

mlemanczyk commented Jan 13, 2017

fyi, I'm not sure if that's meaningful, but I needed to install lodash, elementtree, plist, tostr & xcode before I could compile your example project. It failed compiling with the same error. Attached you can find the output (I replaced parts of my paths with (...) in the file).

Please remember that this is Windows environment and normally I'm using VS 2015 to build Cordova project.

sdkmanager doesn't exist in my tools/bin folder. In fact I don't have bin folder there. The one in Android SDK root folder neither takes --list nor /list as the parameters. I'm listing the libraries manually below. Please let me know if that's what you wanted.

  • Android SDK Tools: 23
  • Android SDK Platform-Tools: 23.0.1
  • Android SDK Build-tools: 23.0.1
  • Android SDK Build-tools: 22.0.1
  • Android SDK Build-tools: 21.1.2
  • Android SDK Build-tools: 19.1
  • SDK Platform (API 23): Rev. 1
  • SDK Platform (API 22): Rev. 2
  • SDK Platform (API 21): Rev. 2
  • SDK Platform (API 19): Rev. 4
  • (API 19) ARM EABI v7a System Image: Rev. 5
  • (API 19) Intel x86 Atom System Image: Rev. 5
  • (API 19) Google APIs: Rev. 20
  • Android Support Repository: 41
  • Android Support Library: 23.2
  • Google USB Driver: 11

It also fails with the following libs:

  • Android SDK Tools: 24.4.1
  • Android SDK Platform-Tools: 25.0.3
  • Android SDK Build-tools: 23.0.1
  • Android SDK Build-tools: 22.0.1
  • Android SDK Build-tools: 21.1.2
  • Android SDK Build-tools: 19.1
  • SDK Platform (API 23): Rev. 3
  • SDK Platform (API 22): Rev. 2
  • SDK Platform (API 21): Rev. 2
  • SDK Platform (API 19): Rev. 4
  • (API 19) Google APIs (x86 System Image): Rev. 18
  • (API 19) Google APIs: Rev. 20
  • SDK Platform (API 16): Rev. 5
  • (API 16) Google APIs: Rev. 4
  • SDK Platform (API 15): Rev. 5
  • Android Support Repository: 41
  • Android Support Library: 23.2
  • Google USB Driver: 11

It finally worked with the following config:

  • Android SDK Tools: 23
  • Android SDK Platform-Tools: 22
  • Android SDK Build-tools: 23.0.1
  • Android SDK Build-tools: 22.0.1
  • Android SDK Build-tools: 21.1.2
  • Android SDK Build-tools: 19.1
  • SDK Platform (API 23): Rev. 1
  • SDK Platform (API 22): Rev. 2
  • SDK Platform (API 21): Rev. 2
  • SDK Platform (API 19): Rev. 4
  • (API 19) Google APIs (x86 System Image): Rev. 14
  • (API 19) Google APIs (ARM System Image): Rev. 14
  • Android Support Repository: 16
  • Android Support Library: 22,2.1
  • Google USB Driver: 11

So that you know, my 2 friends started experiencing the same issue.

Example build output.txt

Example build output - Success.txt

cordova platform ls output

Warning: using node version v0.12.2 which has been deprecated. Please upgrade to the latest node version available (v6.x is recommended).
Installed platforms:
android 5.2.2
Available platforms:
amazon-fireos ~3.6.3 (deprecated)
blackberry10 ~3.8.0
browser ~4.1.0
firefoxos ~3.6.3
webos ~3.7.0
windows ~4.4.0
wp8 ~3.8.2 (deprecated)

@dpa99c
Copy link
Owner

dpa99c commented Jan 14, 2017

@mlemanczyk

fyi, I'm not sure if that's meaningful, but I needed to install lodash, elementtree, plist, tostr & xcode before I could compile your example project.

This is likely because you running a very old version of Node, hence the warning message in your build log:

Warning: using node version v0.12.2 which has been deprecated. Please upgrade to the latest node version available (v6.x is recommended).

v0.12.2 was released 2015-03-31 and so is likely not compatible the installation method used by cordova-custom-config. Would recommend updating Node to latest 6.x version.

Installed platforms: android 5.2.2

[email protected] uses Android API 22 SDK - I would expect this to fail with the newer SDK components (as outlined in #161).

If you install the latest Android SDK components and the latest cordova-android version (6.1.1), does it work?

cordova platform rm android && cordova platform add android@latest

If not, post the build log for the failed build with [email protected]

@mlemanczyk
Copy link

mlemanczyk commented Jan 15, 2017

I've updated Android SDK packages & nodejs to the latest versions and ran the command you provided. I also needed to upgrade JDK to v1.8, otherwise the build was failing due to JDK incompatibility.

Now I got a different error, Gradle & Java heap related. I'm afraid that this solution is hardly acceptable for VS users, though. MS recommends using NodeJS v0.12.2 due to its biggest compatibility with different Cordova versions.

Build log from failing compile after applying the changes you recommended.

cordova run android
cordova-custom-config: Skipping auto-restore of config file backup(s)
cordova-custom-config: Applied custom config from config.xml to (...)\Documents\Source\diag\platforms\android\AndroidManifest.xml
ANDROID_HOME=C:\Program Files (x86)\Android\android-sdk
JAVA_HOME="c:\Program Files (x86)\Java\jdk1.8.0_111"
Subproject Path: CordovaLib
Downloading http://services.gradle.org/distributions/gradle-2.14.1-all.zip
...........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................
Unzipping (...).gradle\wrapper\dists\gradle-2.14.1-all\53l0mv9mggp9q5m2ip574m21oh\gradle-2.14.1-all.zip to (...).gradle\wrapper\dists\gradle-2.14.1-all\53l0mv9mggp9q5m2ip574m21oh
Starting a new Gradle Daemon for this build (subsequent builds will be faster).

FAILURE: Build failed with an exception.

  • What went wrong:
    Unable to start the daemon process.
    This problem might be caused by incorrect configuration of the daemon.
    For example, an unrecognized jvm option is used.
    Please refer to the user guide chapter on the daemon at https://docs.gradle.org/2.14.1/userguide/gradle_daemon.html
    Please read the following process output to find out more:

Error occurred during initialization of VM
Could not reserve enough space for 2097152KB object heap

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
    Error: cmd: Command failed with exit code 1 Error output:
    FAILURE: Build failed with an exception.

  • What went wrong:
    Unable to start the daemon process.
    This problem might be caused by incorrect configuration of the daemon.
    For example, an unrecognized jvm option is used.
    Please refer to the user guide chapter on the daemon at https://docs.gradle.org/2.14.1/userguide/gradle_daemon.html
    Please read the following process output to find out more:


Error occurred during initialization of VM
Could not reserve enough space for 2097152KB object heap

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

Cordova platform ls output

cordova platform ls
Installed platforms:
  android 6.1.1
Available platforms:
  amazon-fireos ~3.6.3 (deprecated)
  blackberry10 ~3.8.0
  browser ~4.1.0
  firefoxos ~3.6.3
  webos ~3.7.0
  windows ~4.4.0
  wp8 ~3.8.2 (deprecated)

Without applying your changes, everything compiles and Android SDK packages can be updated, except for Android Support Repository. If it is updated to rev. 41, the compile fails. If it's left at rev. 16, everything is fine.

@dpa99c
Copy link
Owner

dpa99c commented Jan 15, 2017

@mlemanczyk

Now I got a different error, Gradle & Java heap related.

Seems this is down to Visual Studio not playing nice with Android/Java - see here for solution.

I'm afraid that this solution is hardly acceptable for VS users, though. MS recommends using NodeJS v0.12.2 due to its biggest compatibility with different Cordova versions.
Without applying your changes, everything compiles and Android SDK packages can be updated, except for Android Support Repository. If it is updated to rev. 41, the compile fails. If it's left at rev. 16, everything is fine.

The intended build environment for this plugin is the latest vanilla Cordova CLI and platforms with the latest versions of any dependencies (Java/Node/Android SDK components). Projects containing this plugin will build fine once dependency issues are updated/resolved.

You are welcome to create/maintain a fork which pins these dependencies to older versions for the purposes of Visual Studio users.

@romanvenica
Copy link

romanvenica commented Jan 16, 2017

Hi. Trying to build a blank project with only this pugin:

https://bitbucket.org/romanvenica/test/

on Phonegap Build returns the same error.

@dpa99c
Copy link
Owner

dpa99c commented Jan 16, 2017

@romanvenica You need to specify phonegap-version to use cli-6.4.0 in order to get android platform v6.1.0 otherwise it defaults to cli-6.3.0 with android platform v5.2.1 (see here)

<preference name="phonegap-version" value="cli-6.4.0" />

For example, try building: https://github.com/dpa99c/cordova-diagnostic-plugin-phonegap-build-example

It builds fine with Phonegap Build:

Phonegap Build output

Build Date: 2017-01-16 12:09:52 +0000
--------------------------------------------------------------------------------
PLUGIN OUTPUT
--------------------------------------------------------------------------------
Fetching plugin "cordova-plugin-whitelist@*" via npm
Installing "cordova-plugin-whitelist" at "1.3.1" for android
Subproject Path: CordovaLib
Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:clean
:CordovaLib:clean

BUILD SUCCESSFUL

Total time: 1.648 secs

               This plugin is only applicable for versions of cordova-android greater than 4.0. If you have a previous platform version, you do *not* need this plugin since the whitelist will be built in.
Fetching plugin "cordova.plugins.diagnostic@*" via npm
Installing "cordova.plugins.diagnostic" at "3.3.3" for android
Subproject Path: CordovaLib
Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:clean
:CordovaLib:clean

BUILD SUCCESSFUL

Total time: 1.479 secs
Subproject Path: CordovaLib
--------------------------------------------------------------------------------
COMPILE OUTPUT
--------------------------------------------------------------------------------
Subproject Path: CordovaLib
Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:preBuild UP-TO-DATE
:preDebugBuild UP-TO-DATE
:checkDebugManifest
:preReleaseBuild UP-TO-DATE
:CordovaLib:preBuild UP-TO-DATE
:CordovaLib:preDebugBuild UP-TO-DATE
:CordovaLib:checkDebugManifest
:CordovaLib:prepareDebugDependencies
:CordovaLib:compileDebugAidl
:CordovaLib:compileDebugNdk UP-TO-DATE
:CordovaLib:compileLint
:CordovaLib:copyDebugLint UP-TO-DATE
:CordovaLib:mergeDebugShaders
:CordovaLib:compileDebugShaders
:CordovaLib:generateDebugAssets
:CordovaLib:mergeDebugAssets
:CordovaLib:mergeDebugProguardFiles
:CordovaLib:packageDebugRenderscript UP-TO-DATE
:CordovaLib:compileDebugRenderscript
:CordovaLib:generateDebugResValues
:CordovaLib:generateDebugResources
:CordovaLib:packageDebugResources
:CordovaLib:processDebugManifest
:CordovaLib:generateDebugBuildConfig
:CordovaLib:processDebugResources
:CordovaLib:generateDebugSources
:CordovaLib:incrementalDebugJavaCompilationSafeguard
:CordovaLib:compileDebugJavaWithJavac
:CordovaLib:compileDebugJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
:CordovaLib:processDebugJavaRes UP-TO-DATE
:CordovaLib:transformResourcesWithMergeJavaResForDebug
:CordovaLib:transformClassesAndResourcesWithSyncLibJarsForDebug
:CordovaLib:mergeDebugJniLibFolders
:CordovaLib:transformNative_libsWithMergeJniLibsForDebug
:CordovaLib:transformNative_libsWithSyncJniLibsForDebug
:CordovaLib:bundleDebug
:CordovaLib:preReleaseBuild UP-TO-DATE
:CordovaLib:checkReleaseManifest
:CordovaLib:prepareReleaseDependencies
:CordovaLib:compileReleaseAidl
:CordovaLib:compileReleaseNdk UP-TO-DATE
:CordovaLib:copyReleaseLint UP-TO-DATE
:CordovaLib:mergeReleaseShaders
:CordovaLib:compileReleaseShaders
:CordovaLib:generateReleaseAssets
:CordovaLib:mergeReleaseAssets
:CordovaLib:mergeReleaseProguardFiles
:CordovaLib:packageReleaseRenderscript UP-TO-DATE
:CordovaLib:compileReleaseRenderscript
:CordovaLib:generateReleaseResValues
:CordovaLib:generateReleaseResources
:CordovaLib:packageReleaseResources
:CordovaLib:processReleaseManifest
:CordovaLib:generateReleaseBuildConfig
:CordovaLib:processReleaseResources
:CordovaLib:generateReleaseSources
:CordovaLib:incrementalReleaseJavaCompilationSafeguard
:CordovaLib:compileReleaseJavaWithJavac
:CordovaLib:compileReleaseJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
:CordovaLib:processReleaseJavaRes UP-TO-DATE
:CordovaLib:transformResourcesWithMergeJavaResForRelease
:CordovaLib:transformClassesAndResourcesWithSyncLibJarsForRelease
:CordovaLib:mergeReleaseJniLibFolders
:CordovaLib:transformNative_libsWithMergeJniLibsForRelease
:CordovaLib:transformNative_libsWithSyncJniLibsForRelease
:CordovaLib:bundleRelease
:prepareComAndroidSupportAnimatedVectorDrawable2510Library
:prepareComAndroidSupportAppcompatV72510Library
:prepareComAndroidSupportSupportCompat2510Library
:prepareComAndroidSupportSupportCoreUi2510Library
:prepareComAndroidSupportSupportCoreUtils2510Library
:prepareComAndroidSupportSupportFragment2510Library
:prepareComAndroidSupportSupportMediaCompat2510Library
:prepareComAndroidSupportSupportV42510Library
:prepareComAndroidSupportSupportVectorDrawable2510Library
:prepareProjectCordovaLibUnspecifiedDebugLibrary
:prepareDebugDependencies
:compileDebugAidl
:compileDebugRenderscript
:generateDebugBuildConfig
:generateDebugResValues
:generateDebugResources
:mergeDebugResources
:processDebugManifest
:processDebugResourcesWarning: AndroidManifest.xml already defines debuggable (in http://schemas.android.com/apk/res/android); using existing value in manifest.


:generateDebugSources
:incrementalDebugJavaCompilationSafeguard
:compileDebugJavaWithJavac
:compileDebugJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
Note: /project/src/cordova/plugins/Diagnostic.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
:compileDebugNdk UP-TO-DATE
:compileDebugSources
:mergeDebugShaders
:compileDebugShaders
:generateDebugAssets
:mergeDebugAssets
:transformClassesWithDexForDebug
:mergeDebugJniLibFolders
:transformNative_libsWithMergeJniLibsForDebug
:processDebugJavaRes UP-TO-DATE
:transformResourcesWithMergeJavaResForDebug
:validateSigningDebug
:packageDebug
:assembleDebug
:cdvBuildDebug

BUILD SUCCESSFUL

Total time: 9.036 secs
Built the following apk(s): 
	/project/build/outputs/apk/project-debug.apk

@mlemanczyk
Copy link

mlemanczyk commented Jan 16, 2017

@dpa99c, your test project finally compiled with Android Support Repository 41, after setting _JAVA_OPTIONS and workarounding Gradle's issue with not accepted licenses using this SO.

Switching back to nodejs v0.12.2 does not break the compile. But switching your project back to cordova platform add android@5 according to the instructions on GitHub does break it.

I'm trying to understand what that really means. After cordova platform add android@latest the project is compiled against android-25 API, right? I.e. Target SDK = 25. According to this SO, target SDK indicates the platform the application was tested on.

Do you foresee a risk in switching to android-25 target? According to Google API 25 has 0.2% of the market, only. While majority of people have API 16-23.

We're targeting API 16 and that's what we're testing with. I'm concerned if that will mean that we're risking issues with 97.2% of users, if we target it at API 25. I'm sorry if that's a basic question. This is my first Android project.

@dpa99c
Copy link
Owner

dpa99c commented Jan 17, 2017

@mlemanczyk Using cordova platform add android@latest currently installs [email protected] which supports API 24/25 and defaults to API 25 for compile/target SDK version.

By using the latest version of cordova-android you benefit from bug fixes going in during the continuous development - see the changelog

Android SDKs are backwardly compatible - building with [email protected], your app will still run on a device running API 16 (Android 4.1 Jellybean).
Your only concern would be if you need to target API 14/15 (Android 4.0 Ice Cream Sandwich) which cordova-android@5 supports. Although having said that cordova-android@6 has deprecated support for 4.0, not removed it.

Have a look at this SO answer for an explanation of the various Android SDK versions.

Also see Cordova's Android platform guide - note that it's out-of-date as it doesn't include details of cordova-android@6 yet

dpa99c added a commit that referenced this issue Jan 19, 2017
@dpa99c
Copy link
Owner

dpa99c commented Jan 19, 2017

@vaprea @mlemanczyk Can this issue now be closed?

@mlemanczyk
Copy link

mlemanczyk commented Jan 26, 2017

@dpa99c I'm sorry for the delayed answer. After applying all your advises our project started compiling in VS 2015. I've put all the steps together as the solution to my SO, created before I learned about issue #168.

Thank you very much for your guidance and help on this.

@mickadoua
Copy link

i have same issue, i dont know if i should open another one or post here ?

here my version

ionic v2.2.1
cordova 6.5.0

cordova plugin list

com-sarriaroman-photoviewer 1.1.10 "PhotoViewer"
com.synconset.imagepicker 2.1.7 "ImagePicker"
cordova-plugin-compat 1.1.0 "Compat"
cordova-plugin-console 1.0.4 "Console"
cordova-plugin-facebook4 1.7.4 "Facebook Connect"
cordova-plugin-file 4.3.1 "File"
cordova-plugin-file-transfer 1.6.1 "File Transfer"
cordova-plugin-geolocation 2.4.1 "Geolocation"
cordova-plugin-googlemaps 1.4.0 "phonegap-googlemaps-plugin"
cordova-plugin-splashscreen 4.0.0 "Splashscreen"
cordova-plugin-statusbar 2.2.0 "StatusBar"
cordova-plugin-whitelist 1.3.0 "Whitelist"
cordova-plugin-x-socialsharing 5.1.3 "SocialSharing"
cordova.plugins.diagnostic 3.5.0 "Diagnostic"
ionic-plugin-keyboard 2.2.1 "Keyboard"

config.xml

        <preference name="android-minSdkVersion" value="21" />
        <preference name="android-targetSdkVersion" value="24" />

everything on android sdk are updated

@rajeevriitm
Copy link

@mickadoua Did you solve this issue? I am facing the same.

@mickadoua
Copy link

@rajeevriitm sorry i forgot, how i fix that, :s

@dpa99c
Copy link
Owner

dpa99c commented Apr 28, 2017

@mickadoua looking at the list of plugins you posted, it was likely a similar Gradle collision as outlined at the bottom of #203 - you have the same ImagePicker plugin referenced.

@rajeevriitm
Copy link

@mickadoua Did you have to fork any plugins?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
more info needed Further information is requested. If not provided, issue will be closed
Projects
None yet
Development

No branches or pull requests

6 participants