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

documentviewer demo causes lots of warnings when building on iOS

    XMLWordPrintable

Details

    • iOS/tvOS/watchOS
    • c8b3c0935 (dev), ae584b796 (6.6)

    Description

      After https://codereview.qt-project.org/c/qt/qtdoc/+/482821 is applied, building the qtdocs documentviewer demo causes a lot of warnings when building for iOS:

      ld: warning: duplicate symbol 'AbstractViewer::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::qt_metacall(QMetaObject::Call, int, void**)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::metaObject() const' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::uiInitialized()' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'vtable for AbstractViewer' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'typeinfo name for AbstractViewer' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'typeinfo for AbstractViewer' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::showMessage(QString const&, int)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::documentLoaded(QString const&)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::qt_metacast(char const*)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::printingEnabledChanged(bool)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::staticMetaObject' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/build/documentviewer.build/Debug-iphoneos/Objects-normal/arm64/mocs_compilation.o
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::qt_metacall(QMetaObject::Call, int, void**)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::metaObject() const' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::uiInitialized()' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'vtable for AbstractViewer' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'typeinfo name for AbstractViewer' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'typeinfo for AbstractViewer' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::showMessage(QString const&, int)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::documentLoaded(QString const&)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::qt_metacast(char const*)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::printingEnabledChanged(bool)' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      ld: warning: duplicate symbol 'AbstractViewer::staticMetaObject' in:
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/txtviewer/Debug-iphoneos/libtxtviewer.a(mocs_compilation.o)
          /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/plugins/jsonviewer/Debug-iphoneos/libjsonviewer.a(mocs_compilation.o)
      
      
      GenerateDSYMFile /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/app/Debug-iphoneos/documentviewer.app.dSYM /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/app/Debug-iphoneos/documentviewer.app/documentviewer (in target 'documentviewer' from project 'documentviewer')
          cd /Volumes/T3/Dev/qt/worktrees/dev/qtdoc/examples/demos/documentviewer
          /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/dsymutil /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/app/Debug-iphoneos/documentviewer.app/documentviewer -o /Volumes/T3/Dev/qt/builds/6.6-off/documentviewer_ios/app/Debug-iphoneos/documentviewer.app.dSYM
      warning: (arm64) /Users/qt/work/qt/qtwebengine/build/target/src/pdf/Debug/arm64/obj/third_party/pdfium/core/fxcrt/fxcrt/binary_buffer.o unable to open object file: No such file or directory
      warning: (arm64) /Users/qt/work/qt/qtwebengine/build/target/src/pdf/Debug/arm64/obj/third_party/pdfium/core/fxcrt/fxcrt/bytestring.o unable to open object file: No such file or directory
      warning: (arm64) /Users/qt/work/qt/qtwebengine/build/target/src/pdf/Debug/arm64/obj/third_party/pdfium/core/fxcrt/fxcrt/cfx_bitstream.o unable to open object file: No such file or directory
      warning: (arm64) /Users/qt/work/qt/qtwebengine/build/target/src/pdf/Debug/arm64/obj/third_party/pdfium/core/fxcrt/fxcrt/cfx_datetime.o unable to open object file: No such file or directory
      warning: (arm64) /Users/qt/work/qt/qtwebengine/build/target/src/pdf/Debug/arm64/obj/third_party/pdfium/core/fxcrt/fxcrt/cfx_read_only_span_stream.o unable to open object file: No such file or directory
      ...
      

      Not sure why the dsymutil warnings happen

      But to avoid the duplicate symbol warnings, the demo should have one common library that is linked into each static plugin, instead of compiling ../../app/abstractviewer.cpp 3 times for each static plugin, and then linking all of them into the app.

      Attachments

        Issue Links

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

          Activity

            People

              axelspoerl Axel Spoerl
              alexandru.croitor Alexandru Croitor
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes