Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | /****************************************************************************** |
michael@0 | 2 | * |
michael@0 | 3 | * Copyright (C) 2001, International Business Machines |
michael@0 | 4 | * Corporation and others. All Rights Reserved. |
michael@0 | 5 | * |
michael@0 | 6 | ******************************************************************************* |
michael@0 | 7 | * file name: stubdata.c |
michael@0 | 8 | * |
michael@0 | 9 | * Define initialized data that will build into a valid, but empty |
michael@0 | 10 | * ICU data library. Used to bootstrap the ICU build, which has these |
michael@0 | 11 | * dependencies: |
michael@0 | 12 | * ICU Common library depends on ICU data |
michael@0 | 13 | * ICU data requires data building tools. |
michael@0 | 14 | * ICU data building tools require the ICU common library. |
michael@0 | 15 | * |
michael@0 | 16 | * The stub data library (for which this file is the source) is sufficient |
michael@0 | 17 | * for running the data building tools. |
michael@0 | 18 | * |
michael@0 | 19 | */ |
michael@0 | 20 | #include "unicode/utypes.h" |
michael@0 | 21 | #include "unicode/udata.h" |
michael@0 | 22 | #include "unicode/uversion.h" |
michael@0 | 23 | |
michael@0 | 24 | |
michael@0 | 25 | typedef struct { |
michael@0 | 26 | uint16_t headerSize; |
michael@0 | 27 | uint8_t magic1, magic2; |
michael@0 | 28 | UDataInfo info; |
michael@0 | 29 | char padding[8]; |
michael@0 | 30 | uint32_t count, reserved; |
michael@0 | 31 | /* |
michael@0 | 32 | const struct { |
michael@0 | 33 | const char *const name; |
michael@0 | 34 | const void *const data; |
michael@0 | 35 | } toc[1]; |
michael@0 | 36 | */ |
michael@0 | 37 | int fakeNameAndData[4]; /* TODO: Change this header type from */ |
michael@0 | 38 | /* pointerTOC to OffsetTOC. */ |
michael@0 | 39 | } ICU_Data_Header; |
michael@0 | 40 | |
michael@0 | 41 | U_EXPORT const ICU_Data_Header U_ICUDATA_ENTRY_POINT = { |
michael@0 | 42 | 32, /* headerSize */ |
michael@0 | 43 | 0xda, /* magic1, (see struct MappedData in udata.c) */ |
michael@0 | 44 | 0x27, /* magic2 */ |
michael@0 | 45 | { /*UDataInfo */ |
michael@0 | 46 | sizeof(UDataInfo), /* size */ |
michael@0 | 47 | 0, /* reserved */ |
michael@0 | 48 | |
michael@0 | 49 | #if U_IS_BIG_ENDIAN |
michael@0 | 50 | 1, |
michael@0 | 51 | #else |
michael@0 | 52 | 0, |
michael@0 | 53 | #endif |
michael@0 | 54 | |
michael@0 | 55 | U_CHARSET_FAMILY, |
michael@0 | 56 | sizeof(UChar), |
michael@0 | 57 | 0, /* reserved */ |
michael@0 | 58 | { /* data format identifier */ |
michael@0 | 59 | 0x54, 0x6f, 0x43, 0x50}, /* "ToCP" */ |
michael@0 | 60 | {1, 0, 0, 0}, /* format version major, minor, milli, micro */ |
michael@0 | 61 | {0, 0, 0, 0} /* dataVersion */ |
michael@0 | 62 | }, |
michael@0 | 63 | {0,0,0,0,0,0,0,0}, /* Padding[8] */ |
michael@0 | 64 | 0, /* count */ |
michael@0 | 65 | 0, /* Reserved */ |
michael@0 | 66 | { /* TOC structure */ |
michael@0 | 67 | /* { */ |
michael@0 | 68 | 0 , 0 , 0, 0 /* name and data entries. Count says there are none, */ |
michael@0 | 69 | /* but put one in just in case. */ |
michael@0 | 70 | /* } */ |
michael@0 | 71 | } |
michael@0 | 72 | }; |
michael@0 | 73 | |
michael@0 | 74 |