-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
25 lines (21 loc) · 877 Bytes
/
Makefile
File metadata and controls
25 lines (21 loc) · 877 Bytes
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
OUT = "pick"
CC = gcc
CFLAGS = -Wall -g
LDFLAGS = -Os -nostartfiles -nodefaultlibs -lc -fno-plt -fno-stack-protector -fno-stack-check -fno-unwind-tables -fno-asynchronous-unwind-tables -fomit-frame-pointer -ffast-math -no-pie -fno-pic -fno-PIE -ffunction-sections -fdata-sections -fno-plt -fmerge-all-constants -mno-fancy-math-387 -mno-ieee-fp
SOURCES = $(shell find src/ -name "*.cpp")
HEADERS = $(shell find src/ -name "*.h")
LIBS = `pkg-config --cflags --libs gtk+-3.0`
all: $(SOURCES) $(HEADERS)
@echo "Sources: $(SOURCES)"
@echo "Headers: $(HEADERS)"
$(CC) $(CFLAGS) $(SOURCES) $(LIBS) $(LDFLAGS) -o $(OUT)
strip -s -R .comment -R .gnu.version $(OUT)
sstrip $(OUT)
./autovndh.py $(OUT) --zopfli --lzma --vndh_unibin --vndh_no_argv --vndh "" > $(OUT)~
rm $(OUT) && mv $(OUT)~ $(OUT)
@echo "Size of the program:"
@du -b $(OUT)
run:
./$(OUT)
clean:
rm $(OUT)