+#if ! UNCOMPRESSED
+
+static unsigned short *
+UncompressStructure(struct compressed_block *bp, int count, int size)
+{
+ unsigned short *out = malloc(size);
+ unsigned short *op = out;
+ unsigned short data;
+ int i, j;
+
+ for (i=0; i<count; i++, bp++) {
+ data = bp->data;
+ for (j=0; j<bp->count; j++) {
+ *op++ = data;
+ if (bp->type == kTypeAscending) data++;
+ else if (bp->type == kTypeAscending256) data += 256;
+ }
+ }
+ return out;
+}
+
+static void
+InitCompareTables(void)
+{
+ if (gCompareTable == 0) {
+ gCompareTable = UncompressStructure(gCompareTableCompressed,
+ kCompareTableNBlocks, kCompareTableDataSize);
+ gLowerCaseTable = UncompressStructure(gLowerCaseTableCompressed,
+ kLowerCaseTableNBlocks, kLowerCaseTableDataSize);
+ }
+}
+
+#endif /* ! UNCOMPRESSED */
+