Lines Matching refs:target
81 extern Doname doname_check(Name target, Boolean do_get, Boolean implicit, Boolean automatic);
82 extern Doname doname(Name target, Boolean do_get, Boolean implicit, Boolean automatic);
83 static Boolean check_dependencies(Doname *result, Property line, Boolean do_get, Name target, Name…
84 void dynamic_dependencies(Name target);
91 static void do_assign(Name line, Name target);
92 static void build_command_strings(Name target, Property line);
93 static Doname touch_command(Property line, Name target, Doname result);
95 static Doname sccs_get(Name target, Property *command);
97 static void add_pattern_conditionals(Name target);
98 extern void set_locals(Name target, Property old_locals);
99 extern void reset_locals(Name target, Property old_locals, Property conditional, int index);
100 extern Boolean check_auto_dependencies(Name target, int auto_count, Name *automatics);
130 doname_check(Name target, Boolean do_get, Boolean implicit, Boolean automatic) in doname_check() argument
137 switch (doname(target, do_get, implicit, automatic)) { in doname_check()
150 target->string_mb); in doname_check()
178 target->string_mb); in doname_check()
184 target->string_mb); in doname_check()
192 enter_explicit_rule_from_dynamic_rule(Name target, Name source) in enter_explicit_rule_from_dynamic_rule() argument
198 line = maybe_append_prop(target, line_prop); in enter_explicit_rule_from_dynamic_rule()
200 line->body.line.target = target; in enter_explicit_rule_from_dynamic_rule()
208 line->body.line.less = target; in enter_explicit_rule_from_dynamic_rule()
216 find_dyntarget(Name target) in find_dyntarget() argument
224 Wstring wcb(target); in find_dyntarget()
237 enter_explicit_rule_from_dynamic_rule(target, p->name); in find_dyntarget()
238 return(target); in find_dyntarget()
252 enter_explicit_rule_from_dynamic_rule(target, p->name); in find_dyntarget()
253 return(target); in find_dyntarget()
291 doname(Name target, Boolean do_get, Boolean implicit, Boolean automatic) in doname() argument
301 Name true_target = target; in doname()
312 if (target->state == build_running) { in doname()
315 line = get_prop(target->prop, line_prop); in doname()
326 target->state = build_running; in doname()
327 add_pending(target, in doname()
340 if (target->has_target_prop) { in doname()
341 true_target = get_prop(target->prop, in doname()
342 target_prop)->body.target.target; in doname()
359 if (target->state == build_ok) { in doname()
360 if((!keep_state || (!target->depends_on_conditional && !assign_done))) { in doname()
366 if (target->state == build_subtree) { in doname()
368 target->state = build_dont_know; in doname()
370 if (!target->checking_subtree) { in doname()
377 } else if (target->state == build_pending) { in doname()
378 target->state = build_dont_know; in doname()
450 target->string_mb); in doname()
454 if (target->state == build_in_progress) { in doname()
456 target->string_mb); in doname()
459 target->state = build_in_progress; in doname()
462 if (!target->added_pattern_conditionals) { in doname()
463 add_pattern_conditionals(target); in doname()
464 target->added_pattern_conditionals = true; in doname()
466 if (target->conditional_cnt > 0) { in doname()
467 old_locals = (Property) alloca(target->conditional_cnt * in doname()
469 set_locals(target, old_locals); in doname()
478 if (!target->has_depe_list_expanded) in doname()
480 dynamic_dependencies(target); in doname()
487 if ((line = get_prop(target->prop, line_prop)) != NULL) { in doname()
491 target, in doname()
521 if (target->colon_splits == 0 && !rechecking_target) { in doname()
526 target, in doname()
533 target->state = build_running; in doname()
534 add_pending(target, in doname()
539 if (target->conditional_cnt > 0) { in doname()
540 reset_locals(target, in doname()
542 get_prop(target->prop, in doname()
556 if (target->is_member && in doname()
557 ((member = get_prop(target->prop, member_prop)) != in doname()
559 switch (find_ar_suffix_rule(target, in doname()
568 target->state = build_running; in doname()
569 add_pending(target, in doname()
574 if (target->conditional_cnt > 0) { in doname()
575 reset_locals(target, in doname()
577 get_prop(target->prop, in doname()
587 maybe_append_prop(target, in doname()
595 switch (find_double_suffix_rule(target, in doname()
602 target->state = build_running; in doname()
603 add_pending(target, in doname()
608 if (target->conditional_cnt > 0) { in doname()
609 reset_locals(target, in doname()
611 get_prop(target-> in doname()
639 ((line->body.line.target != NULL) && in doname()
640 !line->body.line.target->has_regular_dependency))) { in doname()
641 switch (find_suffix_rule(target, in doname()
642 target, in doname()
650 target->state = build_running; in doname()
651 add_pending(target, in doname()
656 if (target->conditional_cnt > 0) { in doname()
657 reset_locals(target, in doname()
659 get_prop(target->prop, in doname()
670 result = sccs_get(target, &command); in doname()
680 line = maybe_append_prop(target, line_prop); in doname()
701 line->body.line.target = true_target; in doname()
709 if (!target->is_double_colon_parent) { in doname()
719 silent = (Boolean) target->silent_mode; in doname()
723 ignore_errors = (Boolean) target->ignore_error_mode; in doname()
738 add_running(target, in doname()
746 target->state = build_running; in doname()
747 if ((line = get_prop(target->prop, in doname()
754 if (target->conditional_cnt > 0) { in doname()
755 reset_locals(target, in doname()
757 get_prop(target->prop, in doname()
763 add_serial(target, in doname()
767 target->state = build_running; in doname()
768 line = get_prop(target->prop, line_prop); in doname()
775 if (target->conditional_cnt > 0) { in doname()
776 reset_locals(target, in doname()
778 get_prop(target->prop, in doname()
796 if (target->colons != no_colon) { in doname()
807 Name dtarg = find_dyntarget(target); in doname()
809 if (!target->has_depe_list_expanded) { in doname()
810 dynamic_dependencies(target); in doname()
812 if ((line = get_prop(target->prop, line_prop)) != NULL) { in doname()
816 target, in doname()
841 (void) exists(target); in doname()
842 if ((target->stat.time != file_doesnt_exist) && in doname()
853 if ((line = get_prop(target->prop, line_prop)) != NULL) { in doname()
859 target->state = result; in doname()
861 if (target->conditional_cnt > 0) { in doname()
862 reset_locals(target, in doname()
864 get_prop(target->prop, conditional_prop), in doname()
868 if (target->is_member) { in doname()
872 if ((target->stat.time != file_max_time) && in doname()
873 ((member = get_prop(target->prop, member_prop)) != NULL) && in doname()
875 target->stat.time = in doname()
883 if ((result == build_ok) && check_auto_dependencies(target, in doname()
936 check_dependencies(Doname *result, Property line, Boolean do_get, Name target, Name true_target, Bo… in check_dependencies() argument
960 (rechecking_target || target->rechecking_target)) { in check_dependencies()
1047 target->depends_on_conditional = true; in check_dependencies()
1050 target->stat.time = in check_dependencies()
1159 if (target->conditional_cnt > 0) { in check_dependencies()
1160 reset_locals(target, in check_dependencies()
1162 get_prop(target->prop, in check_dependencies()
1168 target->state = build_running; in check_dependencies()
1169 add_pending(target, in check_dependencies()
1174 if (target->conditional_cnt > 0) { in check_dependencies()
1175 reset_locals(target, in check_dependencies()
1177 get_prop(target->prop, in check_dependencies()
1188 if (target->is_double_colon_parent) { in check_dependencies()
1196 target->stat.time = in check_dependencies()
1198 target->stat.time); in check_dependencies()
1213 target->string_mb); in check_dependencies()
1231 line->body.line.target = true_target; in check_dependencies()
1250 ((member = get_prop(target->prop, member_prop)) != in check_dependencies()
1318 dynamic_dependencies(Name target) in dynamic_dependencies() argument
1336 Name true_target = target; in dynamic_dependencies()
1339 if ((line = get_prop(target->prop, line_prop)) == NULL) { in dynamic_dependencies()
1343 if (target->has_target_prop) { in dynamic_dependencies()
1344 true_target = get_prop(target->prop, in dynamic_dependencies()
1345 target_prop)->body.target.target; in dynamic_dependencies()
1354 target->has_depe_list_expanded = true; in dynamic_dependencies()
1581 Name target = line->body.line.target; in run_command() local
1585 if (!line->body.line.is_out_of_date && target->rechecking_target) { in run_command()
1586 target->rechecking_target = false; in run_command()
1597 build_command_strings(target, line); in run_command()
1622 (target->stat.time != file_doesnt_exist) && in run_command()
1623 ((target->stat.mode & 0222) != 0)) { in run_command()
1625 target->string_mb); in run_command()
1626 target->has_complained = remember_only = true; in run_command()
1654 int len = 2*MAXPATHLEN + strlen(target->string_mb) + 2; in run_command()
1663 MBSTOWCS(to, target->string_mb); in run_command()
1676 current_target = target; in run_command()
1685 result = touch_command(line, target, result); in run_command()
1695 if (!parallel_ok(target, true)) { in run_command()
1705 result = execute_parallel(line, true, target->localhost); in run_command()
1722 result = execute_parallel(line, true, target->localhost); in run_command()
1726 target->parallel = false; in run_command()
1734 result = execute_parallel(line, true, target->localhost); in run_command()
1777 Name target = line->body.line.target; in execute_serial() local
1779 target->has_recursive_dependency = false; in execute_serial()
1815 do_assign(rule->command_line, target); in execute_serial()
1827 target); in execute_serial()
1841 target->string_mb); in execute_serial()
2083 do_assign(Name line, Name target) in do_assign() argument
2120 target->string_mb); in do_assign()
2166 build_command_strings(Name target, Property line) in build_command_strings() argument
2199 if (target->is_member && in build_command_strings()
2200 ((member = get_prop(target->prop, member_prop)) != NULL)) { in build_command_strings()
2201 target = member->body.member.library; in build_command_strings()
2206 if (target->has_target_prop) { in build_command_strings()
2207 target = get_prop(target->prop, target_prop)-> in build_command_strings()
2208 body.target.target; in build_command_strings()
2211 tmp_name = target; in build_command_strings()
2415 target->string_mb, in build_command_strings()
2426 target->string_mb, in build_command_strings()
2451 target->string_mb); in build_command_strings()
2466 target->string_mb); in build_command_strings()
2486 target->conditional_macro_list = cond_macro_list; in build_command_strings()
2488 target->depends_on_conditional = true; in build_command_strings()
2511 touch_command(Property line, Name target, Doname result) in touch_command() argument
2520 for (name = target, target_group = NULL; name != NULL;) { in touch_command()
2594 Name target; in update_target() local
2612 target = line->body.line.target; in update_target()
2617 (target->is_member && in update_target()
2623 target->stat.time = file_max_time; in update_target()
2633 old_stat_time = target->stat.time; in update_target()
2634 target->stat.time = file_no_time; in update_target()
2635 (void) exists(target); in update_target()
2636 if ((target->is_member) && in update_target()
2637 (target->stat.time == old_stat_time)) { in update_target()
2638 member = get_prop(target->prop, member_prop); in update_target()
2640 target->stat.time = member->body.member.library->stat.time; in update_target()
2641 target->stat.time.tv_sec++; in update_target()
2650 target_group->name->stat.time = target->stat.time; in update_target()
2655 line2->body.line.target = target_group->name; in update_target()
2658 target->has_built = true; in update_target()
2680 sccs_get(Name target, Property *command) in sccs_get() argument
2692 while (target->stat.is_sym_link) { in sccs_get()
2695 target->string_mb); in sccs_get()
2698 result = readlink_vroot(target->string_mb, in sccs_get()
2705 target->string_mb, errmsg(errno)); in sccs_get()
2711 Wstring wcb(target); in sccs_get()
2718 target = normalize_name(string.buffer.start, string.text.p - string.buffer.start); in sccs_get()
2719 (void) exists(target); in sccs_get()
2729 if (target->stat.has_sccs == DONT_KNOW_SCCS) { in sccs_get()
2730 read_directory_of_file(target); in sccs_get()
2732 switch (target->stat.has_sccs) { in sccs_get()
2735 target->stat.has_sccs = NO_SCCS; in sccs_get()
2742 if (target->stat.time > file_doesnt_exist) { in sccs_get()
2752 sccs_time = exists(get_prop(target->prop, in sccs_get()
2757 if ((!target->has_complained && in sccs_get()
2768 line = maybe_append_prop(target, line_prop); in sccs_get()
2770 if (sccs_time > target->stat.time) { in sccs_get()
2780 target->string_mb); in sccs_get()
2786 if((target->prop) && in sccs_get()
2787 (target->prop->body.sccs.file) && in sccs_get()
2788 (target->prop->body.sccs.file->string_mb)) { in sccs_get()
2789 if((strlen(target->prop->body.sccs.file->string_mb) == in sccs_get()
2790 strlen(target->string_mb) + 2) && in sccs_get()
2791 (target->prop->body.sccs.file->string_mb[0] == 's') && in sccs_get()
2792 (target->prop->body.sccs.file->string_mb[1] == '.')) { in sccs_get()
2798 line->body.line.target = target; in sccs_get()
2887 add_pattern_conditionals(Name target) in add_pattern_conditionals() argument
2897 Wstring wcb(target); in add_pattern_conditionals()
2903 wcb1.init(conditional->body.conditional.target); in add_pattern_conditionals()
2916 for (previous = &target->prop; in add_pattern_conditionals()
2926 new_prop = append_prop(target, conditional_prop); in add_pattern_conditionals()
2933 target->conditional_cnt++; in add_pattern_conditionals()
2954 set_locals(Name target, Property old_locals) in set_locals() argument
2962 if (target->dont_activate_cond_values) { in set_locals()
2969 for (conditional = get_prop(target->prop, conditional_prop), i = 0; in set_locals()
2995 cond_chain->name = target; in set_locals()
3016 reset_locals(Name target, Property old_locals, Property conditional, int index) in reset_locals() argument
3021 if (target->dont_activate_cond_values) { in reset_locals()
3029 reset_locals(target, old_locals, this_conditional, index+1); in reset_locals()
3033 conditional_targets->name != target) { in reset_locals()
3083 check_auto_dependencies(Name target, int auto_count, Name *automatics) in check_auto_dependencies() argument
3091 if ((line = get_prop(target->prop, line_prop)) == NULL) { in check_auto_dependencies()
3139 target_can_be_built(Name target) { in target_can_be_built() argument
3141 Name true_target = target; in target_can_be_built()
3144 if (target == wait_name) { in target_can_be_built()
3151 if (target->has_target_prop) { in target_can_be_built()
3152 true_target = get_prop(target->prop, in target_can_be_built()
3153 target_prop)->body.target.target; in target_can_be_built()
3174 result = find_percent_rule(target, NULL, false); in target_can_be_built()
3179 if (target->is_member) { in target_can_be_built()
3180 Property member = get_prop(target->prop, member_prop); in target_can_be_built()
3182 result = find_ar_suffix_rule(target, member->body.member.member, NULL, false); in target_can_be_built()
3184 result = find_double_suffix_rule(target, NULL, false); in target_can_be_built()
3187 result = find_double_suffix_rule(target, NULL, false); in target_can_be_built()
3193 result = find_suffix_rule(target, target, empty_name, NULL, false); in target_can_be_built()
3198 result = sccs_get(target, NULL); in target_can_be_built()
3203 Name dtarg = find_dyntarget(target); in target_can_be_built()
3211 if (target->colons != no_colon) { in target_can_be_built()