Not installable when used as subdirectory #91
Labels
available on master
Fix is done on master branch, issue closed on next release
bug
Something isn't working
Milestone
Describe the bug
When I use the library as a cmake subdirectory, the targets and files do not get installed even if I need them to be installed. The following line cannot be bypassed and
GHC_FILESYSTEM_WITH_INSTALL
cannot be setfilesystem/CMakeLists.txt
Line 17 in de57485
This was introduced on jpd002/Play-#825 because the final application did not need the headers (i.e. consumption is
PRIVATE
), but that's not the case in general (i.e. consumption isPUBLIC
). Development libraries, may need to provide these headers as well.To Reproduce
Here is the situation: I have a target
target_a
that depends ontarget_b
(i.eghc_filesystem
).The problem comes when I want to install and export my target
target_a
.If
target_b
is not installed as well, then CMake complains that it will not be able to find such target again when reading the configure script for my project. Which is true, after all,target_b
is not installed. In such case, thetarget_b
happens to be relatively useless (in the Modern CMake usage) and one has to manually add complier flags, include directories, etc.Expected behavior
The
GHC_FILESYSTEM_WITH_INSTALL
option can be set when using the library as a subdirectory.The text was updated successfully, but these errors were encountered: