Unused warnings are no longer treated as errrors by default (#4092)
This commit is contained in:
commit
1d9e692e31
2 changed files with 15 additions and 7 deletions
1
.github/workflows/build.yml
vendored
1
.github/workflows/build.yml
vendored
|
@ -17,6 +17,7 @@ jobs:
|
||||||
GAME_LANGUAGE: ENGLISH
|
GAME_LANGUAGE: ENGLISH
|
||||||
MODERN: 0
|
MODERN: 0
|
||||||
COMPARE: 0
|
COMPARE: 0
|
||||||
|
UNUSED_ERROR: 1
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
21
Makefile
21
Makefile
|
@ -36,13 +36,14 @@ else
|
||||||
EXE :=
|
EXE :=
|
||||||
endif
|
endif
|
||||||
|
|
||||||
TITLE := POKEMON EMER
|
TITLE := POKEMON EMER
|
||||||
GAME_CODE := BPEE
|
GAME_CODE := BPEE
|
||||||
MAKER_CODE := 01
|
MAKER_CODE := 01
|
||||||
REVISION := 0
|
REVISION := 0
|
||||||
MODERN ?= 1
|
MODERN ?= 1
|
||||||
TEST ?= 0
|
TEST ?= 0
|
||||||
ANALYZE ?= 0
|
ANALYZE ?= 0
|
||||||
|
UNUSED_ERROR ?= 0
|
||||||
|
|
||||||
ifeq (agbcc,$(MAKECMDGOALS))
|
ifeq (agbcc,$(MAKECMDGOALS))
|
||||||
MODERN := 0
|
MODERN := 0
|
||||||
|
@ -127,6 +128,12 @@ override CFLAGS += -mthumb -mthumb-interwork -O2 -mabi=apcs-gnu -mtune=arm7tdmi
|
||||||
ifeq ($(ANALYZE),1)
|
ifeq ($(ANALYZE),1)
|
||||||
override CFLAGS += -fanalyzer
|
override CFLAGS += -fanalyzer
|
||||||
endif
|
endif
|
||||||
|
# Only throw an error for unused elements if its RH-Hideout's repo
|
||||||
|
ifeq ($(UNUSED_ERROR),0)
|
||||||
|
ifneq ($(GITHUB_REPOSITORY_OWNER),rh-hideout)
|
||||||
|
override CFLAGS += -Wno-error=unused-variable -Wno-error=unused-const-variable -Wno-error=unused-parameter -Wno-error=unused-function -Wno-error=unused-but-set-parameter -Wno-error=unused-but-set-variable -Wno-error=unused-value -Wno-error=unused-local-typedefs
|
||||||
|
endif
|
||||||
|
endif
|
||||||
ROM := $(MODERN_ROM_NAME)
|
ROM := $(MODERN_ROM_NAME)
|
||||||
OBJ_DIR := $(MODERN_OBJ_DIR_NAME)
|
OBJ_DIR := $(MODERN_OBJ_DIR_NAME)
|
||||||
LIBPATH := -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libgcc.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libnosys.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libc.a))"
|
LIBPATH := -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libgcc.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libnosys.a))" -L "$(dir $(shell $(PATH_MODERNCC) -mthumb -print-file-name=libc.a))"
|
||||||
|
|
Loading…
Reference in a new issue