summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabrice <fabrice@schaub-dev.xyz>2026-02-11 08:29:28 +0100
committerFabrice <fabrice@schaub-dev.xyz>2026-02-11 08:29:28 +0100
commit38e79deda14e1c9da49d5823ef84075fb2ff91ad (patch)
tree43ff0031ebb50f46f1d1a75a255705a34c6638f0
parentd40dd284f712135bb12188c2c804bfca4a35e1cf (diff)
weird
-rw-r--r--.gitmodules3
-rw-r--r--Makefile17
m---------freetype0
-rw-r--r--src/text.h3
4 files changed, 17 insertions, 6 deletions
diff --git a/.gitmodules b/.gitmodules
index 5fc57bc..9f754be 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -8,3 +8,6 @@
[submodule "wgpu"]
path = wgpu
url = https://github.com/gfx-rs/wgpu-native.git
+[submodule "freetype"]
+ path = freetype
+ url = https://github.com/freetype/freetype.git
diff --git a/Makefile b/Makefile
index ea3043c..6e991b9 100644
--- a/Makefile
+++ b/Makefile
@@ -39,10 +39,16 @@ HASHMAP_SOURCE = $(HASHMAP_DIR)/hashmap.c
GLAD_DIR = $(WORK_DIR)/glad
GLAD_SOURCE = $(GLAD_DIR)/glad.c
+FREETYPE_DIR = $(WORK_DIR)/freetype
+FREETYPE_BUILD = $(FREETYPE_DIR)/build
+FREETYPE_INCLUDE = $(FREETYPE_BUILD)/include
+FREETYPE_ARCHIVE = $(FREETYPE_BUILD)/libfreetype.a
+
CSH_FLAGS += \
-I$(MI_INCLUDE) \
-I$(HASHMAP_DIR) \
- -I$(GLAD_DIR)
+ -I$(GLAD_DIR) \
+ -I$(FREETYPE_INCLUDE)
MI_GENERATOR = "Unix Makefiles"
@@ -66,7 +72,7 @@ OBJECTS += $(MI_OBJECT)
DEPS = $(OBJECTS:.o=.d)
-LIBRARIES = -lwayland-client -lEGL -lwayland-egl
+LIBRARIES = -lwayland-client -lEGL -lwayland-egl $(FREETYPE_ARCHIVE)
all: $(WAYCLOCK)
@@ -82,7 +88,7 @@ $(MI_OBJECT): | $(MI_BUILD)
@echo " MAKE $@"
@$(MAKE) -C $(MI_BUILD)
-$(WAYCLOCK): $(OBJECTS)
+$(WAYCLOCK): $(OBJECTS) $(LIBRARIES)
@echo " LD $@"
@$(CXX) $(CXX_FLAGS) -o $@ $^ $(LIBRARIES)
@@ -96,8 +102,9 @@ $(WAYCLOCK): $(OBJECTS)
.PHONY: clean
clean:
- @$(RM) $(OBJECTS) $(DEPS)
- @$(RM) $(WAYCLOCK)
@$(RM) $(MI_BUILD)
+ @$(RM) $(FREETYPE_BUILD)
+ @$(RM) $(WAYCLOCK)
+ @$(RM) $(OBJECTS) $(DEPS)
-include $(DEPS) \ No newline at end of file
diff --git a/freetype b/freetype
new file mode 160000
+Subproject 85c8efe0afa5ad0df35114e317a065f544943c5
diff --git a/src/text.h b/src/text.h
index 089ccce..4cf6e2a 100644
--- a/src/text.h
+++ b/src/text.h
@@ -3,4 +3,5 @@
#include "utils.h"
#include "vec.h"
-struct font_s {}; \ No newline at end of file
+
+struct font_s {};