File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -677,6 +677,10 @@ function(__arduino_resolve_preprocessed_filepath SOURCE_DIRPATH FILENAME OUTPUT_
677677 BASE_DIRECTORY "${SOURCE_DIRPATH} "
678678 OUTPUT_VARIABLE _relative_filepath)
679679
680+ if (_relative_filepath MATCHES "${__ARDUINO_SKETCH_SUFFIX} " )
681+ string (APPEND _relative_filepath ".cpp" )
682+ endif ()
683+
680684 set ("${OUTPUT_VARIABLE} " "${OUTPUT_DIRPATH} /${_relative_filepath} " PARENT_SCOPE)
681685 else ()
682686 unset ("${OUTPUT_VARIABLE} " PARENT_SCOPE)
@@ -818,10 +822,6 @@ function(__arduino_preprocess OUTPUT_VARIABLE OUTPUT_DIRPATH SOURCE_DIRPATH MODE
818822 "${SOURCE_DIRPATH} " "${_source_filepath} "
819823 "${OUTPUT_DIRPATH} " _output_filepath)
820824
821- if (MODE STREQUAL "SKETCH" )
822- string (APPEND _output_filepath ".cpp" )
823- endif ()
824-
825825 string (MD5 _filepath_hash "${_output_filepath} " )
826826 set (_config_filepath "${CMAKE_BINARY_DIR} /ArduinoFiles/${_target} /preprocess-config-${_filepath_hash} .cmake" )
827827
You can’t perform that action at this time.
0 commit comments