================ @@ -424,8 +432,19 @@ std::string Linux::computeSysRoot() const { const StringRef InstallDir = GCCInstallation.getInstallPath(); const StringRef TripleStr = GCCInstallation.getTriple().str(); const Multilib &Multilib = GCCInstallation.getMultilib(); + std::string Path; + if (getTriple().isRISCV()) { + Path = + (InstallDir + "/../../../../sysroot" + Multilib.osSuffix() + "/../..") + .str(); + + if (getVFS().exists(Path)) + return Path; + + return std::string(); + } ---------------- ilovepi wrote:
I see tests for target features, but I think you should have tests for these paths too. https://github.com/llvm/llvm-project/pull/134065 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits