mirror of
https://github.com/ThrowTheSwitch/Unity.git
synced 2025-06-03 11:15:24 +08:00
Cleanup example Makefiles, update test runners
Delete clang flags that were disabled with -Wno-*
This commit is contained in:
@ -5,17 +5,14 @@
|
||||
# ==========================================
|
||||
|
||||
#We try to detect the OS we are running on, and adjust commands as needed
|
||||
ifeq ($(OSTYPE),cygwin)
|
||||
CLEANUP = rm -f
|
||||
MKDIR = mkdir -p
|
||||
TARGET_EXTENSION=.out
|
||||
elseifeq ($(OSTYPE),msys)
|
||||
CLEANUP = rm -f
|
||||
MKDIR = mkdir -p
|
||||
TARGET_EXTENSION=.exe
|
||||
elseifeq ($(OS),Windows_NT)
|
||||
ifeq ($(OS),Windows_NT)
|
||||
ifeq ($(shell uname -s),) # not in a bash-like shell
|
||||
CLEANUP = del /F /Q
|
||||
MKDIR = mkdir
|
||||
else # in a bash-like shell, like msys
|
||||
CLEANUP = rm -f
|
||||
MKDIR = mkdir -p
|
||||
endif
|
||||
TARGET_EXTENSION=.exe
|
||||
else
|
||||
CLEANUP = rm -f
|
||||
@ -23,8 +20,12 @@ else
|
||||
TARGET_EXTENSION=.out
|
||||
endif
|
||||
|
||||
UNITY_ROOT=../..
|
||||
C_COMPILER=gcc
|
||||
ifeq ($(shell uname -s), Darwin)
|
||||
C_COMPILER=clang
|
||||
endif
|
||||
|
||||
UNITY_ROOT=../..
|
||||
|
||||
CFLAGS=-std=c89
|
||||
CFLAGS += -Wall
|
||||
@ -48,7 +49,7 @@ TARGET2 = $(TARGET_BASE2)$(TARGET_EXTENSION)
|
||||
SRC_FILES1=$(UNITY_ROOT)/src/unity.c src/ProductionCode.c test/TestProductionCode.c test/test_runners/TestProductionCode_Runner.c
|
||||
SRC_FILES2=$(UNITY_ROOT)/src/unity.c src/ProductionCode2.c test/TestProductionCode2.c test/test_runners/TestProductionCode2_Runner.c
|
||||
INC_DIRS=-Isrc -I$(UNITY_ROOT)/src
|
||||
SYMBOLS=-DTEST
|
||||
SYMBOLS=
|
||||
|
||||
all: clean default
|
||||
|
||||
|
@ -11,7 +11,7 @@
|
||||
setUp(); \
|
||||
TestFunc(); \
|
||||
} \
|
||||
if (TEST_PROTECT() && !TEST_IS_IGNORED) \
|
||||
if (TEST_PROTECT()) \
|
||||
{ \
|
||||
tearDown(); \
|
||||
} \
|
||||
|
@ -11,7 +11,7 @@
|
||||
setUp(); \
|
||||
TestFunc(); \
|
||||
} \
|
||||
if (TEST_PROTECT() && !TEST_IS_IGNORED) \
|
||||
if (TEST_PROTECT()) \
|
||||
{ \
|
||||
tearDown(); \
|
||||
} \
|
||||
|
Reference in New Issue
Block a user