title: CMake: target_include_directories() prints an error when I try to add the source directory itself, or one of its subdirectories
body: <p>I am writing a C++ library (header-only) and am using CMake to generate my (Visual Studio) project and solution files. I'm also writing a test suite, which is part of the same CMake project.</p>
  
  <p>My problem occurs when I call target_include_directories() on the target that represents my header-only library, so that consumers of my library may find its header files. I get the following error message (even though generation is NOT aborted).</p>
  
  <pre><code>CMake Error in CMakeLists.txt:
    Target "Fonts" INTERFACE_INCLUDE_DIRECTORIES property contains path:
  
      "D:/Projects/GPC/fonts/include"
  
    which is prefixed in the source directory.
  </code></pre>
  
  <p>(D:/Projects/GPC/Fonts being the top-level directory of my library project. Btw the problem remains if I move my header files to the top directory.)</p>
  
  <p>The offending line in my CMakeLists.txt is this (adapted for simplicity):</p>
  
  <pre><code>target_include_directories(Fonts INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/include")
  </code></pre>
  
  <p>I do not understand what I'm doing wrong. Without target_include_directories(), code of consumer projects simply can't include my header files (unless in installed form, but I haven't gotten to that yet, and in any case I want to be able to use my library from its build tree, without installation.)</p>
  
  <p>I feel like I'm missing something basic here; yet I've searched for hours without finding a solution or explanation.</p>