mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
[qfcc] Actually skip compile for -E etc
The preprocess-only option wasn't being checked enough.
This commit is contained in:
parent
119001de6f
commit
99af93c6e6
1 changed files with 6 additions and 3 deletions
|
@ -394,7 +394,7 @@ compile_to_obj (const char *file, const char *obj, lang_t lang)
|
|||
}
|
||||
|
||||
*yyin = preprocess_file (file, 0);
|
||||
if (!*yyin)
|
||||
if (options.preprocess_only || !*yyin)
|
||||
return !options.preprocess_only;
|
||||
|
||||
InitData ();
|
||||
|
@ -568,7 +568,7 @@ separate_compile (void)
|
|||
}
|
||||
dstring_delete (output_file);
|
||||
dstring_delete (extension);
|
||||
if (!err && !options.compile) {
|
||||
if (!err && !options.compile && !options.preprocess_only) {
|
||||
InitData ();
|
||||
chain_initial_types ();
|
||||
linker_begin ();
|
||||
|
@ -659,7 +659,7 @@ compile_file (const char *filename)
|
|||
int (*yyparse) (void) = qc_yyparse;
|
||||
|
||||
*yyin = preprocess_file (filename, 0);
|
||||
if (!*yyin)
|
||||
if (options.preprocess_only || !*yyin)
|
||||
return !options.preprocess_only;
|
||||
|
||||
add_source_file (filename);
|
||||
|
@ -717,6 +717,9 @@ progs_src_compile (void)
|
|||
exit (1);
|
||||
}
|
||||
}
|
||||
if (options.preprocess_only) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
src = load_file (filename->str);
|
||||
if (!src) {
|
||||
|
|
Loading…
Reference in a new issue