diff --git a/cmake/target/fpp_depend.cmake b/cmake/target/fpp_depend.cmake index 1c68e602c0..1780d5ddcd 100644 --- a/cmake/target/fpp_depend.cmake +++ b/cmake/target/fpp_depend.cmake @@ -74,6 +74,7 @@ function(fpp_depend_add_module_target MODULE TARGET SOURCES DEPENDENCIES) ${FPP_SOURCES} DEPENDS fpp_locs + "${FPRIME_BINARY_DIR}/locs.fpp" ${FPP_SOURCES} ) add_custom_target("${TARGET}_${MODULE}" DEPENDS ${OUTPUT_FILES} diff --git a/cmake/target/fpp_locs.cmake b/cmake/target/fpp_locs.cmake index 1fa1afd48b..4debcdec6b 100644 --- a/cmake/target/fpp_locs.cmake +++ b/cmake/target/fpp_locs.cmake @@ -21,7 +21,7 @@ set(FPP_LOCATE_DEFS_HELPER "${PYTHON}" "${CMAKE_CURRENT_LIST_DIR}/tools/redirect function(fpp_locs_add_global_target TARGET) set(FPP_CONFIGS "${FPRIME_FRAMEWORK_PATH}/Fpp/ToCpp.fpp") add_custom_command( - OUTPUT "${FPRIME_BINARY_DIR}/locs.fpp" + OUTPUT "${CMAKE_BINARY_DIR}/locs.fpp" COMMAND "${FPP_LOCATE_DEFS_HELPER}" "${CMAKE_BINARY_DIR}/locs.fpp" @@ -31,7 +31,7 @@ function(fpp_locs_add_global_target TARGET) COMMAND_EXPAND_LISTS ) add_custom_target( - "${TARGET}" DEPENDS "${FPRIME_BINARY_DIR}/locs.fpp" + "${TARGET}" DEPENDS "${CMAKE_BINARY_DIR}/locs.fpp" COMMAND "${CMAKE_COMMAND}" -E copy_if_different "${CMAKE_BINARY_DIR}/locs.fpp" "${FPRIME_BINARY_DIR}/locs.fpp"