From 0b9c54adadbddd1e00db2f74d6a96299ffcbd584 Mon Sep 17 00:00:00 2001 From: klemek Date: Thu, 18 Sep 2025 18:14:28 +0200 Subject: [PATCH] include hashmap.c --- .gitmodules | 3 +++ Makefile.am | 4 ++-- Makefile.dev | 1 + README.md | 2 ++ hashmap.c | 1 + include/hashmap.h | 1 + 6 files changed, 10 insertions(+), 2 deletions(-) create mode 160000 hashmap.c create mode 120000 include/hashmap.h diff --git a/.gitmodules b/.gitmodules index 1d0fe9b..9c889b9 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,6 @@ [submodule "linmath.h"] path = linmath.h url = https://github.com/datenwolf/linmath.h +[submodule "hashmap.c"] + path = hashmap.c + url = https://github.com/tidwall/hashmap.c diff --git a/Makefile.am b/Makefile.am index 5625cb9..7bc4a48 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,6 +1,6 @@ AUTOMAKE_OPTIONS = foreign subdir-objects -Wall bin_PROGRAMS = forge -forge_SOURCES = src/main.c src/args.c src/forge.c src/file.c src/window.c src/shaders.c src/timer.c src/strings.c $(top_srcdir)/include/glad/gl.h +forge_SOURCES = src/main.c src/args.c src/forge.c src/file.c src/window.c src/shaders.c src/timer.c src/strings.c $(top_srcdir)/include/glad/gl.h $(top_srcdir)/hashmap.c/hashmap.c forge_CFLAGS = -Ofast -march=native -flto -funroll-loops -fprefetch-loop-arrays -fno-exceptions -fopenmp -I$(top_srcdir)/include -DGLFW_INCLUDE_NONE forge_LDADD = -lm -lGL -lglfw -include_HEADERS = src/main.h src/args.h src/config.h src/types.h src/forge.h src/file.h src/constants.h src/window.h src/shaders.h src/logs.h src/timer.h src/strings.h $(top_srcdir)/include/glad/gl.h $(top_srcdir)/include/linmath.h \ No newline at end of file +include_HEADERS = src/main.h src/args.h src/config.h src/types.h src/forge.h src/file.h src/constants.h src/window.h src/shaders.h src/logs.h src/timer.h src/strings.h $(top_srcdir)/include/glad/gl.h $(top_srcdir)/include/linmath.h $(top_srcdir)/include/hashmap.h \ No newline at end of file diff --git a/Makefile.dev b/Makefile.dev index 7862151..cc84e3c 100644 --- a/Makefile.dev +++ b/Makefile.dev @@ -12,6 +12,7 @@ build: gcc \ src/*.h src/*.c \ -Iinclude \ + hashmap.c/hashmap.c \ -lm -lGL -lglfw \ -Wall -Wextra \ -DGLFW_INCLUDE_NONE \ diff --git a/README.md b/README.md index 32f4f52..fbf1ae6 100644 --- a/README.md +++ b/README.md @@ -105,12 +105,14 @@ make -f Makefile.dev release-arch - [x] Include common code - [ ] 16 input + 16 fx definition and selection (with const param) - [x] Feedback texture + - [ ] Shaders config file - [ ] Clean code - [ ] Midi - [ ] Read Midi events - [ ] Read midi mapping config file - [ ] Write Midi events - [ ] Save midi state + - [ ] State machine with A/B switch - [ ] Tap-tempo feature - [ ] Clean code - [ ] Video input diff --git a/hashmap.c b/hashmap.c new file mode 160000 index 0000000..5e475b4 --- /dev/null +++ b/hashmap.c @@ -0,0 +1 @@ +Subproject commit 5e475b4662622c51b8f375e7b2013e25f3c77b57 diff --git a/include/hashmap.h b/include/hashmap.h new file mode 120000 index 0000000..c81b4f2 --- /dev/null +++ b/include/hashmap.h @@ -0,0 +1 @@ +../hashmap.c/hashmap.h \ No newline at end of file