From: Adam Dickmeiss Date: Thu, 8 Nov 2007 13:35:36 +0000 (+0000) Subject: Update for locale API changes. X-Git-Tag: ZEBRA.2.0.20~72 X-Git-Url: http://git.indexdata.com/?p=idzebra-moved-to-github.git;a=commitdiff_plain;h=03cd7d7f298324b3cc7185de7e9c65eab79c5048 Update for locale API changes. --- diff --git a/test/api/t17.idx b/test/api/t17.idx index 20efd8c..6159a15 100644 --- a/test/api/t17.idx +++ b/test/api/t17.idx @@ -1,5 +1,5 @@ # Zebra indexes as referred to from the *.abs-files. -# $Id: t17.idx,v 1.2 2007-11-07 10:24:28 adam Exp $ +# $Id: t17.idx,v 1.3 2007-11-08 13:35:36 adam Exp $ # # Traditional word index @@ -10,7 +10,6 @@ completeness 0 position 1 alwaysmatches 1 firstinfield 1 -locale en # simplechain dummy icuchain words-icu.xml diff --git a/util/zebramap.c b/util/zebramap.c index e87bb71..202806f 100644 --- a/util/zebramap.c +++ b/util/zebramap.c @@ -1,4 +1,4 @@ -/* $Id: zebramap.c,v 1.69 2007-11-08 09:30:05 adam Exp $ +/* $Id: zebramap.c,v 1.70 2007-11-08 13:35:36 adam Exp $ Copyright (C) 1995-2007 Index Data ApS @@ -54,7 +54,6 @@ struct zebra_map { } u; chrmaptab maptab; const char *maptab_name; - const char *locale; zebra_maps_t zebra_maps; #if YAZ_HAVE_XML2 xmlDocPtr doc; @@ -110,7 +109,6 @@ zebra_map_t zebra_add_map(zebra_maps_t zms, const char *index_type, zm->id = nmem_strdup(zms->nmem, index_type); zm->maptab_name = 0; zm->use_chain = 0; - zm->locale = 0; zm->maptab = 0; zm->type = map_type; zm->completeness = 0; @@ -218,10 +216,6 @@ static int parse_command(zebra_maps_t zms, int argc, char **argv, return -1; } } - else if (!yaz_matchstr(argv[0], "locale")) - { - zm->locale = nmem_strdup(zms->nmem, argv[1]); - } else if (!yaz_matchstr(argv[0], "simplechain")) { zm->use_chain = 1; @@ -232,12 +226,6 @@ static int parse_command(zebra_maps_t zms, int argc, char **argv, else if (!yaz_matchstr(argv[0], "icuchain")) { #if YAZ_HAVE_XML2 - if (!zm->locale) - { - yaz_log(YLOG_WARN, "%s:%d: locale required before icuchain", - fname, lineno); - return -1; - } zm->doc = xmlParseFile(argv[1]); if (!zm->doc) { @@ -251,7 +239,7 @@ static int parse_command(zebra_maps_t zms, int argc, char **argv, UErrorCode status; xmlNode *xml_node = xmlDocGetRootElement(zm->doc); zm->icu_chain = - icu_chain_xml_config(xml_node, zm->locale, + icu_chain_xml_config(xml_node, /* not sure about sort for this function yet.. */ #if 1 1,