From fcb936b4ea13841e8c4f87648182b20a194413f2 Mon Sep 17 00:00:00 2001 From: Josh Rahm Date: Wed, 27 Nov 2024 12:51:24 -0700 Subject: Some SPI is working, a bit. Still no clock, but I'm about to give up on that. --- cmake/fiddle.cmake | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'cmake/fiddle.cmake') diff --git a/cmake/fiddle.cmake b/cmake/fiddle.cmake index 6b151a2..6830ce5 100644 --- a/cmake/fiddle.cmake +++ b/cmake/fiddle.cmake @@ -1,3 +1,11 @@ +find_program(FIDDLEC "fiddlec") + +if (FIDDLEC) + message (STATUS "Found fiddlec at ${FIDDLEC}") +else() + message (FATAL_ERROR "Could not find fiddlec. Please download and build it at git@git.josher.dev:fiddle.git") +endif() + function(add_fiddle_source header_out fdl_file) get_filename_component(dir_path ${fdl_file} DIRECTORY) get_filename_component(file_name_without_extension ${fdl_file} NAME_WE) @@ -13,7 +21,7 @@ function(add_fiddle_source header_out fdl_file) DEPENDS ${fdl_file} COMMENT "Fiddle compile ${fdl_file} -> ${output_header}" COMMAND ${CMAKE_COMMAND} -E make_directory "${output_dir}" - COMMAND fiddlec -Lc -h ${output_header} -I ${CMAKE_SOURCE_DIR}/fdl/ --intf-dir ${CMAKE_BINARY_DIR}/fdli/ ${CMAKE_SOURCE_DIR}/${fdl_file} + COMMAND ${FIDDLEC} -Lc -h ${output_header} -I ${CMAKE_SOURCE_DIR}/fdl/ --intf-dir ${CMAKE_BINARY_DIR}/fdli/ ${CMAKE_SOURCE_DIR}/${fdl_file} ) # Make the output header file available as a source file for the target -- cgit