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

Wasm build fails when linking both QtCharts and QtGraphs

    XMLWordPrintable

Details

    • WebAssembly

    Description

      When compiling project that links both QtCharts and QtGraphs, there are link errors:

      wasm-ld: error: duplicate symbol: QAreaSeries::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Charts.a(qareaseries.cpp.o)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Graphs.a(mocs_compilation.cpp.o)

      wasm-ld: error: duplicate symbol: QAreaSeries::staticMetaObject
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Charts.a(qareaseries.cpp.o)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Graphs.a(mocs_compilation.cpp.o)

      wasm-ld: error: duplicate symbol: QAreaSeries::colorChanged(QColor)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Charts.a(qareaseries.cpp.o)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Graphs.a(mocs_compilation.cpp.o)

      wasm-ld: error: duplicate symbol: QDateTimeAxis::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Charts.a(qdatetimeaxis.cpp.o)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Graphs.a(mocs_compilation.cpp.o)

      wasm-ld: error: duplicate symbol: QDateTimeAxis::staticMetaObject
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Charts.a(qdatetimeaxis.cpp.o)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Graphs.a(mocs_compilation.cpp.o)

      wasm-ld: error: duplicate symbol: QAbstractAxis::labelsVisibleChanged(bool)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Charts.a(qabstractaxis.cpp.o)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Graphs.a(mocs_compilation.cpp.o)

      wasm-ld: error: duplicate symbol: QAbstractAxis::gridVisibleChanged(bool)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Charts.a(qabstractaxis.cpp.o)
      >>> defined in C:/Qt/6.8.2/wasm_singlethread/lib/libQt6Graphs.a(mocs_compilation.cpp.o)

      wasm-ld: error: too many errors emitted, stopping now (use -error-limit=0 to see all errors)
      em++: error: 'C:/Utils/emsdk/upstream/bin\wasm-ld.exe @C:\Users\qiche\AppData\Local\Temp\emscripten_xlaa9mym.rsp.utf-8' failed (returned 1)
      ninja: build stopped: subcommand failed.
      12:11:50: The process "C:\Qt\Tools\CMake_64\bin\cmake.exe" exited with code 1.
      Error while building/deploying project Responsive_ScadaApp (kit: WebAssembly Qt 6.8.2 (single-threaded))
      When executing step "Build"

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            oulu_hillbilly Sami Varanka
            qihuang Qichen Huang
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes