summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authoruint23 <[email protected]>2025-04-14 22:18:55 +0100
committeruint23 <[email protected]>2025-04-14 22:18:55 +0100
commit7883981fe9976b3933959c04fa8cc62158c70855 (patch)
tree0dbec9721c71c3f1e638a0bffc40cd18622077a1 /Makefile
parent54c9dd27d5674990ddc8d444f14336d549d52725 (diff)
inital window manager setup. check for other window managers too
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile24
1 files changed, 24 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..2cdfaf1
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,24 @@
+CC = gcc
+CFLAGS = -Wall -Wextra -O2 -g -Isrc
+LDFLAGS = -lX11
+
+SRC_DIR = src
+SRC = $(wildcard $(SRC_DIR)/*.c)
+OBJ = $(SRC:.c=.o)
+BIN = sxwm
+
+all: $(BIN)
+
+$(BIN): $(OBJ)
+ $(CC) -o $@ $^ $(LDFLAGS)
+
+$(SRC_DIR)/%.o: $(SRC_DIR)/%.c
+ $(CC) $(CFLAGS) -c -o $@ $<
+
+x:
+ rm -f $(SRC_DIR)/*.o $(BIN)
+
+r:
+ x all
+
+.PHONY: all clean rebuild