Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-975

Include path ignore the local path for generated types

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • 5.12.3
    • 5.12.1
    • Shiboken
    • None
    • All
    • 009c7413952c01c7ba4722aa73c968e07dc17e04 (pyside/pyside-setup/5.12)

    Description

      I'm trying to wrap a project which uses directory names to "namespace" includes, i.e.

      myproject/mycomponent/some_file.hpp

      I can add those files to the wrapper for each object with "<include file-name=...>" directives, but most of the generated headers just include the global "#include <some_file.hpp>".

      This would require to add all "local" component include directories to the global include path for the compiler, and might lead to problems with ambiguous filenames.

      It would be helpful to include the path for discovered headers.

       

      Some hints from my looking into the issue that might be helpful:

      The problem seems to be in ApiExtractor/abstractmetabuilder.cpp - AbstractMetaBuilderPrivate::setInclude() where the the filepath is stripped and just the filename is used. The input for this method is the relative path from the current working dir, but it would need to be looked up in the include directories provided in the config, e.g. when setInclude is called with "my/lib/path/include/myproject/mycomponent/some_file.hpp", the method would have to match "my/lib/path/include" against the "include-path" or "system-include-paths" and extract the actual usable path given this compiler include configuration.

      Attachments

        For Gerrit Dashboard: PYSIDE-975
        # Subject Branch Project Status CR V

        Activity

          People

            kleint Friedemann Kleint
            volka Volker Aßmann
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes