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
Hii, I'm a new learner to C++ and I'm struggling with linking proj lib to cmake.
I used : sudo apt-get install libproj-dev to download proj, and I tried to link to proj as https://proj.org/en/9.4/development/cmake.html suggested:
`cmake_minimum_required(VERSION 3.28)
project(transform_crs)
And it gives error:` Could not find a package configuration file provided by "PROJ" with any of
the following names:
PROJConfig.cmake
proj-config.cmake
Add the installation prefix of "PROJ" to CMAKE_PREFIX_PATH or set
"PROJ_DIR" to a directory containing one of the above files. If "PROJ"
provides a separate development package or SDK, be sure it has been
installed.`
I wonder what's the correct way to link PROJ in cmakelist then? Thank you so much for your time and help and sry this is a very basic problem. ^O^, there's not much info online about this, I'd be really appreciated you can help me with it.
The text was updated successfully, but these errors were encountered:
Hii, I'm a new learner to C++ and I'm struggling with linking proj lib to cmake.
I used : sudo apt-get install libproj-dev to download proj, and I tried to link to proj as https://proj.org/en/9.4/development/cmake.html suggested:
`cmake_minimum_required(VERSION 3.28)
project(transform_crs)
set(CMAKE_CXX_STANDARD 17)
find_package(PROJ REQUIRED CONFIG)
add_executable(transform_crs main.cpp)
target_link_libraries(transform_crs PRIVATE PROJ::proj)`
And it gives error:` Could not find a package configuration file provided by "PROJ" with any of
the following names:
Add the installation prefix of "PROJ" to CMAKE_PREFIX_PATH or set
"PROJ_DIR" to a directory containing one of the above files. If "PROJ"
provides a separate development package or SDK, be sure it has been
installed.`
I wonder what's the correct way to link PROJ in cmakelist then? Thank you so much for your time and help and sry this is a very basic problem. ^O^, there's not much info online about this, I'd be really appreciated you can help me with it.
The text was updated successfully, but these errors were encountered: