error.detect.hunter.root¶
What happens¶
CMake fatal error with message:
[hunter ** FATAL ERROR **] Can't detect HUNTER_ROOT
Explanation¶
Hunter need to have directory where all the packages will be installed. Next locations tried (by priority):
- CMake variable
HUNTER_ROOT(high priority; not recommended, since you need to set it for every build) - Environment variable
HUNTER_ROOT(recommended, full control over directory location shared between all projects) - Environment variable
HOME(low priority) - Environment variable
SYSTEMDRIVE(Windows only) - Environment variable
USERPROFILE(Windows only)
- CMake variable
What to do¶
- Fix your environment.
HOMEusually defined on Unix-like platforms andSYSTEMDRIVE/USERPROFILEon Windows - Set
HUNTER_ROOTenvironment variable (restart all CMake GUI’s or terminals to apply changes)