15b5430611
Instead of using cmake, I *obviously* need to use cmake -G 'Unix Makefiles'. How silly of me.
...
MicroSoft Windows: "it just works"
2025-09-15 12:30:01 +02:00
6c184a4d36
re-enable windows, and see what happens.
2025-09-15 12:17:37 +02:00
82ebe1f4d1
fix: use CC instead of LD, and deprecate LD
...
this is a bit confusing, since setting `LD=cc` would have the same
issue; `ld: -f may not be used without -shared`. So I've got no idea
what is going wrong, I guess it's something funky.
This works, so we shall stick with this.
2025-09-15 12:08:39 +02:00
5f3bd40a47
potato time.
...
this is quite upsetting.
2025-09-15 12:04:41 +02:00
158a7f8383
fix: don't use UNIX sh based ifs, instead opt for GNU Make.
...
This is more portable acorss machines
2025-09-15 12:04:41 +02:00
c32d1551c8
fix: regular xxd does not have -n, thus using some argument manipulation magic
...
On my main system I use `tinyxxd`, henceforth: "regular"
2025-09-15 12:04:41 +02:00
b04ce9998f
fix: shader hex code is formatted incorrectly
2025-09-15 11:59:39 +02:00
218b98e684
fix: colour coding on error messages is incorrect
2025-09-15 11:59:39 +02:00
f20171c0d7
fix: using the linker for generating a .o file is a feature for only GNU ld.
...
Now utilising a process to generate a .c file using `xxd`, and compiling
those to object files.
2025-09-15 11:59:39 +02:00
3a7709c392
fix: use more accurate linker flags / calling.
2025-09-15 11:59:39 +02:00
ec36d8c475
add runner architecture to the action cache
2025-09-15 11:59:39 +02:00
a14ef55262
fix: testing compilation does not correctly filter out main.o
2025-09-15 11:14:41 +02:00
d340bbe40b
fix: fminf and other <math.h> from libm not found.
...
The `-lm` linker flag was applied preceding the libraries, but it
should've been succeding.
2025-09-15 11:14:41 +02:00
0f6a2579b9
forcibly recompile the libs, so if deps get updated, this will be carried through.
...
This sacrifices a bit of workflow performance, but won't be too
significant. The heaviest step (cmake) is still circumvented
2025-09-15 11:14:40 +02:00
1ac4592503
Aparrently, the act docker container does not have cmake installed.
...
Adding this should not make a significant impact on workflow
performance.
2025-09-15 09:35:59 +02:00
4da02373a5
disable fail fast, so feedback is provided for all matrix combinations
2025-09-15 09:25:18 +02:00
c724ff0449
remove explicit definition for repository, since it messes with act
...
`act` allows to debug github workflows before sending them to the
server, allowing to test some behaviour, before pushing.
2025-09-15 09:20:07 +02:00
348c4e484c
fix: clean-libs can fail when it shouldn't
2025-09-13 21:44:46 +02:00
1140bd97bf
fix: linking library glfw, whilst the library compilation produces libglfw3.
...
This slight discrepancy is a tad annoying, since it doesn't work
backwards so it uses my system's version. But we'll figure something for
that out later... probably.
2025-09-13 21:32:33 +02:00
997b15c640
fix: obj/res/ path did not create a directory, so likely failed to place anything there.
2025-09-13 21:17:07 +02:00
f481af7e78
fix: incorrect gl.c path
2025-09-13 21:16:33 +02:00
1169ca98b1
use threaded makefile for more efficiency.
2025-09-13 21:11:58 +02:00
75ebff9071
remove pointer arithmatic warnings, since they are just useful
2025-09-13 21:11:38 +02:00
4f081e7f3e
remove usage of mempcpy; this is apart of GNU C
2025-09-13 21:09:56 +02:00
8a1ed6e3c4
attempt without including windows
2025-09-13 21:04:29 +02:00
a7678c874c
write a CI workflow for multiple OSes, that compile and test the code using the makefile.
2025-09-13 20:57:54 +02:00
d9ddae770a
fix: just use compiler builtins with endianess
...
this is the most portable and clean approach. Compiler built-ins should
always be present regardless, and is more maintainable, since we're not
trying to keep up with various versions of this header.
2025-09-13 20:25:38 +02:00
c2e1b67b4c
seperate out library compilation from general compilation
...
This can help with a more nuanced compilation. (eg. use system libraries
rather than compile our own)
Furthermore, it decreases the needed compilation time, since we needn't
recompile the whole thing when having cleaned out our local sources.
2025-09-13 20:25:38 +02:00
8548c2d037
fix: log macros were using GNU extensions without them needing them.
...
We can optionally add `,` utilising the `__VA_OPT__` macro. However,
this lead to the next problem, which is that an empty vardiac parameter
is a C23 extension. This was solved by dropping the string parameter,
making it be part of the vardiac parameters.
2025-09-13 20:25:38 +02:00
7ec6a3b91a
fix: using __bswap_X functions over bswap_X macros, which we should be using.
2025-09-13 20:25:38 +02:00
3f48a7abb2
add compile commands events to gitignore
2025-09-13 20:25:38 +02:00
667814fb72
rework makefile to put extera emphasis on us no longer performing cross-platform compilation
...
Furthermore, we removed a bunch of behaviour that wasn't needed, and
simplified the bunch.
2025-09-13 20:25:38 +02:00
23fda298e6
fix: makefile had some duplicate configurations
2025-09-11 23:28:58 +02:00
03c76b0be6
rename makefile to Makefile, to reflect how everyone seems to name their makefile.
...
it just makes sense, and I might as well do it like this to prevent
confusing people.
2025-09-11 23:28:58 +02:00
f0d14e76b2
write decompression logic up to the point of hanelling the buffer.
2025-09-10 12:52:35 +02:00
07f4ea34d2
macro flipped const char
2025-09-10 12:07:00 +02:00
5de0c77992
start writing code for decompressing chunk data.
...
I still haven't much of an idea where I'll take this, but it's a start.
I know it is needed for block filtering and such, I still need to find a
way how I'll actually implement it.
2025-09-10 11:37:20 +02:00
2cfae0fce4
rework error.h, to decrease impact on binary size.
...
We were statically creating a new string per log message, so re-using
the same message would cause duplicate byte sizes.
Now, all prefixes / suffixes are only defined once, the file name is
defined once per file, the line number should be defined once per unique
line.
This just saves some memory in the final binary, allowing things to be
optimised a little better.
2025-09-10 11:37:20 +02:00
d933931829
fix: shouldn't multiply by CHUNKS, but by SECTOR
2025-09-10 10:13:26 +02:00
f020347f71
change mvchunks parameter order, to be a bit more clear and consistent with functions such as memmove
2025-09-10 10:13:26 +02:00
b13de01f24
fix: violating strict aliasing rules in most areas in the new code.
...
Yes, I am aware there are plenty of violations in `conf.c`, but I'll
likely fix/rewrite those when I will use it. Since there are some other
changes I think I'll want to make.
2025-09-10 10:13:26 +02:00
3a0704710c
add a flag when debugging to generate SIGFPE when signed integer overflow occurs. (this is UB)
2025-09-10 10:13:26 +02:00
b72b8eaee1
add comments to point at where strict aliasing rule violations occur in data scripts
...
this is definitely not all of them, a thorough rewrite must take place
to fix as many as we can.
2025-09-10 10:13:26 +02:00
55635d44ae
delete redundant COLOUR32 definitions
2025-09-10 10:13:26 +02:00
4fa0b41e7a
add quit in main.c to atexit, for added safety
2025-09-10 10:13:26 +02:00
8a5afd6915
write a portable version of endian.h, to replace the system's endian.h.
...
utilising GNU C standard library for some of the functionality, or GNU C
extensions.
2025-09-10 10:13:26 +02:00
8b952fb86f
edit makefile to remove redundant flags, and make clean task more conditional
2025-08-29 11:47:46 +02:00
0baadfca75
update copyright information in all files
...
the comment was using single-line comments, I prefer multi-line comments
now.
This bothered me for much too long.
2025-08-29 09:36:55 +02:00
9a45294e56
write some constants for mcx.c, so things are less error-prone.
2025-08-29 09:35:02 +02:00
5b5f1f54af
remove unneeded code
2025-08-28 16:46:27 +02:00