I uploaded my apk it always shows that it is supported by 0 android devices.Please help me to successfully launch my first app. I have uploaded 12 version but is not working anyone. I am basically using location sms and contact read permission in my app.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="deepesh.travel.abhay.applayout" android:versionCode="5" xmlns:tools="http://schemas.android.com/tools">
<!-- To auto-complete the email text field in the login form with the user's emails -->
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="23" />
<uses-feature android:name="android.hardware.sensor.compass"
android:required="false" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.READ_PROFILE" />
<uses-permission android:name="android.permission.READ_CONTACTS" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.SEND_SMS" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.READ_CONTACTS" />
<uses-permission android:name="com.android.alarm.permission.SET_ALARM"/>
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.VIBRATE" />
<application
android:name="deepesh.travel.abhay.applayout.saved_data_elements"
android:allowBackup="true"
tools:replace="icon, label"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name"
android:roundIcon="#mipmap/ic_launcher"
android:supportsRtl="true"
android:theme="#style/AppTheme">
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="AIzaSyDNVWdbxYpqG08j-wytsWb5cwrBM0mN1ro" />
<activity android:name="deepesh.travel.abhay.applayout.WelcomeActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="deepesh.travel.abhay.applayout.MainActivity"
android:label="#string/app_name"
android:theme="#style/AppTheme.NoActionBar" />
<activity
android:name="com.google.android.gms.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
android:theme="#android:style/Theme.Translucent" />
<activity
android:name="deepesh.travel.abhay.applayout.SettingTest"
android:label="#string/title_activity_settings"
android:parentActivityName="deepesh.travel.abhay.applayout.MainActivity">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="deepesh.travel.abhay.applayout.MainActivity" />
</activity>
<activity
android:name="deepesh.travel.abhay.applayout.Tutorial"
android:label="#string/tutorial"
android:parentActivityName="deepesh.travel.abhay.applayout.SettingTest">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="deepesh.travel.abhay.applayout.MainActivity" />
</activity>
<activity
android:name="deepesh.travel.abhay.applayout.privacyPolicy"
android:label="#string/privacy"
android:parentActivityName="deepesh.travel.abhay.applayout.SettingTest">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="deepesh.travel.abhay.applayout.MainActivity" />
</activity>
<receiver android:name="deepesh.travel.abhay.applayout.AlarmReceiver" />
</application>
</manifest>
and My build.gradle file is like this:
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
applicationId "deepesh.travel.abhay.applayout"
minSdkVersion 14
targetSdkVersion 23
versionCode 12
versionName "1.0"
multiDexEnabled true
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
dexOptions {
javaMaxHeapSize "2048M"
}
}
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.2.3'
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile "com.android.support:support-v4:25.3.1"
compile 'com.android.support:mediarouter-v7:25.3.1'
compile "com.android.support:support-v13:25.3.1"
compile "com.android.support:appcompat-v7:25.3.1"
compile "com.android.support:cardview-v7:25.3.1"
compile 'com.android.support:design:25.3.1'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'com.almworks.sqlite4java:sqlite4java-win32-x64:1.0.392'
compile 'com.android.support:preference-v7:25.3.1'
compile 'com.google.android.gms:play-services:10.2.1'
compile 'org.apache.directory.studio:org.apache.commons.io:2.4'
compile 'com.google.android.gms:play-services-ads:10.2.1'
compile 'com.google.android.gms:play-services:8.4.0'
testCompile 'junit:junit:4.12'
}
Please help me to successfully launch my first app. I have uploaded 12 version but is not working anyone. I am basically using location sms and contact read permission in my app.
remove <uses-sdk android:minSdkVersion="14" android:targetSdkVersion="23" />
no use if u r defining in gradle then if u r targeting to 23 version
then keep ur compileSdkVersion 25 buildToolsVersion "25.0.3" to 26
android:roundIcon="#mipmap/ic_launcher" This is for Android O which is 26
So make your build proper you all mixup with the version
app gradle
compileSdkVersion 26
buildToolsVersion "26.0.1"
minSdkVersion 14
targetSdkVersion 26
versionCode 13
versionName "1.0"
Make build gradle file like this .
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion "26.0.1"
defaultConfig {
applicationId "deepesh.travel.abhay.applayout"
minSdkVersion 14
targetSdkVersion 26
versionCode 17
versionName "1.0"
multiDexEnabled true
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
dexOptions {
javaMaxHeapSize "2048M"
}
}
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.3'
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile "com.android.support:support-v4:26.+"
compile 'com.android.support:mediarouter-v7:26.+'
compile "com.android.support:support-v13:26.+"
compile "com.android.support:appcompat-v7:26.+"
compile "com.android.support:cardview-v7:26.+"
compile 'com.android.support:design:26.+'
compile 'com.android.support.constraint:constraint-layout:1.+'
compile 'com.almworks.sqlite4java:sqlite4java-win32-x64:1.+'
compile 'com.android.support:preference-v7:26.+'
compile 'com.google.android.gms:play-services:10.2.1'
compile 'commons-io:commons-io:2.4'
compile 'com.google.android.gms:play-services-ads:10.2.1'
compile 'com.google.android.gms:play-services:8.4.0'
testCompile 'junit:junit:4.12'
}
And Remove from mainifest file.
Related
I wanted to use table view in my android application but i get the following error:
Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed : Attribute application#label value=(Curtain Club) from AndroidManifest.xml:13:9-37
is also present at [de.codecrafters.tableview:tableview:2.8.0] AndroidManifest.xml:11:18-50 value=(#string/app_name).
Suggestion: add 'tools:replace="android:label"' to <application> element at AndroidManifest.xml:10:5-139:19 to override.
Here is my gradle file:
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion '26.0.2'
defaultConfig {
applicationId "Calculator.curtainclub"
minSdkVersion 23
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile 'com.android.support:recyclerview-v7:26.1.0'
compile 'de.codecrafters.tableview:tableview:2.8.0'
implementation 'com.android.support:wear:26.1.0'
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:26.1.0'
compile 'com.android.support:design:26.1.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.2'
testCompile 'junit:junit:4.12'
compile project(':jtds-1.3.1')
androidTestCompile 'com.android.support.test.espresso:espresso-core:3.0.2'
androidTestCompile 'com.android.support.test:runner:1.0.2'
androidTestCompile 'com.android.support:support-annotations:27.1.1'
compile files('libs/mail.jar')
compile files('libs/additionnal.jar')
compile files('libs/activation.jar')
}
if i remove the table view library, my gradle syncs perfectly with no errors
Here is my manifest file:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
<uses-permission android:name="android.permission.USE_FINGERPRINT" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<application
android:allowBackup="true"
android:icon="#mipmap/ic_launcher"
android:label="Curtain Club"
android:supportsRtl="true"
android:theme="#style/AppTheme">
<activity android:name=".LoginLogout.login">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".Employees.AdminLogin" />
<activity android:name=".Calculator.Calc_140_pattern"></activity>
</application>
Please note i have opted out some activity files because there is a lot and it wouldn't allow me to add the question because of too much code
In your manifest file replace this
android:label="Curtain Club"
with
#string/curtain_club
Now Go to your strings.xml file and write this
<string name="curtain_club">Curtain Club</string>
After that rebuild your project
I'm building an application that has a shared library and two applications that share this library.
As soon as the application starts the logcat shows D/AndroidRuntime: Shutting down VM.
If I debug the application it does not launch my MainActivity (LoginActivity). The application crashs after return from attachBaseContext(Context base) in the Application Class.
This is not a simple case of NPE, the problem is that the VM is Shutting down and the only debuggable part is the Global.attachBaseContext that runs OK and after that the Logcat message is shown.
LOGCAT
I/MultiDex: VM with version 2.1.0 has multidex support
I/MultiDex: install
I/MultiDex: VM has multidex support, MultiDex support library is disabled.
I/MultiDex: install
I/MultiDex: VM has multidex support, MultiDex support library is disabled.
D/AndroidRuntime: Shutting down VM
--------- beginning of crash
E/AndroidRuntime: FATAL EXCEPTION: main
Process: br.com.cfb.dogwalktracker_dogwalker, PID: 17406
java.lang.NullPointerException: Attempt to invoke virtual method 'boolean
java.lang.String.equals(java.lang.Object)' on a null object reference at android.app.ActivityThread.installProvider(ActivityThread.java:5140)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:4769)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4709)
at android.app.ActivityThread.-wrap1(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1415)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5443)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:728)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
GradeBuild shared library
apply plugin: 'com.android.library'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
minSdkVersion 17
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
dexOptions {
javaMaxHeapSize "4g"
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
compile 'com.android.support:multidex:1.0.1'
})
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support:design:25.3.1'
compile 'com.android.support:support-v13:25.3.1'
compile 'com.android.support:cardview-v7:25.3.1'
compile 'com.android.support:recyclerview-v7:25.3.1'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'com.github.orangegangsters:swipy:1.2.0#aar'
compile 'com.android.support:multidex:1.0.1'
compile 'com.squareup.retrofit:retrofit:1.9.0'
compile 'com.squareup.okhttp:okhttp-urlconnection:2.2.0'
compile 'com.squareup.okhttp:okhttp:2.2.0'
compile 'com.google.code.gson:gson:2.7'
compile 'org.parceler:parceler:1.0.1'
compile 'org.parceler:parceler-api:1.0.1'
compile 'com.google.android.gms:play-services-ads:11.0.4'
compile 'com.google.android.gms:play-services-maps:11.0.4'
compile 'com.google.android.gms:play-services-places:11.0.4'
compile 'com.android.support:support-v4:25.3.1'
testCompile 'junit:junit:4.12'
}
Gradebuild (from dog walker Application)
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
applicationId "br.com.cfb.dogwalktracker_dogwalker"
minSdkVersion 17
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
dexOptions {
javaMaxHeapSize "4g"
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
compile 'com.google.android.gms:play-services:11.0.4'
compile 'com.android.support:multidex:1.0.1'
})
compile project(':DogWalkTrackerShared')
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.google.android.gms:play-services-plus:11.0.4'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
}
GradeBuild (From user Application)
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
applicationId "br.com.cfb.dogwalktrackeruser"
minSdkVersion 17
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
dexOptions {
javaMaxHeapSize "4g"
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
compile 'com.android.support:multidex:1.0.1'
})
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support:design:25.3.1'
compile 'com.android.support:support-v13:25.3.1'
compile 'com.android.support:cardview-v7:25.3.1'
compile 'com.android.support:recyclerview-v7:25.3.1'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'com.github.orangegangsters:swipy:1.2.0#aar'
compile 'com.android.support:multidex:1.0.1'
compile 'com.squareup.retrofit:retrofit:1.9.0'
compile 'com.squareup.okhttp:okhttp-urlconnection:2.2.0'
compile 'com.squareup.okhttp:okhttp:2.2.0'
compile 'com.google.code.gson:gson:2.7'
compile 'org.parceler:parceler:1.0.1'
compile 'org.parceler:parceler-api:1.0.1'
compile 'com.google.android.gms:play-services-ads:11.0.4'
compile 'com.google.android.gms:play-services-maps:11.0.4'
compile 'com.google.android.gms:play-services-places:11.0.4'
compile 'com.android.support:support-v4:25.3.1'
compile project(':DogWalkTrackerShared')
testCompile 'junit:junit:4.12'
}
GLOBAL
public class Global extends Application {
protected void attachBaseContext(Context base) {
super.attachBaseContext(base);
MultiDex.install(this);
}
}
Manifest (from dog walker Application)
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="br.com.cfb.dogwalktracker_dogwalker">
<uses-permission android:name="android.permission.WRITE_INTERNAL_STORAGE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission android:name="android.permission.RECEIVE_SMS" />
<uses-permission android:name="android.permission.READ_SMS" />
<uses-permission android:name="android.permission.SEND_SMS" />
<uses-feature android:name="android.hardware.location.gps" />
<uses-feature
android:name="android.hardware.camera"
android:required="true" />
<application
android:name="br.com.cfb.dogwalktrackershared.Global"
android:allowBackup="true"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name_dogwalker"
android:roundIcon="#mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="#style/AppTheme"
tools:replace="label">
<activity
android:name=".LoginActivity"
android:label="#string/app_name_dogwalker">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".GrantPermissionActivity"
android:label="#string/app_name_dogwalker"/>
<activity
android:name=".NavigationDrawer"
android:label="#string/app_name"
android:theme="#style/AppTheme.NoActionBar" />
<receiver
android:name=".BootReceiver"
android:enabled="true">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
<receiver android:name="br.com.cfb.dogwalktrackershared.IncomingSms">
<intent-filter>
<action android:name="android.provider.Telephony.SMS_RECEIVED" />
</intent-filter>
</receiver>
<receiver android:name=".AlarmReceiver" />
</application>
</manifest>
Manifest (From user Application)
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="br.com.cfb.dogwalkertrackeruser">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECEIVE_SMS" />
<uses-permission android:name="android.permission.READ_SMS" />
<uses-permission android:name="android.permission.SEND_SMS" />
<uses-feature
android:name="android.hardware.camera"
android:required="true" />
<!--
The ACCESS_COARSE/FINE_LOCATION permissions are not required to use
Google Maps Android API v2, but you must specify either coarse or fine
location permissions for the 'MyLocation' functionality.
-->
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<application
android:name="br.com.cfb.dogwalktrackershared.Global"
android:allowBackup="true"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name"
android:roundIcon="#mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="#style/AppTheme">
<activity
android:name="br.com.cfb.dogwalktracker_dogwalker.LoginActivity"
android:label="#string/app_name_dogwalker">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="br.com.cfb.dogwalktracker_dogwalker.GrantPermissionActivity"
android:label="#string/app_name_dogwalker"/>
<activity
android:name=".NavigationDrawer"
android:label="#string/app_name"
android:theme="#style/AppTheme.NoActionBar" />
<!--
The API key for Google Maps-based APIs is defined as a string resource.
(See the file "res/values/google_maps_api.xml").
Note that the API key is linked to the encryption key used to sign the APK.
You need a different API key for each encryption key, including the release key that is used to
sign the APK for publishing.
You can define the keys for the debug and release targets in src/debug/ and src/release/.
-->
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="#string/google_maps_key" />
</application>
</manifest>
Manifest from Shared Library
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="br.com.cfb.dogwalktrackershared">
<uses-permission android:name="android.permission.INTERNET" />
<application android:allowBackup="true"
android:label="#string/app_name"
android:supportsRtl="true">
</application>
</manifest>
I have many android modules implemented in my project. Each module is added as an independent Android module which can be launched on mobile or an emulator. After working on all the modules. Finally, I wanted to merge all those independent modules into one project and connect everything and make all the modules work as a single app.
To do that, I've replaced apply plugin: 'com.android.application' with
apply plugin: 'com.android.library' in all the module's gradle file except for the app/build.gradle which is the first module in the app and it has apply plugin: 'com.android.application'in its gradle.
Also, in the app/manifest.xml I have this defined in it:
<activity
android:name=".MainActivity"
android:screenOrientation="portrait"
android:theme="#style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER"/>
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
But, when I launch the app on an emulator or a real device. The activity of the fourth module which is named as FirstTimeProfileSetup (i.e. not MainActivity) shows up on the screen as a first screen. when we wait for some time without any operations on the screen, then the FirstTimeProfileSetup screen goes off and the MainActivity of the app module will show up.
Below is the manifest.xml file of app module:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.example">
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.INTERNET" />
<!--<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="25" />-->
<application
android:allowBackup="true"
android:icon="#mipmap/app_logo"
android:label="#string/app_name"
android:roundIcon="#mipmap/app_logo"
android:supportsRtl="true"
android:theme="#style/AppTheme"
tools:replace="android:icon,android:roundIcon">
<meta-data
android:name="com.facebook.sdk.ApplicationId"
android:value="#string/facebook_app_id" />
<activity
android:name=".MainActivity"
android:screenOrientation="portrait"
android:theme="#style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER"/>
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="#string/google_maps_key" />
<activity
android:name=".loginAndSignup.sign_in"
android:label="sign_in"
android:parentActivityName=".MainActivity"
android:theme="#style/AppTheme">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value=".MainActivity" />
</activity>
<activity android:name=".Registration" />
</application>
</manifest>
Below is the manifest of the other module whose activity is showing up first:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.firsttimeusermodule">
<uses-permission android:name="android.permission.CAMERA" />
<uses-feature android:name="android.hardware.camera" android:required="true" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<!--<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="25" />-->
<application
android:allowBackup="true"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name"
android:roundIcon="#mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="#style/AppTheme">
<activity android:name=".FirstTimeProfileSetup"></activity>
<activity android:name=".ProfilePic"></activity>
<provider
android:name="android.support.v4.content.FileProvider"
android:authorities="com.firsttimeusermodule"
android:exported="false"
android:grantUriPermissions="true">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="#xml/file_paths"></meta-data>
</provider>
</application>
</manifest>
and below is the build.gradle of app module:
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
applicationId "com.example"
minSdkVersion 15
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
externalNativeBuild {
cmake {
cppFlags "-frtti -fexceptions"
}
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
externalNativeBuild {
cmake {
path "CMakeLists.txt"
}
}
productFlavors {
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
compile 'com.android.support:design:25.3.1'
compile 'com.facebook.android:facebook-android-sdk:4.22.1'
compile 'com.google.gms:google-services:3.1.0'
compile 'com.android.support:support-v4:25.3.1'
testCompile 'junit:junit:4.12'
compile 'com.google.gms:google-services:3.1.0'
compile 'com.google.android.gms:play-services-auth:11.0.0'
compile 'com.google.android.gms:play-services-maps:11.0.0'
compile project(path: ':usertype')
compile project(path: ':firsttimeusermodule')
compile 'com.squareup.retrofit2:retrofit:2.3.0'
compile 'com.google.code.gson:gson:2.8.1'
compile 'com.squareup.retrofit2:converter-gson:2.3.0'
}
apply plugin: 'com.google.gms.google-services'
and below is the build.gradle file of the other module:
apply plugin: 'com.android.library'
android {
compileSdkVersion 25
buildToolsVersion "25.0.3"
defaultConfig {
// applicationId "com.firsttimeusermodule"
minSdkVersion 15
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support:support-v4:25.3.1'
compile 'com.google.gms:google-services:3.1.0'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
}
Can anyone please helps me resolve this problem.
Thanks in advance
Here's the screenshot of Merged Manifest:
Please help me. I dont know why, when I trying to upload the apk from version code 21 to 22 and version Name from 305 to 306.. playstore showing me detail zero device supported. this is my AndroidManifest.xml.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.android.studio"
android:installLocation="auto"
android:versionCode="22"
android:versionName="3.0.6">
<uses-sdk
android:minSdkVersion="11"
android:targetSdkVersion="25" />
<uses-feature
android:glEsVersion="0x00020000"
android:required="true" />
<supports-screens
android:anyDensity="true"
android:largeScreens="true"
android:normalScreens="true"
android:resizeable="true"
android:smallScreens="true"
android:xlargeScreens="true" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<!---->
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.CALL_PHONE" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<!---->
<uses-permission android:name="android.permission.GET_TASKS" />
<uses-permission
android:name="android.permission.PACKAGE_USAGE_STATS"
tools:ignore="ProtectedPermissions" />
<uses-permission android:name="android.Manifest.permission.ACCESS_NETWORK_STATE" />
<application
android:name=".SplashScreen"
android:allowBackup="true"
android:hardwareAccelerated="false"
android:icon="#drawable/ic_launcher"
android:label="#string/app_name"
android:largeHeap="true">
<!--
The API key for Google Maps-based APIs is defined as a string resource.
(See the file "res/values/google_maps_api.xml").
Note that the API key is linked to the encryption key used to sign the APK.
You need a different API key for each encryption key, including the release key that is used to
sign the APK for publishing.
You can define the keys for the debug and release targets in src/debug/ and src/release/.
-->
<activity
android:name=".SplashScreen"
android:configChanges="keyboardHidden"
android:screenOrientation="portrait"
android:theme="#style/AppTheme">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".Tutorial"
android:configChanges="keyboardHidden"
android:noHistory="true"
android:screenOrientation="portrait"
android:theme="#style/AppTheme"
android:windowSoftInputMode="adjustPan|stateHidden" />
</application>
this is my build.gradle (project)
apply plugin: 'com.android.application'
apply plugin: 'com.neenbedankt.android-apt'
android {
compileSdkVersion 25
buildToolsVersion "25.0.2"
useLibrary 'org.apache.http.legacy'
compileOptions.encoding = 'ISO-8859-1'
defaultConfig {
applicationId "com.android.studio"
minSdkVersion 11
targetSdkVersion 25
multiDexEnabled true
renderscriptTargetApi 25
renderscriptSupportModeEnabled true
}
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-project.txt'
}
}
packagingOptions {
}
dexOptions {
javaMaxHeapSize "4g"
}
aaptOptions {
cruncherEnabled = false
}
}dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile('com.android.support:support-v4:21.0.3') {
exclude group: 'com.android.support', module: 'support-v4'
}
compile 'com.android.support:multidex:1.0.1'
compile 'com.android.support:appcompat-v7:25.1.0'
compile 'com.android.support:percent:25.1.0'
compile 'com.jakewharton:butterknife:8.2.1'
compile 'com.readystatesoftware.sqliteasset:sqliteassethelper:2.0.1'
compile 'com.karumi:dexter:2.3.1'
compile 'com.github.siyamed:android-shape-imageview:0.9.+#aar'
compile 'com.google.android.gms:play-services-auth:9.4.0'
compile 'com.google.firebase:firebase-core:9.4.0'
compile 'com.google.firebase:firebase-auth:9.4.0'// dif
compile 'com.google.firebase:firebase-messaging:9.4.0'// dif
compile 'com.google.android.gms:play-services-maps:9.4.0'
compile 'com.android.support:design:25.1.0'
compile 'com.android.support:cardview-v7:25.1.0'
compile 'com.github.chrisbanes:PhotoView:1.2.6'
compile 'com.squareup.okhttp3:okhttp:3.2.0'
compile 'com.adeel:easyFTP:1.0'
compile 'com.android.support:exifinterface:25.1.0'
compile 'net.gotev:uploadservice:2.1'
compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.5'
compile 'com.android.support:support-v4:25.1.0'
compile 'com.squareup.picasso:picasso:2.4.0'
compile 'com.google.android.gms:play-services-location:9.4.0'
compile 'io.github.luizgrp.sectionedrecyclerviewadapter:sectionedrecyclerviewadapter:1.0.4'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
testCompile 'junit:junit:4.12'
apt 'com.jakewharton:butterknife-compiler:8.2.1'
compile 'com.google.android.gms:play-services:9.4.0'
}
apply plugin: 'com.google.gms.google-services'
this is my build.gradle (module:app)
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.2'
classpath 'com.neenbedankt.gradle.plugins:android-apt:1.8'
classpath 'com.google.gms:google-services:3.0.0'
}} allprojects {
repositories {
jcenter()
maven { url "https://jitpack.io"}
}}
It is a bug in google play store you can upload the APK it will be visible for all the devices according to your configuration.
Refer my answer at
APK 0 Device Compatibility
I'm migrating my project from eclipse to Android Studio and ran into an error :
Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed with multiple errors, see logs
I've searched through this problem and seen that I need to use
xmlns:tools="http://schemas.android.com/tools"
in the manifest tag
and
tools:node="replace"
tools:replace="icon"
in the application tag. but that didn't help me. I presume that there is something to do with Gradle/Manifest working failure, but not sure where
Here's manifest (it's the only Manifest in App module)
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.vladdrummer.headsup"
xmlns:tools="http://schemas.android.com/tools"
android:versionCode="7"
android:versionName="1.01" >
<uses-sdk
android:minSdkVersion="11"
android:targetSdkVersion="25" />
<application
android:allowBackup="true"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name"
android:theme="#style/AppTheme"
tools:node="replace"
tools:replace="icon">
<activity
android:name=".MainActivity"
android:configChanges="orientation|screenSize"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
<uses-permission android:name="android.permission.CAMERA"/>
<uses-feature android:name="android.hardware.camera" />
<uses-feature android:name="android.hardware.camera" android:required="true" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="com.android.vending.BILLING" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
</manifest>
and here's Gradle :
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.0"
defaultConfig {
applicationId "com.vladdrummer.headsup"
minSdkVersion 11
targetSdkVersion 25
versionCode 7
versionName "1.01"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:25.1.0'
compile "com.android.support:support-core-utils:25.1.0"
testCompile 'junit:junit:4.12'
compile project(':ldialogs')
}
just in case : here's the library's (module) manifest :
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="uk.me.lewisdeane.ldialogs">
<application android:allowBackup="true" android:label="#string/lib_name"
android:supportsRtl="true">
</application>
</manifest>
and here's the module's Gradle :
apply plugin: 'com.android.library'
android {
compileSdkVersion 25
buildToolsVersion "25.0.0"
defaultConfig {
minSdkVersion 11
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:25.0.0'
testCompile 'junit:junit:4.12'
}