Can I get the system home directory in cmake on li

2019-04-04 01:34发布

问题:

Is there a variable related to the home_dir(like /home/user) of linux system in cmake. Or some other easy ways to get it

回答1:

Home directory is referred to by the HOME environment variable, so you can access it in CMake script by:

$ENV{HOME}


标签: cmake