parse error apk android (syntax error, parsing error) - android

Please help, I am suffering a second day.
The manifesto is written:
<uses-sdk
android:minSdkVersion="7"
android:targetSdkVersion="8" />
Collect the file apk to install it on lg optimus one (2.2) and nexus 4
nexus 4 on works
lg optimus one to write error
What's the problem?
thank you
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="my.prog"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="7"
android:targetSdkVersion="8" />
<application
android:allowBackup="true"
android:icon="#drawable/ic_icon"
android:label="#string/app_name"
android:theme="#style/AppTheme" >
<activity
android:name="my.prog.MainActivity"
android:screenOrientation="portrait"
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>
</manifest>
log error:
87-102/system_process W/PackageParser﹕ /data/app/vmdl35341.tmp (at Binary XML file line #3): Requires newer sdk version #9 (current version is #8)

Problem was solved, it may be helpful:
file build.gradle
defaultConfig {
minSdkVersion 7
targetSdkVersion 18
}
need to change the minSdkVersion
p.s.if it did not help change the manifest

Related

Android Studio 3.1.3 android:roundIcon

I have a Compile Error telling me to remove android:roundIcon from AndroidManifest.xml, similar to this other post:
No resource identifier found for attribute 'roundIcon' in package 'android'
I have targeted API 15 and only have that version installed, but Android Studio keeps re-adding that line and breaking compilation. How do I stop/fix this?
My build.gradle has:
minSdkVersion 15
targetSdkVersion 15
AndroidManifest.xml:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.testapplication"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="15"
android:targetSdkVersion="15" />
<application
android:allowBackup="true"
android:debuggable="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="com.example.testapplication.MainActivity" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
It just keeps re-adding android:roundIcon="#mipmap/ic_launcher_round" if I delete it. How do I stop that behaviour?
Thanks.
Just remove all the "#mipmap/ic_launcher" for round icons. You'll be done. Also, if it doesn't solve, try adding your own icon for the same using an image asset and setting it as "ic_launcher" icon.

Android error: Application is not installed on your phone

I am getting this error when trying to install my exported unsigned application on tablet pc (running Android 4.04. version). App is normally installing and running in Android emulator in Eclipse. I tried removing and reinstalling it, but that didn't help either. Atached is my AndroidManifest.xml since problem is often there (but I can't see any duplicate code).
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="hr.punctum.LociranjePonudaProizvoda"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk android:minSdkVersion="9" android:targetSdkVersion="16" />
<application
android:label="#string/app_name"
android:icon="#drawable/ic_launcher"
android:theme="#style/AppTheme">
<activity
android:label="#string/app_name"
android:name=".ListaProizvoda" >
<intent-filter >
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name="DetaljiProizvoda"></activity>
<activity android:name="GMapsActivity"></activity>
<uses-library android:name="com.google.android.maps" />
</application>
<uses-permission android:name="android.permission.INTERNET"/>
</manifest>
The only thing suspicious I see is the uses-library tag, do you have the Google Maps lib in your tablet? (if yes then you should have the following files in it)
/system/etc/permissions/com.google.android.maps.xml
/system/framework/com.google.android.maps.jar
Without the lib the apk installation will fail with INSTALL_FAILED_MISSING_SHARED_LIBRARY error.

Error string types not allowed at android:configChanges in manifest file

Here is my manifest file which shows error string types not allowed at android:configChanges please help me in rectification of the error.
below is my manifest file.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.ifahja.banner"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk android:minSdkVersion="10"/>
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name" >
<activity
android:name=".MyBannerActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name="com.google.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>
</application>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
</manifest>
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
screenSize & smallestScreenSize attributes are not available in SDK 10.They are been introduced in API level 13.
http://developer.android.com/guide/topics/manifest/activity-element.html#config
Make sure you have the latest copy of the Android SDK and that you're
compiling against at least Android v3.2 (set target in
project.properties to android-13).
The Google Mobile Ads SDK for Android requires a run-time of Android 2.3 or later (set
android:minSdkVersion to at least 9 in your AndroidManifest.xml).
This means you can develop with the latest version of the Android SDK
and your app will still run on an earlier Android version (2.3
minimum).

App fails with permission when try to debug on Android 4.0 device

I've written app for Android 2.2 (target version) and I tried to run it on device with Android 4.0.3 but it fails with granting permission for internet connection. It run without problems on Android 2.3. Is there any way to run that app on A4.0 without changing target SDK version?
My AndroidManifest.xml:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="pl.niemier.allegro"
android:versionCode="1"
android:versionName="1.0" android:installLocation="auto">
<uses-sdk android:minSdkVersion="8" android:targetSdkVersion="10"/>
<uses-permission android:name="android.permission.INTERNET"/>
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name" android:debuggable="true">
<activity
android:name=".MainActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".ShowAuctionActivity"></activity>
<activity android:name=".SearchFormActivity"></activity>
<activity android:name=".UserInfoActivity"></activity>
<activity android:name=".ConfigPanelActivity"></activity>
</application>
</manifest>
Try adding the SDK target version in you manifest file:
<uses-sdk android:minSdkVersion="8" />
Please check if the version number is correct.
I assume you have added <uses-permission android:name="android.permission.INTERNET" /> since it works on Android 2.3.

Valid sdkVersion for slideme.org

I am trying to upload an apk to slidme.org
http://slideme.org/node/add/mobileapp
But I get this validation failing
Your application must have a valid sdkVersion set. You need to edit
your AndroidManifest.xml file to fix this, and then upload again the
.apk file.
What is the problem with my manifest ?
<application
android:screenOrientation="portrait"
android:icon="#drawable/icon"
android:label="#string/app_name" >
<activity
android:screenOrientation="portrait"
android:label="#string/app_name"
android:name=".Start" >
<intent-filter >
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
<uses-sdk
android:minSdkVersion="4"
android:targetSdkVersion="7" />
I had similar problem and solve it by:
remove:
minSdkVersion 15
targetSdkVersion 28
from gradle.
and adding :
<uses-sdk
android:minSdkVersion="15"
android:targetSdkVersion="26" />
to manifest.
It seems slideme isn't up to date...
Solved it by removing minSdkVersion. and refered targetSdkVersion to min version.
So in your case it will become

Categories

Resources