prefix_rules should append rather than overwrite the prefix

This commit is contained in:
Jérémie Dimino 2018-02-23 15:46:35 +07:00 committed by Rudi Grinberg
parent 3fd3d5b44c
commit e77bd30681
1 changed files with 5 additions and 0 deletions

View File

@ -1406,6 +1406,11 @@ let prefix_rules t prefix ~f =
Sexp.code_error "Build_system.prefix_rules' prefix contains targets"
["targets", Path.Set.sexp_of_t (Build_interpret.Target.paths targets)]
end;
let prefix =
match t.prefix with
| None -> prefix
| Some p -> Build.O.(>>>) p prefix
in
prefix_rules' t (Some prefix) ~f
let on_load_dir t ~dir ~f =