You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CMake Error at /opt/cmake/share/cmake-3.28/Modules/FindFreetype.cmake:108 (get_property):
get_property could not find TARGET freetype. Perhaps it has not yet been
created.
Call Stack (most recent call first):
CMakeLists.txt:12 (find_package)
The freetype library seems to provide both targets (see here and here)
while the hunter package seems to only provides freetype::freetype and Freetype::Freetype (ccp-pm/freetype) and not the freetype target.
My CMake knowledge is quite limited so I'm uncertain what the correct solution to this issue is. That is why I seek your help to find an appropriate soluion.
From what I can tell with version 2.10.4, same as hunter, the freetype library did use the freetype target [0] and only later added the Freetype::Freetype alias.
Hi,
starting with CMake 3.28.0 the usage of freetype config was added in FindFreetype.cmake which reads the config of the hunter package.
After that FindFreetype.cmake tries to read some properties of the freetype target
And this results in an error 🤕
The freetype library seems to provide both targets (see here and here)
while the hunter package seems to only provides
freetype::freetype and Freetype::Freetype
(ccp-pm/freetype) and not thefreetype
target.I also provided a small project that demonstrates the issue.
My CMake knowledge is quite limited so I'm uncertain what the correct solution to this issue is. That is why I seek your help to find an appropriate soluion.
thx 😺
https://github.com/Kitware/CMake/blob/v3.28.1/Modules/FindFreetype.cmake#L100
https://github.com/Kitware/CMake/blob/v3.28.1/Modules/FindFreetype.cmake#L108
https://gitlab.freedesktop.org/freetype/freetype/-/issues/1165
https://gitlab.freedesktop.org/freetype/freetype/-/merge_requests/178
https://github.com/cpp-pm/freetype/blob/hunter-2.10.4/cmake/template/Config.cmake.in
https://github.com/zerotacg/hunter-freetype-issue/tree/main
https://github.com/zerotacg/hunter-freetype-issue/actions/runs/7309580812/job/19917318519#step:3:1177
The text was updated successfully, but these errors were encountered: