summaryrefslogtreecommitdiff
path: root/2026/games/just__jane/Makefile
diff options
context:
space:
mode:
authorLLLL Colonq <llll@colonq>2026-08-04 04:35:44 -0400
committerLLLL Colonq <llll@colonq>2026-08-04 04:35:44 -0400
commit3c7796f066647090ed8436778bdfe25f11844c05 (patch)
tree0644a101004d91af4fcdc2f51fcc2e03f7f255ce /2026/games/just__jane/Makefile
parenta75221ab93f59d688f90cd83f0284ff98951fcfa (diff)
Prepare for upload
Diffstat (limited to '2026/games/just__jane/Makefile')
-rw-r--r--2026/games/just__jane/Makefile39
1 files changed, 39 insertions, 0 deletions
diff --git a/2026/games/just__jane/Makefile b/2026/games/just__jane/Makefile
new file mode 100644
index 0000000..c9b8c8e
--- /dev/null
+++ b/2026/games/just__jane/Makefile
@@ -0,0 +1,39 @@
+CXX := em++
+
+TARGET := sakura_samurai.html
+
+SRC_DIR := src
+OBJ_DIR := build/web
+
+# RAYLIB_DIR := ../just-packages/raylib-web/raylib
+RAYLIB_DIR := ../../examples/example_raylib
+
+CPPFLAGS := \
+ -I$(SRC_DIR) \
+ -isystem $(RAYLIB_DIR)/raylib/src \
+ -Iinclude
+
+CXXFLAGS := -std=c++23 -Wall -Wextra -O2 -DPLATFORM_WEB -Wno-unused-parameter -Wno-unused-argument -sFETCH
+
+LDFLAGS := \
+ $(RAYLIB_DIR)/libraylib.a \
+ -s USE_GLFW=3 \
+ -s ASYNCIFY \
+ -s ALLOW_MEMORY_GROWTH=1 \
+ -s ASSERTIONS=1 \
+ --preload-file assets
+
+APP_SRCS := $(shell find $(SRC_DIR) -name '*.cpp')
+
+all: $(TARGET)
+
+$(TARGET): $(APP_SRCS)
+ $(CXX) $(CPPFLAGS) $(CXXFLAGS) -o $@ $^ $(LDFLAGS)
+
+clean:
+ rm -rf $(OBJ_DIR) $(TARGET) sakura_samurai.js sakura_samurai.wasm sakura_samurai.data .cache
+
+serve: $(TARGET)
+ emrun --no_browser --port 8080 .
+
+.PHONY: all clean serve