diff options
Diffstat (limited to 'build/target.cxx')
-rw-r--r-- | build/target.cxx | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/build/target.cxx b/build/target.cxx index 87194fb..3b030ee 100644 --- a/build/target.cxx +++ b/build/target.cxx @@ -285,7 +285,15 @@ namespace build n += *ext; } - path (dir / path_type (move (n))); + path_type p (dir / path_type (move (n))); + const path_type& ep (path ()); + + if (ep.empty ()) + path (p); + else if (p != ep) + fail << "path mismatch for target " << *this << + info << "assigned '" << ep << "'" << + info << "derived '" << p << "'"; } // file_target |