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

Support OUTPUT_NAME and RUNTIME_OUTPUT_DIRECTORY when running Android tests

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • Qt Creator 18.0.0
    • None

      Under QTBUG-138622, the Android script runner started supporting OUTPUT_NAME and RUNTIME_OUTPUT_NAME properties to decide where the script would end up being written. In Qt Creator, the only place (atm) that uses the runner is the test plugin (added in https://codereview.qt-project.org/c/qt-creator/qt-creator/+/596953), so if a test sets those properties now, Qt Creator won't be able to run the test properly and will fail, it will fallback to trying to run the lib<target>_<abi>.so which fails.

      Qt Creator has no details about the values of OUTPUT_NAME and RUNTIME_OUTPUT_DIRECTORY that are set in CMake. The issue has two parts, the test plugin aims to keep things simple and not have build system implementation details there, so anything we want to do to support this fully would better go into the cmake implementation.

      Then, Qt Creator mainly uses the file-api, to get target details, however, it seems that CMake is not really writing the value of OUTPUT_NAME and RUNTIME_OUTPUT_DIRECTORY into the file-api json files nor to the cache files.

      I see that we already write the OUTPUT_NAME value (maybe indirectly) to the android deployment json file under "application-binary" key, but nothing writes the RUNTIME_OUTPUT_DIRECTORY. Also, for the value of OUTPUT_NAME only a last resort is to also parse the value from the generated app shared library as it will have that name, but ofc that doesn't solve the issue.

      So to support this we either need to wait for CMake to offer a way to do this or simply write those values ourselves and have Qt Creator handle them.

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

            portale Alessandro Portale
            assam Assam Boudjelthia
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes