[clang] Add support for sysroot-relative system header search paths (PR #82084)

Jan Svoboda via cfe-commits cfe-commits at lists.llvm.org
Sat Oct 11 08:52:08 PDT 2025


================
@@ -3191,6 +3191,22 @@ static bool ParseHeaderSearchArgs(HeaderSearchOptions &Opts, ArgList &Args,
   bool IsIndexHeaderMap = false;
   bool IsSysrootSpecified =
       Args.hasArg(OPT__sysroot_EQ) || Args.hasArg(OPT_isysroot);
+
+  // Expand a leading `=` to the sysroot if one was passed (and it's not a
+  // framework flag).
+  auto PrefixHeaderPath = [IsSysrootSpecified,
----------------
jansvoboda11 wrote:

I see, thanks for explaining. Do you mind creating a PR? That seems like a reasonable path forward.

https://github.com/llvm/llvm-project/pull/82084


More information about the cfe-commits mailing list