Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f1c2fb3

Browse filesBrowse files
srl295MylesBorins
authored andcommitted
doc: document and warn if the ICU version is too old
Fixes: #19657 PR-URL: #23766 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Ujjwal Sharma <usharma1998@gmail.com>
1 parent 2e3e68a commit f1c2fb3
Copy full SHA for f1c2fb3

File tree

Expand file treeCollapse file tree

3 files changed

+15
-1
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

3 files changed

+15
-1
lines changed
Open diff view settings
Collapse file

‎BUILDING.md‎

Copy file name to clipboardExpand all lines: BUILDING.md
+4Lines changed: 4 additions & 0 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -444,6 +444,10 @@ You can find other ICU releases at
444444
Download the file named something like `icu4c-**##.#**-src.tgz` (or
445445
`.zip`).
446446

447+
To check the minimum recommended ICU, run `./configure --help` and see
448+
the help for the `--with-icu-source` option. A warning will be printed
449+
during configuration if the ICU version is too old.
450+
447451
##### Unix/macOS
448452

449453
From an already-unpacked ICU:
Collapse file

‎configure.py‎

Copy file name to clipboardExpand all lines: configure.py
+8-1Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@
5151
valid_mips_fpu = ('fp32', 'fp64', 'fpxx')
5252
valid_mips_float_abi = ('soft', 'hard')
5353
valid_intl_modes = ('none', 'small-icu', 'full-icu', 'system-icu')
54+
with open ('tools/icu/icu_versions.json') as f:
55+
icu_versions = json.load(f)
5456

5557
# create option groups
5658
shared_optgroup = optparse.OptionGroup(parser, "Shared libraries",
@@ -425,7 +427,9 @@
425427
intl_optgroup.add_option('--with-icu-source',
426428
action='store',
427429
dest='with_icu_source',
428-
help='Intl mode: optional local path to icu/ dir, or path/URL of icu source archive.')
430+
help='Intl mode: optional local path to icu/ dir, or path/URL of '
431+
'the icu4c source archive. '
432+
'v%d.x or later recommended.' % icu_versions["minimum_icu"])
429433

430434
parser.add_option('--with-ltcg',
431435
action='store_true',
@@ -1470,6 +1474,9 @@ def write_config(data, name):
14701474
icu_ver_major = m.group(1)
14711475
if not icu_ver_major:
14721476
error('Could not read U_ICU_VERSION_SHORT version from %s' % uvernum_h)
1477+
elif int(icu_ver_major) < icu_versions["minimum_icu"]:
1478+
error('icu4c v%d.x is too old, v%d.x or later is required.' % (int(icu_ver_major),
1479+
icu_versions["minimum_icu"]))
14731480
icu_endianness = sys.byteorder[0];
14741481
o['variables']['icu_ver_major'] = icu_ver_major
14751482
o['variables']['icu_endianness'] = icu_endianness
Collapse file

‎tools/icu/icu_versions.json‎

Copy file name to clipboard
+3Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"minimum_icu": 57
3+
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.