Uploaded image for project: 'HPCC'
  1. HPCC
  2. HPCC-20334

Proper use of conditional CMake target dependencies

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 7.2.0
    • Fix Version/s: 7.2.0
    • Component/s: ConfigManager 2.0
    • Labels:

      Description

      Should CMake targets that depend upon conditionally defined targets also be conditionally defined?

      The configuration/config2 project is conditional upon USE_BOOST_REGEX. If USE_BOOST_REGEX is not set, the config2 target is never defined.

      The esp/services/ws_config2 project is unconditionally dependent upon the config2 target. If USE_BOOST_REGEX is not set, a CMake error occurs trying to configure the ws_config2 target.

      The default configuration for the platform sets USE_BOOST_REGEX. The default configurations for plugins may not set this value. Running CMake for plugins that do not set this value results in errors while processing the platform's configuration.

      Is it acceptable for a plugin to inherit a dependency from a platform component that the plugin does not depend upon?

        Attachments

          Activity

            People

            • Assignee:
              kenrowland Kenneth A Rowland
              Reporter:
              klemti01 Tim Klemm
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: