aboutsummaryrefslogtreecommitdiff
path: root/kittenc.h
diff options
context:
space:
mode:
authorJavier <dev.git@javispedro.com>2026-09-03 23:49:29 +0200
committerJavier <dev.git@javispedro.com>2026-09-04 00:06:23 +0200
commit1b9e3118374a13dc12652d87b1dd3d1ccfecbbf3 (patch)
tree0c5f7b5aef76806a449d799dba333d41eaa60aa2 /kittenc.h
parent906193586d30a382d2b982419d92f80c07a65286 (diff)
downloadvbados-1b9e3118374a13dc12652d87b1dd3d1ccfecbbf3.tar.gz
vbados-1b9e3118374a13dc12652d87b1dd3d1ccfecbbf3.zip
embed language & unicode tables into main executables
use KITTENC to embed all NLS files into executable KITTENC does not allow loading external files anymore... embed the cp???uni.tbl (codepage -> unicode conversion tables) into the main executable too. however, we will still try to find them in PATH if user cp is missing from the internal ones. this means the distribution zip/flp now contain much fewer files. con: some utilities now need to built in the host (kittenc & unitbl2c) this may make the build less portable; so far unix and dos/386 still work.
Diffstat (limited to 'kittenc.h')
-rw-r--r--kittenc.h44
1 files changed, 44 insertions, 0 deletions
diff --git a/kittenc.h b/kittenc.h
new file mode 100644
index 0000000..d42ec27
--- /dev/null
+++ b/kittenc.h
@@ -0,0 +1,44 @@
+/*
+ KITTENC - compile kitten files and attach this to
+ executables in a way that the kitten library retrieves
+ the language resources, in the same way that
+ catgets/kittengets ever did
+
+*/
+/*
+ This software is free software; free to use,
+ modify, pass to others, whatever
+
+ use it at your own risk
+*/
+
+#ifndef KITTENC_H
+#define KITTENC_H
+
+//internal stuff shared between kitten.c and kittenc.c
+struct message_header
+{
+ short len;
+ short id;
+ // char message[];
+};
+
+struct content
+{
+ char language[4];
+ long filepos_start; // for this language
+ long filepos_end;
+ long reserved; // align on 16 byte to look better in hex editor
+};
+
+struct message_end
+{
+ long filepos; // points to content
+ long resource_count;// number of entries
+ long fileend_orig; // file end NOW because UPX
+ char ID[8]; // "KITTENC"
+};
+
+#define KITTEN_MAX_RESOURCES 16
+
+#endif /* KITTENC_H */