Skip to content

[Build] Set correct flatcc path for Windows #4993

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 11 additions & 4 deletions devtools/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -157,13 +157,20 @@ file(MAKE_DIRECTORY
${_program_schema__include_dir}/executorch/devtools/bundled_program
)


# Note that the flatcc project actually writes its outputs into the source
# tree instead of under the binary directory, and there's no way to change
# that behavior.
if(WIN32)
set(_flatcc_bin_path ${_flatcc_source_dir}/bin/${CMAKE_BUILD_TYPE}/flatcc)
else()
set(_flatcc_bin_path ${_flatcc_source_dir}/bin/flatcc)
endif()

add_custom_command(
OUTPUT ${_etdump_schema__outputs}
COMMAND
# Note that the flatcc project actually writes its outputs into the source
# tree instead of under the binary directory, and there's no way to change
# that behavior.
${_flatcc_source_dir}/bin/flatcc -cwr -o
${_flatcc_bin_path} -cwr -o
${_program_schema__include_dir}/executorch/devtools/etdump
${_etdump_schema__srcs}
COMMAND rm -f ${_etdump_schema_cleanup_paths}
Expand Down
Loading