• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps android + eclipse = jar mismatch fix your dependencies

androgaga

Newbie
Hello

Today I created my first game for Android using libGDX and Eclipse.

And yes, the desktop-version app runs fine !

But the android-version won't run :

- Your project contains errors, please fix them before running your application
- Problems : "Jar mismatch! Fix your dependencies"

Could someone please help ??? thanks :)

PS :
Code:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.badlogic.drop"
    android:versionCode="1"
    android:versionName="1.0" >

    <uses-sdk android:minSdkVersion="5" android:targetSdkVersion="17" />

    <application
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name" >
        <activity
            android:name=".MainActivity"
            android:label="@string/app_name"
            android:screenOrientation="landscape"
            android:configChanges="keyboard|keyboardHidden|orientation|screenSize">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
    </application>

</manifest>

AND :
Code:
package com.badlogic.drop;

import android.os.Bundle;

import com.badlogic.gdx.backends.android.AndroidApplication;
import com.badlogic.gdx.backends.android.AndroidApplicationConfiguration;

public class MainActivity extends AndroidApplication {
	   @Override
	   public void onCreate(Bundle savedInstanceState) {
	      super.onCreate(savedInstanceState);
	        
	      AndroidApplicationConfiguration cfg = new AndroidApplicationConfiguration();
	      cfg.useGL20 = true;
	      cfg.useAccelerometer = false;
	      cfg.useCompass = false;
	        
	      initialize(new Drop<Object>(), cfg);
	   }
	}
 
Hi, tanks for asking, in project-android/libs, it contains 2 folders 'armeabi' ans 'areabi-v7a', and there are 6 other archivesrfor gdx...

Th
 
it might be the version of android you have installed. Check that the version of android your project requires is installed on the machine.
In eclipse, right click on the project folder in the package frame

click on properties (probably the last item on the list)

click android

if your sdk is properly configured then you will see a list of all versions that are available. If none of them is ticked, then you should select the latest version you see.

Otherwise I am not so sure what your problem currently is
 
Back
Top Bottom