aboutsummaryrefslogtreecommitdiff
path: root/libX11/src/util/mkks.sh
diff options
context:
space:
mode:
Diffstat (limited to 'libX11/src/util/mkks.sh')
-rw-r--r--libX11/src/util/mkks.sh11
1 files changed, 11 insertions, 0 deletions
diff --git a/libX11/src/util/mkks.sh b/libX11/src/util/mkks.sh
new file mode 100644
index 000000000..262cc9540
--- /dev/null
+++ b/libX11/src/util/mkks.sh
@@ -0,0 +1,11 @@
+#!/bin/sh
+
+cat $* | awk 'BEGIN { \
+ printf "/*\n * This file is generated from %s. Do not edit.\n */\n", \
+ "$(INCLUDESRC)/keysymdef.h";\
+} \
+/^#define/ { \
+ len = length($2)-3; \
+ printf("{ \"%s\", %s },\n", substr($2,4,len), $3); \
+}'
+