diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2022-12-08 21:13:47 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2022-12-12 18:28:02 +0300 |
commit | ab7dba520c8efd2cfbdd71dd91ae6b60923a12cd (patch) | |
tree | bb4cf6a252397c5aa1f0cf9ef7a3ab064b6079e6 /libbuild2/cc/types.cxx | |
parent | aeae50fe987b1787d1c1ae6f5c0bfb4f179205ef (diff) |
Adapt to dir_iterator API change
Diffstat (limited to 'libbuild2/cc/types.cxx')
-rw-r--r-- | libbuild2/cc/types.cxx | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/libbuild2/cc/types.cxx b/libbuild2/cc/types.cxx index 8ee4fa9..c6cfae9 100644 --- a/libbuild2/cc/types.cxx +++ b/libbuild2/cc/types.cxx @@ -6,6 +6,7 @@ #include <libbuild2/cc/utility.hxx> using namespace std; +using namespace butl; namespace build2 { @@ -123,6 +124,8 @@ namespace build2 size_t importable_headers:: insert_angle_pattern (const dir_paths& sys_hdr_dirs, const string& pat) { + tracer trace ("importable_headers::insert_angle_pattern"); + assert (pat.front () == '<' && pat.back () == '>' && path_pattern (pat)); // First see if it has already been inserted. @@ -172,7 +175,17 @@ namespace build2 try { - path_search (f, process, dir); + path_search ( + f, + process, + dir, + path_match_flags::follow_symlinks, + [&trace] (const dir_entry& de) + { + l5 ([&]{trace << "skipping inaccessible/dangling entry " + << de.base () / de.path ();}); + return true; + }); } catch (const system_error& e) { |