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

prl file is read but LIBS is not updated

    XMLWordPrintable

Details

    Description

      Hi

      as far as I understand from qmake documentation, http://doc.qt.nokia.com/4.6/qmake-environment-reference.html#libdepend, prl files can keep track of additional static libraries to be linked in the application when linking to static libraries.

      Thus, in my library project I added

      1. save information about the library:
        CONFIG += create_prl

      and the .prl file actually gets created; the information which relates to other static libraries used is the following I guess

      QMAKE_PRL_LIBS = -LC:\Lore\Boost\lib -lboost_regex-mgw44-mt-1_43

      which correctly says that my library (in this case libsource-highlight.a) uses the boost library.

      Now, in an application that uses libsource-highlight.a I added

      CONFIG += link_prl

      and I put

      LIBS += <other stuff> -lsource-highlight

      however, the directives

      -LC:\Lore\Boost\lib -lboost_regex-mgw44-mt-1_43

      are not automatically added by qmake to LIBS,

      Please, note that libsource-highlight.a is correctly found (I put the right library path). Moreover, by running qmake with -d the .prl file is parsed

      DEBUG 1: Project file: reading C:/Lore/usr/lib/source-highlight.prl
      DEBUG 1: Project Parser: c:\Lore\usr\lib\source-highlight.prl:1 :QMAKE_PRL_BUILD_DIR: :=: (C:/Lore/work/source-highlight-build-desktop/lib/srchilite)
      DEBUG 1: Project Parser: c:\Lore\usr\lib\source-highlight.prl:2 :QMAKE_PRO_INPUT: :=: (srchilite.pro)
      DEBUG 1: Project Parser: c:\Lore\usr\lib\source-highlight.prl:3 :QMAKE_PRL_TARGET: :=: (libsource-highlight)
      DEBUG 1: Project Parser: c:\Lore\usr\lib\source-highlight.prl:4 :QMAKE_PRL_CONFIG: :=: (include_source_dir lex yacc warn_on debug uic resources incremental_off thread_off warn_on link_prl copy_dir_files debug_and_release_target precompile_header debug stl exceptions rtti static console warn_on create_prl staticlib static)
      DEBUG 1: Project Parser: c:\Lore\usr\lib\source-highlight.prl:5 :QMAKE_PRL_VERSION: :=: (3)
      DEBUG 1: Project Parser: c:\Lore\usr\lib\source-highlight.prl:6 :QMAKE_PRL_LIBS: :=: (-LC:\Lore\Boost\lib -lboost_regex-mgw44-mt-1_43)

      many thanks in advance
      Lorenzo

      Attachments

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

        Activity

          People

            buddenha Oswald Buddenhagen
            lorebett Lorenzo Bettini
            Votes:
            4 Vote for this issue
            Watchers:
            9 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes