Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-83376

add_library cannot create imported target XXX because another target with the same name already exists.

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • P0: Blocker
    • None
    • 5.15.0 Beta3
    • Build System
    • None
    • Windows

    Description

      Trying to build MuseScore using MSVC 2019 and msvc2019_64 gives:

      CMake Error at C:/Qt/5.15.0/msvc2019_64/lib/cmake/Qt5Qml/Qt5Qml_QDebugMessageServiceFactory.cmake:2 (add_library):
      add_library cannot create imported target
      "Qt5::QDebugMessageServiceFactory" because another target with the same
      name already exists.
      Call Stack (most recent call first):
      C:/Qt/5.15.0/msvc2019_64/lib/cmake/Qt5Qml/Qt5QmlConfigExtras.cmake:4 (include)
      C:/Qt/5.15.0/msvc2019_64/lib/cmake/Qt5Qml/Qt5QmlConfig.cmake:249 (include)
      build/FindQt5.cmake:40 (find_package)
      CMakeLists.txt:87 (include)

      It did work with beta 2.
      And (still) works with msvc2017_64.

      Attachments

        Issue Links

          Activity

            People

              qtbuildsystem Qt Build System Team
              jojo-schmitz Joachim Schmitz
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: