Skip to content

Commit

Permalink
Allow generating C_SOURCE as an extra output
Browse files Browse the repository at this point in the history
  • Loading branch information
alexreinking committed Aug 29, 2024
1 parent d72df59 commit 3417316
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion cmake/HalideGeneratorHelpers.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,11 @@ function(_Halide_library_from_generator TARGET)
endif ()

foreach (output IN LISTS ARG_EXTRA_OUTPUTS)
_Halide_add_output("${output}" "${TARGET}")
if (output STREQUAL "c_source" AND ARG_TYPE STREQUAL "c_source")
# Skip this as it was handled above
else ()
_Halide_add_output("${output}" "${TARGET}")
endif ()
endforeach ()

## Run the generator
Expand Down Expand Up @@ -440,6 +444,7 @@ function(add_halide_library TARGET)
ASSEMBLY
BITCODE
COMPILER_LOG
C_SOURCE
FEATURIZATION
FUNCTION_INFO_HEADER
HLPIPE
Expand Down

0 comments on commit 3417316

Please sign in to comment.