-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot find HanaConfig.cmake #39
Comments
To make it work I used your script in the dependencies folder ! |
Ahhh. Actually, I think this is a bug with the Boost distribution. When you install Boost, it should install a |
Make sure you're not using both that script AND a global installation of Boost, since that could cause problems. |
For people experiencing the same problem and want to use a global installation of Boost, I've used: find_package(Hana QUIET)
if (Hana_FOUND)
target_link_libraries(dyno INTERFACE hana)
else()
find_package(Boost 1.61)
if (Boost_FOUND)
target_link_libraries(dyno INTERFACE Boost::boost)
else()
message(SEND_ERROR "hana not found: either install stand-alone or use Boost>=1.61")
endif()
endif() Do the same for CallableTraits as well (but change the version to 1.64). Also we need to change cmake/dyno-config.cmake file as well. include(CMakeFindDependencyMacro)
find_package(Hana QUIET)
if (NOT Hana_FOUND)
find_package(Boost 1.61 REQUIRED)
endif()
find_package(CallableTraits QUIET)
if (NOT CallableTraits_FOUND)
find_package(Boost 1.64 REQUIRED)
endif()
# Below is the same
if(NOT TARGET Dyno::dyno)
include("${CMAKE_CURRENT_LIST_DIR}/dyno-targets.cmake")
endif() I am not sure whether this should be reported to Boost or packagers of my distribution but this is a workaround. I can send a PR but this feels like dirty hack. |
Hello,
I tried to use your library with my project but I have this error with CMake :
I installed Boost 1.65.1 with Homebrew on macOS High Sierra, but it doesn't seem to have this file configured while I can add other Boost librairies in my CMake file.
The text was updated successfully, but these errors were encountered: