<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">Hej,</div><div class=""><br class=""></div><div class="">Just re-read your question to make sure I understood, because I thought in the project I currently work in we had those targets, but not the problems. So I checked and realised we actually gotten rid of those INTERFACE libraries, because we encountered all kinds of trouble, amongst which one is the problem you refer to. Another problem for instance, is that INTERFACE link dependencies don’t get transferred like with normal libraries. Extremely annoying, so we decided the ‘academical’ use of an INTERFACE library wasn’t (nearly) worth the effort.</div><div class=""><br class=""></div><div class="">Not a resolution to your problem though ……</div><div class=""><br class=""></div><div class="">Sincerely, Jakob</div><div class=""><br class=""></div><br class=""><div><blockquote type="cite" class=""><div class="">On 02 Jan 2016, at 13:12, Klaim - Joël Lamotte <<a href="mailto:mjklaim@gmail.com" class="">mjklaim@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><br class="Apple-interchange-newline"><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><div class="gmail_quote" style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;">On 1 January 2016 at 11:00, Jakob van Bethlehem<span class="Apple-converted-space"> </span><span dir="ltr" class=""><<a href="mailto:jsvanbethlehem@gmail.com" target="_blank" class="">jsvanbethlehem@gmail.com</a>></span><span class="Apple-converted-space"> </span>wrote:<br class=""><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex;"><div style="word-wrap: break-word;" class=""><div class="">Hej Joël,</div><div class=""><br class=""></div><div class="">The command you’re looking for is ‘source_group’, see <a href="https://cmake.org/cmake/help/v3.0/command/source_group.html" target="_blank" class="">https://cmake.org/cmake/help/v3.0/command/source_group.html</a></div><div class=""><br class=""></div></div></blockquote><div class=""><br class=""></div><div class="">I use this already but it works only with source files, not with targets. With targets you need to set the FOLDER property.</div><div class=""> </div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex;"><div style="word-wrap: break-word;" class=""><div class=""></div><div class="">Sincerely,</div><div class="">Jakob</div><div class=""><br class=""></div><br class=""><div class=""><blockquote type="cite" class=""><div class=""><div class="h5"><div class="">On 30 Dec 2015, at 20:52, Klaim - Joël Lamotte <<a href="mailto:mjklaim@gmail.com" target="_blank" class="">mjklaim@gmail.com</a>> wrote:</div><br class=""></div></div><div class=""><div class=""><div class="h5"><div dir="ltr" class=""><div class="">The following CMake script:</div><div class=""><br class=""></div><div class="">   <span class="Apple-converted-space"> </span>cmake_minimum_required(VERSION 3.4)</div><div class="">    </div><div class="">   <span class="Apple-converted-space"> </span>add_library( mylib INTERFACE )</div><div class="">   <span class="Apple-converted-space"> </span>set_property( TARGET mylib PROPERTY FOLDER /some/dir )</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">Will trigger this error on configuration:</div><div class=""><br class=""></div><div class="">   <span class="Apple-converted-space"> </span>CMake Error at CMakeLists.txt:4 (set_property):</div><div class="">     <span class="Apple-converted-space"> </span>INTERFACE_LIBRARY targets may only have whitelisted properties.  The</div><div class="">     <span class="Apple-converted-space"> </span>property "FOLDER" is not allowed.</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">This prevent any interface library to be organized in Visual Studio virtual folders.</div><div class="">Unfortunately it also mean that header-only targets can't be organized.</div><div class=""><br class=""></div><div class="">I have no idea how this should be solved. Should the property just be white-listed?</div><div class="">Or should a better have a another specific library mode for header-only targets?<br class=""></div><div class=""><br class=""></div><div class="">Is there any workaround?</div><div class=""><br class=""></div><div class="">Joël Lamotte</div><div class=""><br class=""></div></div></div></div>--<span class="Apple-converted-space"> </span><br class=""><br class="">Powered by<span class="Apple-converted-space"> </span><a href="http://www.kitware.com/" target="_blank" class="">www.kitware.com</a><br class=""><br class="">Please keep messages on-topic and check the CMake FAQ at:<span class="Apple-converted-space"> </span><a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank" class="">http://www.cmake.org/Wiki/CMake_FAQ</a><br class=""><br class="">Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br class=""><br class="">CMake Support:<span class="Apple-converted-space"> </span><a href="http://cmake.org/cmake/help/support.html" target="_blank" class="">http://cmake.org/cmake/help/support.html</a><br class="">CMake Consulting:<span class="Apple-converted-space"> </span><a href="http://cmake.org/cmake/help/consulting.html" target="_blank" class="">http://cmake.org/cmake/help/consulting.html</a><br class="">CMake Training Courses:<span class="Apple-converted-space"> </span><a href="http://cmake.org/cmake/help/training.html" target="_blank" class="">http://cmake.org/cmake/help/training.html</a><br class=""><br class="">Visit other Kitware open-source projects at<span class="Apple-converted-space"> </span><a href="http://www.kitware.com/opensource/opensource.html" target="_blank" class="">http://www.kitware.com/opensource/opensource.html</a><br class=""><br class="">Follow this link to subscribe/unsubscribe:<br class=""><a href="http://public.kitware.com/mailman/listinfo/cmake" target="_blank" class="">http://public.kitware.com/mailman/listinfo/cmake</a></div></blockquote></div><br class=""></div><br class="">--<br class=""><br class="">Powered by<span class="Apple-converted-space"> </span><a href="http://www.kitware.com/" rel="noreferrer" target="_blank" class="">www.kitware.com</a><br class=""><br class="">Please keep messages on-topic and check the CMake FAQ at:<span class="Apple-converted-space"> </span><a href="http://www.cmake.org/Wiki/CMake_FAQ" rel="noreferrer" target="_blank" class="">http://www.cmake.org/Wiki/CMake_FAQ</a><br class=""><br class="">Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br class=""><br class="">CMake Support:<span class="Apple-converted-space"> </span><a href="http://cmake.org/cmake/help/support.html" rel="noreferrer" target="_blank" class="">http://cmake.org/cmake/help/support.html</a><br class="">CMake Consulting:<span class="Apple-converted-space"> </span><a href="http://cmake.org/cmake/help/consulting.html" rel="noreferrer" target="_blank" class="">http://cmake.org/cmake/help/consulting.html</a><br class="">CMake Training Courses:<span class="Apple-converted-space"> </span><a href="http://cmake.org/cmake/help/training.html" rel="noreferrer" target="_blank" class="">http://cmake.org/cmake/help/training.html</a><br class=""><br class="">Visit other Kitware open-source projects at<span class="Apple-converted-space"> </span><a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank" class="">http://www.kitware.com/opensource/opensource.html</a><br class=""><br class="">Follow this link to subscribe/unsubscribe:<br class=""><a href="http://public.kitware.com/mailman/listinfo/cmake" rel="noreferrer" target="_blank" class="">http://public.kitware.com/mailman/listinfo/cmake</a></blockquote></div></div></blockquote></div><br class=""></body></html>