summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorOxore <oxore@protonmail.com>2018-12-06 04:50:12 +0300
committerOxore <oxore@protonmail.com>2018-12-06 04:50:12 +0300
commit0813c5e414de517ff0fef6cc9eedcb4d512f4fe8 (patch)
tree49d492f6d835163378341c37da62596ba92db4fb /Makefile
parente3614f6eef762ca0c2e14736c8a20760c6d5661b (diff)
Add prefix libs support in the Makefile
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile3
1 files changed, 3 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index f9a15a3..41b61b6 100644
--- a/Makefile
+++ b/Makefile
@@ -16,6 +16,7 @@ SOURCES:=$(wildcard $(SRC)/*.c)
OBJECTS:=$(SOURCES:$(SRC)/%.c=$(BUILD)/%.c.o)
DEPENDS:=$(OBJECTS:.o=.d)
+INCLUDE+=$(PREFIX)/include
INCLUDE+=include
INCLUDE+=$(MUNIT)
INCLUDE:=$(INCLUDE:%=-I%)
@@ -34,6 +35,8 @@ CFLAGS+=-g3
CFLAGS+=-O0
CFLAGS+=-MD
+LDFLAGS+=-L$(PREFIX)/lib
+LDFLAGS+=-Wl,-rpath=$(PREFIX)/lib
LDFLAGS+=$(COMMON)
LDFLAGS_TETRIS+=$(LDFLAGS)