Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-32674

Qt Creator uses wrong source reference for linker messages

XMLWordPrintable

    • Linux/Wayland
    • 102333d4a (master)

      When ld outputs errors about missing functions, the message contains location at which the functions is used, but Qt Creator picks up location in .o file and upon clicking the error, opens a binary.

      /usr/lib/gcc/x86_64-pc-linux-gnu/14/../../../../x86_64-pc-linux-gnu/bin/ld: Build.dir/Target.dir/path/to/source_file.cpp.o: in function `foo()':
      /path/to/source_file.cpp:42:(.text+0xb58): undefined reference to `bar()'
      /usr/lib/gcc/x86_64-pc-linux-gnu/14/../../../../x86_64-pc-linux-gnu/bin/ld: /path/to/source_file.cpp:138:(.text+0xbc2): undefined reference to `bar()'
      

      Rather than a link to /path/to/source_file.cpp:42, Qt Creator provides a link to Build.dir/Target.dir/path/to/source_file.cpp.o

        For Gerrit Dashboard: QTCREATORBUG-32674
        # Subject Branch Project Status CR V

            kandeler Christian Kandeler
            eugeneshalygin Eugene Shalygin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes