1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
diff --git a/Makefile b/Makefile
index f52a3ae..ab0594a 100644
--- a/Makefile
+++ b/Makefile
@@ -378,6 +378,22 @@ else ifeq ($(platform), retrofw)
CXXFLAGS += -std=c++11
CFLAGS += -std=gnu11
+# TRIMUI
+else ifeq ($(platform), trimui)
+ TARGET := $(TARGET_NAME)_libretro.so
+ CC = $(CROSS_COMPILE)gcc
+ CXX = $(CROSS_COMPILE)g++
+ AR = $(CROSS_COMPILE)ar
+ SHARED := -shared -Wl,--no-undefined -Wl,--version-script=link.T
+ LDFLAGS += -fno-PIC -flto
+ CXXFLAGS += -std=c++11
+ CFLAGS += -std=gnu11
+ CFLAGS += -fomit-frame-pointer -ffast-math -mcpu=arm926ej-s -mtune=arm926ej-s -fno-PIC -flto
+ OPTIMIZE := -Ofast -DNDEBUG
+ ifeq (,$(DEBUG))
+ LDFLAGS += -s
+ endif
+
# Windows MSVC 2017 all architectures
else ifneq (,$(findstring windows_msvc2017,$(platform)))
@@ -627,10 +643,20 @@ endif
ifeq ($(DEBUG),1)
FLAGS += -O0 -g
+else ifneq (,$(OPTIMIZE))
+ CFLAGS += $(OPTIMIZE)
+ CXXFLAGS += $(OPTIMIZE)
else
FLAGS += -O2 -DNDEBUG $(EXTRA_GCC_FLAGS)
endif
+ifeq ($(PROFILE), GENERATE)
+ CFLAGS += -fprofile-generate=./profile/beetle-pce-fast
+ LDFLAGS += -lgcov
+else ifeq ($(PROFILE), APPLY)
+ CFLAGS += -fprofile-use -fprofile-dir=../profile/beetle-pce-fast -fbranch-probabilities
+endif
+
ifneq (,$(findstring msvc,$(platform)))
ifeq ($(DEBUG), 1)
CFLAGS += -MTd
|