Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- programs/vkd3d-compiler/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/programs/vkd3d-compiler/main.c b/programs/vkd3d-compiler/main.c index cec2ebb1..b79396e9 100644 --- a/programs/vkd3d-compiler/main.c +++ b/programs/vkd3d-compiler/main.c @@ -483,7 +483,7 @@ static bool parse_command_line(int argc, char **argv, struct options *options) if (options->print_target_types) return true;
- if (!validate_target_type(options->source_type, options->target_type)) + if (!options->preprocess_only && !validate_target_type(options->source_type, options->target_type)) { fprintf(stderr, "Target type '%s' is invalid for source type '%s'.\n", get_target_type_info(options->target_type)->name,
Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- programs/vkd3d-compiler/main.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/programs/vkd3d-compiler/main.c b/programs/vkd3d-compiler/main.c index b79396e9..91c8e04f 100644 --- a/programs/vkd3d-compiler/main.c +++ b/programs/vkd3d-compiler/main.c @@ -639,12 +639,21 @@ int main(int argc, char **argv) if (!(output = open_output(options.output_filename, &close_output))) goto done;
- if (!options.output_filename && get_target_type_info(options.target_type)->is_binary - && isatty(fileno(output))) + if (!options.output_filename && isatty(fileno(output))) { - fprintf(stderr, "Output is a tty and output format is binary, exiting.\n" - "If this is really what you intended, specify the output explicitly.\n"); - goto done; + bool is_binary; + + if (options.preprocess_only) + is_binary = get_source_type_info(options.source_type)->is_binary; + else + is_binary = get_target_type_info(options.target_type)->is_binary; + + if (is_binary) + { + fprintf(stderr, "Output is a tty and output format is binary, exiting.\n" + "If this is really what you intended, specify the output explicitly.\n"); + goto done; + } }
if (!options.explicit_colour && has_colour(output))
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=82789
Your paranoid android.
=== debiant (build log) ===
Task: Patch failed to apply
=== debiant (build log) ===
Task: Patch failed to apply
Signed-off-by: Henri Verbeet hverbeet@codeweavers.com
Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- programs/vkd3d-compiler/main.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/programs/vkd3d-compiler/main.c b/programs/vkd3d-compiler/main.c index 91c8e04f..f1e597a0 100644 --- a/programs/vkd3d-compiler/main.c +++ b/programs/vkd3d-compiler/main.c @@ -397,8 +397,8 @@ static bool parse_command_line(int argc, char **argv, struct options *options) };
memset(options, 0, sizeof(*options)); - options->source_type = VKD3D_SHADER_SOURCE_DXBC_TPF; - options->target_type = VKD3D_SHADER_TARGET_SPIRV_BINARY; + options->source_type = VKD3D_SHADER_SOURCE_NONE; + options->target_type = VKD3D_SHADER_TARGET_NONE; options->formatting = VKD3D_SHADER_COMPILE_OPTION_FORMATTING_INDENT | VKD3D_SHADER_COMPILE_OPTION_FORMATTING_HEADER;
@@ -483,6 +483,11 @@ static bool parse_command_line(int argc, char **argv, struct options *options) if (options->print_target_types) return true;
+ if (options->source_type == VKD3D_SHADER_SOURCE_NONE) + options->source_type = options->preprocess_only ? VKD3D_SHADER_SOURCE_HLSL : VKD3D_SHADER_SOURCE_DXBC_TPF; + if (options->target_type == VKD3D_SHADER_TARGET_NONE && !options->preprocess_only) + options->target_type = VKD3D_SHADER_TARGET_SPIRV_BINARY; + if (!options->preprocess_only && !validate_target_type(options->source_type, options->target_type)) { fprintf(stderr, "Target type '%s' is invalid for source type '%s'.\n",
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=82790
Your paranoid android.
=== debiant (build log) ===
Task: Patch failed to apply
=== debiant (build log) ===
Task: Patch failed to apply
Signed-off-by: Henri Verbeet hverbeet@codeweavers.com
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=82788
Your paranoid android.
=== debiant (build log) ===
Task: Patch failed to apply
=== debiant (build log) ===
Task: Patch failed to apply