1
0
Fork 0
forked from soccera/rdo

Merge pull request 'Add static compilation rule to makefile' (#12) from henriquehbr/rdo:main into main

Reviewed-on: https://codeberg.org/sw1tchbl4d3/rdo/pulls/12
This commit is contained in:
sw1tchbl4d3 2022-12-04 11:05:53 +00:00
commit 7ab7f4bd65

View file

@ -1,12 +1,16 @@
CFLAGS = -Wall -Wextra -Werror -Wl,-z,now
CFLAGS_RELEASE = ${CFLAGS} -O2 -s -D_FORTIFY_SOURCE=2
CFLAGS_DEBUG = ${CFLAGS} -O0 -g -fsanitize=undefined
CFLAGS_STATIC = ${CFLAGS_RELEASE} -static-pie
LIBS = -lcrypt
CC = gcc
all: rdo.c
${CC} ${CFLAGS_RELEASE} rdo.c -o rdo ${LIBS}
static: rdo.c
${CC} ${CFLAGS_STATIC} rdo.c -o rdo ${LIBS}
debug: rdo.c
${CC} ${CFLAGS_DEBUG} rdo.c -o rdo ${LIBS}