diff options
author | turret <turret@duck.com> | 2023-11-19 18:57:55 -0600 |
---|---|---|
committer | turret <turret@duck.com> | 2023-11-19 18:57:55 -0600 |
commit | a8b2282eb88f24c3c5f461e1557fa2cf76ebc251 (patch) | |
tree | 67544659f7df20e0286cb82e17aa47520a601f14 /include/util.h | |
download | discord-bot-skeleton-a8b2282eb88f24c3c5f461e1557fa2cf76ebc251.tar.gz discord-bot-skeleton-a8b2282eb88f24c3c5f461e1557fa2cf76ebc251.tar.bz2 discord-bot-skeleton-a8b2282eb88f24c3c5f461e1557fa2cf76ebc251.zip |
Initial commit
- create subsystem system using clone syscall, shared memory, shared
file descriptors
- printk-like logging facility (TODO: console loglevel)
- initcall system (like linux kernel)
TODO: determine license
factors: linker.ld, linux kernel licensing (some ideas are more
liberally taken rather than paraphrased)
Diffstat (limited to 'include/util.h')
-rw-r--r-- | include/util.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/util.h b/include/util.h new file mode 100644 index 0000000..97435be --- /dev/null +++ b/include/util.h @@ -0,0 +1,5 @@ +#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) + +void die(const char *fmt, ...); + +#define writeputs(str) write(STDOUT_FILENO, str, strlen(str)); |