inviwo icon indicating copy to clipboard operation
inviwo copied to clipboard

CMake warnings for missing module dependencies

Open r-englund opened this issue 5 years ago • 1 comments

Currently, warnings are printed while configuring cmake if there are modules in IVW_EXTERNAL_MODULES that depends on some module that is not in IVW_EXTERNAL_MODULES (or inviwo-core).

For example, in my repo I have a bunch of modules, one of them depends on the VTK module in modules/misc. In my current build I do not use that module nor any module from modules/misc, hence I haven't added modules/misc to IVW_EXTERNAL_MODULES.
Every time I run cmake I get warnings for that missing dependency.
IMO this is a bit too verbose. It could be shown only when the module needing the dependency is enabled, and then we could use error instead of warning.

CMake Warning at cmake/globalmacros.cmake:96 (message):
  Found dependency: "InviwoVTKModule", in depends.cmake for module:
  "VTKEnsightReading".  But no such Inviwo module was registered.
Call Stack (most recent call first):
  cmake/globalmacros.cmake:333 (ivw_private_check_dependency_list)
  CMakeLists.txt:145 (ivw_register_modules)

r-englund avatar Aug 26 '19 07:08 r-englund

Sounds reasonable

petersteneteg avatar Aug 26 '19 09:08 petersteneteg