move US_TO_NT_MULTIPLIER macro definition to Makefile (#6445)

* only:unit test time mess

* move US_TO_NT_MULTIPLIER macro definition in Makefile

---------

Co-authored-by: rusefi <rusefillc@gmail.com>
This commit is contained in:
kifir23917 2024-05-02 02:33:39 +03:00 committed by GitHub
parent 3da4de56f3
commit b84a4d13e1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 6 additions and 4 deletions

View File

@ -16,6 +16,8 @@ CHIBIOS = ../firmware/ChibiOS
CHIBIOS_CONTRIB = ../firmware/ChibiOS-Contrib
RULESPATH = $(CHIBIOS)/os/common/startup/SIMIA32/compilers/GCC
US_TO_NT_MULTIPLIER = 100
PROJECT_CPU=simulator
ifneq ($(BOARD_DIR),)
@ -49,6 +51,7 @@ endif
# Compiler options here.
ifeq ($(USE_OPT),)
USE_OPT = -Wall -Wno-error=implicit-fallthrough -Wno-error=write-strings -Wno-error=strict-aliasing -Werror=nonnull
USE_OPT += -D US_TO_NT_MULTIPLIER=$(US_TO_NT_MULTIPLIER)
ifeq ($(OS),Windows_NT)
USE_OPT += -DEFI_SIM_IS_WINDOWS=1

View File

@ -28,8 +28,6 @@
#define hasOsPanicError() (FALSE)
#define US_TO_NT_MULTIPLIER 100
// need to fight 32bit int overflow
#define MY_US2ST(x) ((x) / 10)

View File

@ -6,6 +6,8 @@
PROJECT_DIR = ../firmware
UNIT_TESTS_DIR=$(PROJECT_DIR)/../unit_tests
US_TO_NT_MULTIPLIER = 100
# Imported source files and paths
include $(PROJECT_DIR)/console/console.mk
include $(PROJECT_DIR)/console/binary/tunerstudio.mk

View File

@ -53,8 +53,6 @@ void chDbgAssert(int c, char *msg, void *arg);
}
#endif /* __cplusplus */
#define US_TO_NT_MULTIPLIER 100
#define VCS_VERSION "321"
#define RUS_EFI_VERSION_TAG "rusEfiVersion"

View File

@ -39,6 +39,7 @@ ifeq ($(USE_OPT),)
#USE_OPT = $(RFLAGS) -O2 -fgnu89-inline -ggdb -fomit-frame-pointer -falign-functions=16 -std=gnu99 -Werror-implicit-function-declaration -Werror -Wno-error=pointer-sign -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=sign-compare -Wno-error=unused-parameter -Wno-error=missing-field-initializers
USE_OPT = -c -Wall -O0 -ggdb -g
USE_OPT += -Werror=missing-field-initializers
USE_OPT += -D US_TO_NT_MULTIPLIER=$(US_TO_NT_MULTIPLIER)
endif
ifeq ($(COVERAGE),yes)