summaryrefslogtreecommitdiff
path: root/scripts/runcmapdump.sh
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2018-04-04 16:54:50 +0200
committerTor Andersson <tor.andersson@artifex.com>2018-04-25 12:26:32 +0200
commit5dd383a4eb03c05f0e34fd166c133d567d66de3d (patch)
treed275cc64defa8d5e806b5281857d6266ab8269b0 /scripts/runcmapdump.sh
parent5f4a7fef375a16f457974794ab5c552105107652 (diff)
downloadmupdf-5dd383a4eb03c05f0e34fd166c133d567d66de3d.tar.xz
Check in generated CMap source.
Created with the 'scripts/runcmapdump.sh' script.
Diffstat (limited to 'scripts/runcmapdump.sh')
-rw-r--r--scripts/runcmapdump.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/scripts/runcmapdump.sh b/scripts/runcmapdump.sh
new file mode 100644
index 00000000..ae73add9
--- /dev/null
+++ b/scripts/runcmapdump.sh
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+LIST=$(echo resources/cmaps/* | sort)
+
+for f in $LIST
+do
+ b=$(basename $f)
+ echo "#include \"cmaps/$b.h\""
+ python scripts/cmapdump.py > source/pdf/cmaps/$b.h $f
+done
+
+
+echo "static pdf_cmap *table[] = {"
+for f in $LIST
+do
+ b=$(basename $f)
+ c=$(echo $b | tr - _)
+ echo "&cmap_$c,"
+done
+echo "};"