Reputation: 335
I am using CLion 2022.3.2 and remote deployment to read code in Folly. Folly project relies on some external headers, e.g., glog
, which are installed in the system folders by dnf
command, e.g., /usr/include
. I am using CMake (3.20.2) to build the project. CMake can successfully build the project and all executable targets work well. However, when I open some Folly cpp files that includes system headers, e.g., #include <glog/logging.h>
, #include <random>
, Clion complains "'glog/logging.h' files not find.".
I have try to find some solutions. The common advice is to run Tools -> Resync with Remote Hosts. When I run this command, Clion complains "Downloaded failed /usr/include", "Downloaded failed /usr/local/include", and etc. I cannot find extra debug messages to resolve the fail downloading. Thank you for give me some advice.
EDIT: I look into the log of CLion, and find the following warning:
WARN - #c.i.e.p.OSProcessHandler - Process has been already terminated: /usr/bin/rsync -zar -v -e "ssh -p 22 " --log-file=/private/var/folders/8_/s7_qf53d5nb5szqvs136g7vm0000gp/T/rsync_download1.log --files-from=/private/var/folders/8_/s7_qf53d5nb5szqvs136g7vm0000gp/T/fileList1.txt myname@myip:/usr/local/lib/clang/15.0.7/include/ include
Upvotes: 0
Views: 451
Reputation: 335
I think my problem is similar to https://stackoverflow.com/a/67802186/6778553.
The real reason is that these files exist as symbolic links on my Ubuntu. During synchronization, Clion will first use tar to package the files, and then download them locally. By default, the symbolic links will not be parsed to the corresponding files.
I have fixed the problem by following the suggestion in the previous answer: enable clion.remote.tar.dereference in Registry of CLion.
Upvotes: 0