From 6bbdd5e594deb3a7143461fe657ad495e95bbafd Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Wed, 5 Jun 2019 20:20:29 +0300 Subject: Make preprocessing options order consistent across preprocessing and compilation compiler runs --- build2/cc/compile-rule.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'build2') diff --git a/build2/cc/compile-rule.cxx b/build2/cc/compile-rule.cxx index c85d939..bfbbc8a 100644 --- a/build2/cc/compile-rule.cxx +++ b/build2/cc/compile-rule.cxx @@ -2806,13 +2806,13 @@ namespace build2 if (reprocess) args.push_back ("-D__build2_preprocess"); + append_options (args, t, c_poptions); + append_options (args, t, x_poptions); + // Add *.export.poptions from prerequisite libraries. // append_lib_options (bs, args, a, t, li); - append_options (args, t, c_poptions); - append_options (args, t, x_poptions); - // Populate the src-out with the -I$out_base -I$src_base pairs. // { @@ -4053,11 +4053,11 @@ namespace build2 if (reprocess) args.push_back ("-D__build2_preprocess"); - append_lib_options (t.base_scope (), args, a, t, li); - append_options (args, t, c_poptions); append_options (args, t, x_poptions); + append_lib_options (t.base_scope (), args, a, t, li); + assert (sys_inc_dirs_extra <= sys_inc_dirs.size ()); append_option_values ( args, "-I", -- cgit v1.1