Ashish Tiwari
Ashish Tiwari

Reputation: 2246

Why the APK file created by Android Studio is different from APK created by Eclipse?

I have developed an Android application in Eclipse and used the APK generated by Eclipse, now I have moved to Android Studio as it is Official IDE for Android development. I have imported the project in Android Studio and got the APK file.

The problem is if I install the new APK (Generated by Android Studio) in my device that has the old APK(Generated by Eclipse) installed on it, then device is showing a message "An existing package by same name with a conflicting signature is already installed".

My Question is why both APK files are different if both is developed and generated from same PC?

Upvotes: 0

Views: 312

Answers (2)

Ke Di
Ke Di

Reputation: 345

I assume you have two Android SDKs on your PC which means you may have two different default keystore on your PC (Or maybe you reinstalled your SDK so the default keystore is changed).

You can find your keystore at here:

OS X and Linux: ~/.android/

Windows Vista and Windows 7: C:\Users\your_user_name\.android\

This problem won't happen if you generate a specific keystore for your application. Later no matter which PC you use, the generated APK can always overwrite the previous version (means previous version are signed by the same keystore, and the version code is smaller).

Upvotes: 1

Shakeeb Ayaz
Shakeeb Ayaz

Reputation: 6096

Android studio is having gradle feature which builds apk a way different than the eclipse thats why different signature .

Upvotes: 1

Related Questions