yubico-piv-tool provides CMake targets:

    find_package(unofficial-libykpiv CONFIG REQUIRED)
    target_link_libraries(main PRIVATE unofficial::libykpiv::ykpiv)

yubico-piv-tool provides pkg-config modules:

    # Yubico PIV C Library
    ykpiv
