Commit Graph

38 Commits

Author SHA1 Message Date
ca9413db67 add a recipe to print some session info when calling the makefile 2025-06-15 13:57:52 +02:00
d4f2796859 add definitions to quickly compile using a some default parameters 2025-06-15 13:57:52 +02:00
2b710a28bb fix: remove -DGLFW_DLL flag, since it has no reason to be there and is causing problems 2025-06-15 13:57:52 +02:00
a6ec8cf83d fix: windows compilation because it doesn't support sanitisers 2025-06-15 13:57:52 +02:00
f4a287857d tweak the testing flags a little, to catch errors a bit easier 2025-06-13 01:55:44 +02:00
3d0b3a5e1e add log for debugging to makefile, where it logs the PKG_CONFIG_PATH value. 2025-06-11 17:56:22 +02:00
4fc1717983 correct pkg-config command 2025-06-11 17:56:22 +02:00
e57f499a32 add libmath to the linker 2025-06-06 18:09:49 +02:00
5f4389d9f9 provide a better method of embedding shaders within the source code 2025-06-06 18:09:49 +02:00
fc2cbd9924 switch from c17 to gnu99
I am choosing gnu99 over c99, since I am planning to use GNU extensions,
like bswap. (in a future commit)
Why I choose c99 over c17, is because this'll produce more portable
code.

c99 does not implement noreturn.h, thus I added it to the compiler
attributes header.
2025-06-02 12:41:01 +02:00
cbefafacf8 rework makefile to be more os- and compiler-agnostic.
alongside removing non-crucial complexity and attempting to simplify
things as much as I can.
2025-06-02 12:41:01 +02:00
Quinn
e9946118ea add test compilation / running to makefile 2025-06-02 12:41:01 +02:00
Quinn
06e6875585 parameterize the compilation process via a macro 2025-06-02 12:41:00 +02:00
Quinn
4b611c7918 add sanitizers to flags 2025-06-02 12:41:00 +02:00
Quinn
7354c049ec add notparallel to clean 2025-06-02 12:41:00 +02:00
Quinn
9120e37c26 add glad into the compilation for openGL function entry points 2025-06-02 12:41:00 +02:00
Quinn
ef9f472018 make compile_commands.json file creation be more linked to individual targets, than just having it locally.
this way, when recompiling for a new target, firstly. A full clean is
not necessary. Secondly, switching between targets updates the symlink
at project root accordingly.
2025-06-02 12:41:00 +02:00
Quinn
62e0c149cc flip the DEBUG condition to check for non-0, rather than 1.
this way debug can be set to `true` or anything other than `0`, to
enable it, which makes more semantic sense.
2025-06-02 12:41:00 +02:00
Quinn
bb7cbd22d5 change profile log type from warn to mesg 2025-06-02 12:41:00 +02:00
Quinn
0dacc79cac fix: windows compilation
windows needed some special things when it came to including packages.
2025-06-02 12:41:00 +02:00
Quinn
538f20f733 remove references of rust in README.md 2025-05-01 16:48:47 +02:00
Quinn
401854002f remove rust/cargo from compilation
it has become clear that incorperating rust in this project was a
mistake, since I don't understand it well enough for it to be useful,
and at this rate it'd be faster to use GLFW in C than in rust.
2025-05-01 16:48:45 +02:00
Quinn
f61a72c680 include glfw libraries in the makefile 2025-05-01 16:48:41 +02:00
Quinn
0c74252a2f use NDEBUG instead of DEBUG as preprocessor. 2025-05-01 16:48:41 +02:00
Quinn
95f6d9b9d9 fix: makefile unable to convert the src/%.c paths into obj/$arch/$prof/%.o paths
had to include the src/ path in the shell finding, due to it otherwise
prefixing with ./src (it was aparrently also including files from
target/)
2025-05-01 16:48:40 +02:00
Quinn
7fe877fcbf move dir definitions before source definitions 2025-05-01 16:48:39 +02:00
Quinn
33ffa6d89e rework makefile logging to be more readable
added the log categories explicitly, removing the need for specifying
the log colour with each log
2025-05-01 16:48:38 +02:00
Quinn
64691550bd use a more dynamic makefile
- remove CLANG env, as it might be confused for the compiler. And it
doesn't fit the build system that well anyway. (as we're compiling based
on file extension already)
- locate source files using find, rather than a bunch of wildcards.
- rename TARGET to BIN and store DIR_BIN and DIR_OBJ for the output
directories
- use pattern matchin for C object file creation, rather than specifying
all the sources manually
- remove directory target as directory creation is handled by the
recipe's themselves now.
2025-05-01 16:48:38 +02:00
Quinn
c363fb6481 use bear whenever available, rather than only when debugging 2025-05-01 16:48:37 +02:00
Quinn
85bb26a08c use cargo instead of rustc 2025-05-01 16:48:35 +02:00
Quinn
961b8796ee use printf instead of echo due to some minor issues 2025-05-01 16:48:34 +02:00
Quinn
ec06481a36 write todo comments 2025-05-01 16:48:33 +02:00
Quinn
4c0f0a5aa9 introduce target flags for linking step 2025-05-01 16:48:31 +02:00
Quinn
2754fcbe3f warnings as errors 2025-05-01 16:48:30 +02:00
Quinn
c913e62fcc seperate rust flags out of the rust compilation command
for consistency and able to specify a target now, which is still
relevant for linking, despite not using the standard library
2025-05-01 16:48:30 +02:00
Quinn
801ed6ba76 always compile as static library 2025-05-01 16:48:29 +02:00
Quinn
07f4e5fe48 remove unused version 2025-05-01 16:48:28 +02:00
Quinn
7a64aefcac setup project files
Added (most) of the project files to the working tree.
Some work still needs to be done to make the rust/C communication better
before we can fully move on to starting to write the actual applicaiton.
2025-05-01 16:48:18 +02:00