PNGΒΆ

hunter_add_package(PNG)
find_package(PNG CONFIG REQUIRED)

add_executable(boo main.cpp)
target_link_libraries(boo PRIVATE PNG::png)

For compatibility with FindPNG module, the ALIAS target PNG::PNG can be used too:

add_executable(baz main.cpp)
target_link_libraries(baz PRIVATE PNG::PNG)