aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorGravatar BanceDev 2026-02-17 21:19:02 -0500
committerGravatar BanceDev 2026-02-17 21:19:02 -0500
commitc259a3c0bb5231ab3797d553503b710adb3c24e8 (patch)
tree16ffb85bd6b39f81b70ca45f35789179a14159ec /Makefile
initial commit
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile31
1 files changed, 31 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..e796520
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,31 @@
+CC = cc
+
+PREFIX = /usr/local
+LIBS = -lX11 -lXinerama -lXcursor
+
+CPPFLAGS = -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=700
+CFLAGS = -std=c99 -pedantic -Wall -Wextra -Os ${CPPFLAGS} -fdiagnostics-color=always -I/usr/X11R6/include
+LDFLAGS = ${LIBS} -L/usr/X11R6/lib
+
+SRC = src/tilite.c
+OBJ = build/tilite.o
+
+all: tilite
+
+build/tilite.o: src/tilite.c
+ mkdir -p build
+ ${CC} -c ${CFLAGS} src/tilite.c -o build/tilite.o
+
+tilite: ${OBJ}
+ ${CC} -o tilite ${OBJ} ${LDFLAGS}
+
+clean:
+ rm -rf build tilite
+
+install: all
+ mkdir -p ${PREFIX}/bin
+ cp -f tilite ${PREFIX}/bin/
+ chmod 755 ${PREFIX}/bin/tilite
+
+uninstall:
+ rm -f ${PREFIX}/bin/tilite