Closed FrankXie05 closed 1 year ago
This question drags in a lot of vcpkg particularities. More general (https://github.com/microsoft/vcpkg/pull/30980#discussion_r1172147992), please solve this problem and inconsistency:
Target libconfig++
is in namespace and directory libconfig
but in config libconfig++
.
This makes the target unreachable.
find_package(libconfig++)
doesn't work.find_package(libconfig)
doesn't provide the target.Consistent patterns would be:
libconfig++
is in namespace, config and directory libconfig
.libconfig++
is in namespace, config and directory libconfig++
.I would recommend the first alternative, in particular because they are connected.
Hey ! Is there any new about this issue ? I really need to use libonfig++ under Cmake with vcpkg.
I'm not an advanced programmer, but it seams that all we need need is to rename the namespace.
@mllusar You can use my PR temporarily https://github.com/microsoft/vcpkg/pull/30980
- Target
libconfig++
is in namespace, config and directorylibconfig
.
Implemented in #234.
Hi, I'm one of the maintainers of vcpkg, and we recently received a question about libconfg using cmake. Issue: There seems to be this problem with the exported cmake usage after we installed libconfig, it fails to link against
libconfig++
. Run command./vcpkg install libconfig:x64-windows --head
and output:For this reason, I made a patch to separate
libconfig
andlibconfig++
.However, from the code structure,
libconfig
does not seem to be separated, but is linked tolibconfig++
. BUt, it was broken. https://github.com/hyperrealm/libconfig/blob/4f13b7f5152427b5e511a09617ca2d9ff63f7800/lib/CMakeLists.txt#L144 https://github.com/hyperrealm/libconfig/blob/4f13b7f5152427b5e511a09617ca2d9ff63f7800/lib/CMakeLists.txt#L152Reproduce steps:
CMakeLists.txt
Error:
Related vcpkg issue and PR: https://github.com/microsoft/vcpkg/issues/30906 https://github.com/microsoft/vcpkg/pull/30980
@hyperrealm