diff --git a/frontends/common/parser_options.cpp b/frontends/common/parser_options.cpp index 7ed8272e81..67e241319a 100644 --- a/frontends/common/parser_options.cpp +++ b/frontends/common/parser_options.cpp @@ -395,10 +395,13 @@ bool ParserOptions::searchForIncludePath(const char *&includePathOut, } std::vector *ParserOptions::process(int argc, char *const argv[]) { - searchForIncludePath(p4includePath, {"p4include"_cs, "../p4include"_cs, "../../p4include"_cs}, + searchForIncludePath(p4includePath, + {"p4include"_cs, "../p4include"_cs, "../../p4include"_cs, + "../share/p4c/p4include"_cs}, exename(argv[0])); searchForIncludePath(p4_14includePath, - {"p4_14include"_cs, "../p4_14include"_cs, "../../p4_14include"_cs}, + {"p4_14include"_cs, "../p4_14include"_cs, "../../p4_14include"_cs, + "../share/p4c/p4_14include"_cs}, exename(argv[0])); auto remainingOptions = Util::Options::process(argc, argv);