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

cannot link moc: undefined reference to `QCommandLineOption::setFlags

    XMLWordPrintable

Details

    • Bug
    • Resolution: Incomplete
    • P1: Critical
    • None
    • 5.9.0 Alpha
    • Build tools: moc
    • None
    • FreeBSD 11, 32-bit
      FreeBSD clang version 3.8.0 (tags/RELEASE_380/final 262564) (based on LLVM 3.8.0)
      Target: i386-unknown-freebsd11.0
      Thread model: posix
      InstalledDir: /usr/bin

    Description

      $ make
      cd src/ && ( test -e Makefile || /usr/home/rutledge/dev/qt59-dbg/qtbase/bin/qmake -o Makefile /usr/home/rutledge/dev/qt59/qtbase/src/src.pro ) && make -f Makefile
      cd tools/bootstrap/ && ( test -e Makefile || /usr/home/rutledge/dev/qt59-dbg/qtbase/bin/qmake -o Makefile /usr/home/rutledge/dev/qt59/qtbase/src/tools/bootstrap/bootstrap.pro ) && make -f Makefile
      cd tools/moc/ && ( test -e Makefile || /usr/home/rutledge/dev/qt59-dbg/qtbase/bin/qmake -o Makefile /usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/moc.pro ) && make -f Makefile
      clang++ -Wl,--gc-sections -pthread -o ../../../bin/moc .obj/moc.o  .obj/preprocessor.o  .obj/generator.o  .obj/parser.o  .obj/token.o  .obj/main.o   -L/usr/local/lib -L/usr/home/rutledge/dev/qt59-dbg/qtbase/lib -lQt5Bootstrap -lz
      .obj/main.o: In function `runMoc(int, char**)':
      /usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/main.cpp:(.text+0xc1d): undefined reference to `QCommandLineOption::setFlags(QFlags<QCommandLineOption::Flag>)'
      /usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/main.cpp:(.text+0xd3b): undefined reference to `QCommandLineOption::setFlags(QFlags<QCommandLineOption::Flag>)'
      /usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/main.cpp:(.text+0xe59): undefined reference to `QCommandLineOption::setFlags(QFlags<QCommandLineOption::Flag>)'
      /usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/main.cpp:(.text+0x1036): undefined reference to `QCommandLineOption::setFlags(QFlags<QCommandLineOption::Flag>)'
      /usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/main.cpp:(.text+0x1154): undefined reference to `QCommandLineOption::setFlags(QFlags<QCommandLineOption::Flag>)'
      .obj/main.o:/usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/main.cpp:(.text+0x1272): more undefined references to `QCommandLineOption::setFlags(QFlags<QCommandLineOption::Flag>)' follow
      .obj/main.o: In function `runMoc(int, char**)':
      /usr/home/rutledge/dev/qt59/qtbase/src/tools/moc/main.cpp:(.text+0x508e): undefined reference to `QtPrivate::QStringList_join(QStringList const&, QLatin1String)'
      clang++: error: linker command failed with exit code 1 (use -v to see invocation)
      *** Error code 1
      
      Stop.
      make[2]: stopped in /usr/home/rutledge/dev/qt59-dbg/qtbase/src/tools/moc
      *** Error code 1
      
      Stop.
      make[1]: stopped in /usr/home/rutledge/dev/qt59-dbg/qtbase/src
      *** Error code 1
      
      Stop.
      make: stopped in /usr/home/rutledge/dev/qt59-dbg/qtbase
      

      It seems to be there though:

      $ nm -C ./lib/libQt5Bootstrap.a  | grep -i QCommandLineOption
               U QCommandLineOption::QCommandLineOption(QStringList const&, QString const&, QString const&, QString const&)
               U QCommandLineOption::QCommandLineOption(QCommandLineOption const&)
               U QCommandLineOption::~QCommandLineOption()
      00000000 T QCommandLineParser::addOptions(QList<QCommandLineOption> const&)
      00000000 T QCommandLineParser::addOption(QCommandLineOption const&)
      00000000 W QList<QCommandLineOption>::detach_helper_grow(int, int)
               U QCommandLineOption::description() const
               U QCommandLineOption::defaultValues() const
               U QCommandLineOption::flags() const
               U QCommandLineOption::names() const
               U QCommandLineOption::valueName() const
      00000000 T QCommandLineParser::isSet(QCommandLineOption const&) const
      00000000 T QCommandLineParser::value(QCommandLineOption const&) const
      00000000 T QCommandLineParser::values(QCommandLineOption const&) const
      qcommandlineoption.o:
      00000000 T QCommandLineOption::setValueName(QString const&)
      00000000 T QCommandLineOption::setDescription(QString const&)
      00000000 T QCommandLineOption::setDefaultValue(QString const&)
      00000000 T QCommandLineOption::setDefaultValues(QStringList const&)
      00000000 T QCommandLineOption::setFlags(QFlags<QCommandLineOption::Flag>)
      00000000 T QCommandLineOption::QCommandLineOption(QStringList const&)
      00000000 T QCommandLineOption::QCommandLineOption(QStringList const&, QString const&, QString const&, QString const&)
      00000000 T QCommandLineOption::QCommandLineOption(QString const&)
      00000000 T QCommandLineOption::QCommandLineOption(QString const&, QString const&, QString const&, QString const&)
      00000000 T QCommandLineOption::QCommandLineOption(QCommandLineOption const&)
      00000000 T QCommandLineOption::QCommandLineOption(QStringList const&)
      00000000 T QCommandLineOption::QCommandLineOption(QStringList const&, QString const&, QString const&, QString const&)
      00000000 T QCommandLineOption::QCommandLineOption(QString const&)
      00000000 T QCommandLineOption::QCommandLineOption(QString const&, QString const&, QString const&, QString const&)
      00000000 T QCommandLineOption::QCommandLineOption(QCommandLineOption const&)
      00000000 T QCommandLineOption::~QCommandLineOption()
      00000000 T QCommandLineOption::~QCommandLineOption()
      00000000 T QCommandLineOption::operator=(QCommandLineOption const&)
      00000000 T QCommandLineOptionPrivate::removeInvalidNames(QStringList)
      00000000 W QCommandLineOptionPrivate::QCommandLineOptionPrivate(QStringList const&)
      00000000 W QCommandLineOptionPrivate::QCommandLineOptionPrivate(QString const&)
      00000000 W QCommandLineOptionPrivate::QCommandLineOptionPrivate(QCommandLineOptionPrivate const&)
      00000000 W QCommandLineOptionPrivate::~QCommandLineOptionPrivate()
      00000000 T QCommandLineOption::description() const
      00000000 T QCommandLineOption::defaultValues() const
      00000000 T QCommandLineOption::flags() const
      00000000 T QCommandLineOption::names() const
      00000000 T QCommandLineOption::valueName() const
      

      Attachments

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

        Activity

          People

            Unassigned Unassigned
            srutledg Shawn Rutledge
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes