[cmake-developers] find_package without REQUIRED can cause fatal error now

Bill Hoffman bill.hoffman at kitware.com
Mon Jul 30 10:33:10 EDT 2012


Alex added this check:
  http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=a2be068c

It guards against broken installations of packages.  This is a good 
thing.  However, it is causing a failed test:


http://open.cdash.org/buildSummary.php?buildid=2465838


--    Checking FindVTK
CMake Error at //lib/vtk-5.8/VTKTargets-debug.cmake:996 (MESSAGE):
   The imported target "vtkWrapTcl" references the file

      "//bin/vtkWrapTcl"

   but this file does not exist.  Possible reasons include:


So, there is a bad config file for VTK on this machine.

However, if someone does an optional find_package it should not error 
out.   If you were building a project that you did not write the cmake 
files for and came across this error for an optional part of the system 
you might be stuck.  Not sure how to make the required bit propagate 
down to where this error is produced...

Thoughts?

-Bill



More information about the cmake-developers mailing list