mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-13 17:01:16 +00:00
ICU-157 udata updates..
X-SVN-Rev: 297
This commit is contained in:
parent
a34482e43f
commit
c0908dcdb4
4 changed files with 243 additions and 0 deletions
120
icu4c/source/tools/gentz/Makefile.in
Normal file
120
icu4c/source/tools/gentz/Makefile.in
Normal file
|
@ -0,0 +1,120 @@
|
|||
## Makefile.in for ICU - tools/gentz
|
||||
## Steven R. Loomi
|
||||
|
||||
## Shell to use
|
||||
SHELL = @SHELL@
|
||||
VERSION = @VERSION@
|
||||
|
||||
ICUDATADIR=$(top_builddir)/../data/
|
||||
TZFILE=tz.txt
|
||||
|
||||
## Install directory information
|
||||
srcdir = @srcdir@
|
||||
top_srcdir = @top_srcdir@
|
||||
prefix = @prefix@
|
||||
exec_prefix = @exec_prefix@
|
||||
|
||||
bindir = @bindir@
|
||||
sbindir = @sbindir@
|
||||
datadir = @datadir@
|
||||
libdir = @libdir@
|
||||
includedir = @includedir@
|
||||
|
||||
pkgdatadir = $(datadir)/@PACKAGE@
|
||||
pkglibdir = $(libdir)/@PACKAGE@
|
||||
pkgincludedir = $(includedir)/@PACKAGE@
|
||||
|
||||
## Install program information
|
||||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
|
||||
## Compiler/tools information
|
||||
CC = @CC@
|
||||
CXX = @CXX@
|
||||
PACKAGE = @PACKAGE@
|
||||
VERSION = @VERSION@
|
||||
|
||||
## Platform-specific setup
|
||||
@host_frag@
|
||||
|
||||
## Build directory information
|
||||
top_builddir = ../..
|
||||
subdir = tools/gentz
|
||||
|
||||
## Extra files to remove for 'make clean'
|
||||
CLEANFILES = *~
|
||||
|
||||
## Target information
|
||||
TARGET = gentz
|
||||
|
||||
DEFS = @DEFS@
|
||||
CPPFLAGS = @CPPFLAGS@ -I$(top_srcdir)/common -I$(top_srcdir)/i18n -I../toolutil
|
||||
CFLAGS = @CFLAGS@
|
||||
CXXFLAGS = @CXXFLAGS@
|
||||
LDFLAGS = @LDFLAGS@ \
|
||||
$(LD_RPATH)$(LD_RPATH_PRE)$(libdir)@ld_rpath_suf@$(LD_RPATH_PRE)$(top_builddir)/common@ld_rpath_suf@$(LD_RPATH_PRE)$(top_builddir)/tools/toolutil
|
||||
LIBS = $(LIBICU-UC) @LIBS@ @LIB_M@ -L$(top_builddir)/tools/toolutil -licu-toolutil
|
||||
|
||||
OBJECTS = gentz.o
|
||||
|
||||
DEPS = $(OBJECTS:.o=.d)
|
||||
|
||||
|
||||
## List of phony targets
|
||||
.PHONY : all all-local install install-local clean clean-local \
|
||||
distclean distclean-local target-clean-local dist dist-local check \
|
||||
check-local build-data
|
||||
|
||||
## Clear suffix list
|
||||
.SUFFIXES :
|
||||
|
||||
## List of standard targets
|
||||
all: all-local
|
||||
install: install-local
|
||||
clean: clean-local
|
||||
distclean : distclean-local
|
||||
dist: dist-local
|
||||
check: check-local
|
||||
|
||||
all-local: $(TARGET) build-data
|
||||
|
||||
install-local: target-clean-local all-local build-data
|
||||
$(mkinstalldirs) $(sbindir)
|
||||
$(INSTALL) $(TARGET) $(sbindir)/$(TARGET)
|
||||
|
||||
build-data: $(ICUDATADIR)/tz.dat
|
||||
|
||||
# we set the ICU_DATA directory here so that tz.dat ends up in
|
||||
# icu/data rather than PREFIX/share/icu/VERSION/
|
||||
$(ICUDATADIR)/tz.dat: $(TZFILE) $(TARGET)
|
||||
ICU_DATA=$(ICUDATADIR) ./$(TARGET) $(TZFILE) tz.dat
|
||||
|
||||
dist-local:
|
||||
|
||||
target-clean-local:
|
||||
rm -f $(TARGET)
|
||||
|
||||
clean-local: target-clean-local
|
||||
test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
|
||||
rm -f $(OBJECTS)
|
||||
|
||||
distclean-local: clean-local
|
||||
rm -f Makefile $(DEPS) $(RES_FILES) $(TEST_FILES)
|
||||
|
||||
check-local:
|
||||
|
||||
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
|
||||
cd $(top_builddir) \
|
||||
&& CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
|
||||
|
||||
$(TARGET) : $(OBJECTS)
|
||||
$(LINK.cc) -o $@ $^ $(LIBS)
|
||||
|
||||
ifneq ($(MAKECMDGOALS),distclean)
|
||||
-include $(DEPS)
|
||||
endif
|
||||
|
||||
|
51
icu4c/source/tools/makeconv/ucmfiles.mk
Normal file
51
icu4c/source/tools/makeconv/ucmfiles.mk
Normal file
|
@ -0,0 +1,51 @@
|
|||
# A list of UCM's to build
|
||||
# Note:
|
||||
#
|
||||
# If you are thinking of modifying this file, READ THIS.
|
||||
#
|
||||
# Instead of changing this file [unless you want to check it back in],
|
||||
# you should consider creating a 'ucmlocal.mk' file in this same directory.
|
||||
# Then, you can have your local changes remain even if you upgrade or re
|
||||
# configure the ICU.
|
||||
#
|
||||
# Example 'ucmlocal.mk' files:
|
||||
#
|
||||
# * To add an additional converter to the list:
|
||||
# _____________________________________________________
|
||||
# | UCM_SOURCE_LOCAL = myconverter.ucm ...
|
||||
#
|
||||
# * To REPLACE the default list and only build with a few
|
||||
# converters:
|
||||
# _____________________________________________________
|
||||
# | UCM_SOURCE = ibm-913.ucm ibm-949.ucm ibm-37.ucm
|
||||
#
|
||||
#
|
||||
|
||||
UCM_SOURCE = ibm-1038.ucm ibm-1047.ucm ibm-1089.ucm ibm-1123.ucm \
|
||||
ibm-1140.ucm ibm-1141.ucm ibm-1142.ucm ibm-1143.ucm ibm-1144.ucm \
|
||||
ibm-1145.ucm ibm-1146.ucm ibm-1147.ucm ibm-1148.ucm ibm-1149.ucm \
|
||||
ibm-1153.ucm ibm-1154.ucm ibm-1155.ucm ibm-1156.ucm ibm-1157.ucm \
|
||||
ibm-1158.ucm ibm-1159.ucm ibm-1160.ucm ibm-1164.ucm ibm-1252.ucm \
|
||||
ibm-12712.ucm ibm-1275.ucm ibm-1276.ucm ibm-1277.ucm ibm-1280.ucm \
|
||||
ibm-1281.ucm ibm-1282.ucm ibm-1283.ucm ibm-1361.ucm ibm-1362.ucm \
|
||||
ibm-1363.ucm ibm-1364.ucm ibm-1370.ucm ibm-1371.ucm ibm-1383.ucm \
|
||||
ibm-1386.ucm ibm-1390.ucm ibm-1399.ucm ibm-16684.ucm ibm-16804.ucm \
|
||||
ibm-17248.ucm ibm-21427.ucm ibm-420.ucm ibm-424.ucm ibm-437.ucm \
|
||||
ibm-4899.ucm ibm-4909.ucm ibm-4930.ucm ibm-4971.ucm ibm-5104.ucm \
|
||||
ibm-5123.ucm ibm-5210.ucm ibm-5346.ucm ibm-5347.ucm ibm-5349.ucm \
|
||||
ibm-5350.ucm ibm-5351.ucm ibm-5352.ucm ibm-5353.ucm ibm-5354.ucm \
|
||||
ibm-803.ucm ibm-808.ucm ibm-813.ucm ibm-834.ucm ibm-848.ucm \
|
||||
ibm-8482.ucm ibm-849.ucm ibm-852.ucm ibm-855.ucm ibm-856.ucm \
|
||||
ibm-857.ucm ibm-858.ucm ibm-859.ucm ibm-860.ucm ibm-861.ucm \
|
||||
ibm-863.ucm ibm-864.ucm ibm-865.ucm ibm-866.ucm ibm-867.ucm \
|
||||
ibm-868.ucm ibm-869.ucm ibm-872.ucm ibm-874.ucm ibm-878.ucm \
|
||||
ibm-901.ucm ibm-902.ucm ibm-9027.ucm ibm-9044.ucm ibm-9049.ucm \
|
||||
ibm-9061.ucm ibm-912.ucm ibm-913.ucm ibm-914.ucm ibm-915.ucm \
|
||||
ibm-916.ucm ibm-920.ucm ibm-921.ucm ibm-922.ucm ibm-923.ucm \
|
||||
ibm-9238.ucm ibm-924.ucm ibm-933.ucm ibm-935.ucm ibm-942.ucm \
|
||||
ibm-943.ucm ibm-949.ucm ibm-970.ucm ibm-1258.ucm ibm-273.ucm \
|
||||
ibm-277.ucm ibm-278.ucm ibm-280.ucm ibm-284.ucm ibm-285.ucm \
|
||||
ibm-297.ucm ibm-37.ucm ibm-500.ucm ibm-871.ucm ibm-937.ucm \
|
||||
ibm-930.ucm ibm-1257.ucm ibm-1256.ucm ibm-1255.ucm ibm-1254.ucm ibm-1253.ucm ibm-1251.ucm \
|
||||
ibm-1250.ucm ibm-862.ucm ibm-850.ucm ibm-950.ucm
|
||||
|
45
icu4c/source/tools/toolutil/ucmpwrit.c
Normal file
45
icu4c/source/tools/toolutil/ucmpwrit.c
Normal file
|
@ -0,0 +1,45 @@
|
|||
#include "ucmpwrit.h"
|
||||
#include <stdio.h>
|
||||
|
||||
U_CAPI void U_EXPORT2 udata_write_ucmp8 (UNewDataMemory *pData, const CompactByteArray* array)
|
||||
{
|
||||
udata_writeBlock(pData, array, sizeof(*array));
|
||||
udata_writeBlock(pData, array->fArray, sizeof(array->fArray[0])*array->fCount);
|
||||
udata_writeBlock(pData, array->fIndex, sizeof(array->fIndex[0])*UCMP8_kIndexCount);
|
||||
}
|
||||
|
||||
/* internal constants*/
|
||||
#define UCMP16_kMaxUnicode_int 65535
|
||||
#define UCMP16_kUnicodeCount_int (UCMP16_kMaxUnicode_int + 1)
|
||||
#define UCMP16_kBlockShift_int 7
|
||||
#define UCMP16_kBlockCount_int (1 << UCMP16_kBlockShift_int)
|
||||
#define UCMP16_kBlockBytes_int (UCMP16_kBlockCount_int * sizeof(int16_t))
|
||||
#define UCMP16_kIndexShift_int (16 - UCMP16_kBlockShift_int)
|
||||
#define UCMP16_kIndexCount_int (1 << UCMP16_kIndexShift_int)
|
||||
#define UCMP16_kBlockMask_int (UCMP16_kBlockCount_int - 1)
|
||||
|
||||
|
||||
const int32_t UCMP16_kMaxUnicode = UCMP16_kMaxUnicode_int;
|
||||
const int32_t UCMP16_kUnicodeCount = UCMP16_kUnicodeCount_int;
|
||||
const int32_t UCMP16_kBlockShift = UCMP16_kBlockShift_int;
|
||||
const int32_t UCMP16_kBlockCount = UCMP16_kBlockCount_int;
|
||||
const int32_t UCMP16_kBlockBytes = UCMP16_kBlockBytes_int;
|
||||
const int32_t UCMP16_kIndexShift = UCMP16_kIndexShift_int;
|
||||
const int32_t UCMP16_kIndexCount = UCMP16_kIndexCount_int;
|
||||
const uint32_t UCMP16_kBlockMask = UCMP16_kBlockMask_int;
|
||||
|
||||
|
||||
U_CAPI void U_EXPORT2 udata_write_ucmp16 (UNewDataMemory *pData, const CompactShortArray* array)
|
||||
{
|
||||
udata_writeBlock(pData, array, sizeof(*array));
|
||||
udata_writeBlock(pData, array->fArray, sizeof(array->fArray[0])*array->fCount);
|
||||
udata_writeBlock(pData, array->fIndex, sizeof(array->fIndex[0])*UCMP16_kIndexCount);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
27
icu4c/source/tools/toolutil/ucmpwrit.h
Normal file
27
icu4c/source/tools/toolutil/ucmpwrit.h
Normal file
|
@ -0,0 +1,27 @@
|
|||
/****************************************
|
||||
* Copyright (C) 1999 IBM, Inc. and Others.
|
||||
****************************************/
|
||||
|
||||
/**
|
||||
API's for writing UCMPs
|
||||
*/
|
||||
|
||||
#ifndef _UCMPWRIT
|
||||
#define _UCMPWRIT
|
||||
|
||||
#include "utypes.h"
|
||||
#include "unewdata.h"
|
||||
|
||||
#include "ucmp8.h"
|
||||
#include "ucmp16.h"
|
||||
#include "ucmp32.h"
|
||||
|
||||
U_CAPI void U_EXPORT2 udata_write_ucmp8 (UNewDataMemory *pData, const CompactByteArray* array);
|
||||
|
||||
U_CAPI void U_EXPORT2 udata_write_ucmp16(UNewDataMemory *pData, const CompactShortArray* array);
|
||||
|
||||
/*Not implemented. [yet] */
|
||||
/*U_CAPI void U_EXPORT2 udata_write_ucmp32(UNewDataMemory *pData, const CompactIntArray* array);*/
|
||||
|
||||
|
||||
#endif
|
Loading…
Add table
Reference in a new issue