I want to get file path in clang and I use getDir() in FileEntry. The result is I get relative path of that file. How can I get the file’s alsolute path?
Thanks in advance
I want to get file path in clang and I use getDir() in FileEntry. The result is I get relative path of that file. How can I get the file’s alsolute path?
Thanks in advance
If your system supports it, the BSD "realpath" function will do it.
-Chris
I want to get file path in clang and I use getDir() in FileEntry. The result is I get relative path of that file. How can I get the file's alsolute path?
If your system supports it, the BSD "realpath" function will do it.
Argh, never use realpath()!
You can just use the sys::Path::makeAbsolute function, we don't handle
the "working directory" of the compiler in any special fashion (yet).
- Daniel