1

I'm trying to build simple Qt project with android profile, but receiving strange error:

Android_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug/android-build/src/org/qtproject/qt5/android/bindings/QtApplication.java:46: error: duplicate class: org.qtproject.qt5.android.bindings.QtApplication public class QtApplication extends Application

after androiddeployqt run

Sergey
  • 176
  • 2
  • 12

1 Answers1

0

Right, I'm going to assume this is the same as what has happened to myself:

  1. You've upgraded Android Studio which has broken the Qt build for Android.
  2. You've managed to solve the issue of upgrading gradle, resolving previous errors. ie from here
  3. Now you're getting 'error: duplicate class'.

Solution:

When Qt builds the project all files are stored in 'build-myappname-Android_for_armeabi_v7a_GCC_4_9_Qt_5_8_0-Debug

Delete that folder and rebuild the project.

You may need to clean and rerun qmake, but I doubt that is required. I only do that out of habit.

Community
  • 1
  • 1
WLGfx
  • 1,169
  • 15
  • 31