From 6d7adf0f043ff2591203f80da6bc4d4774be5b49 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Mon, 27 Feb 2017 14:03:54 +0100 Subject: [PATCH] Add a patch for icu4c on android 64 bits. On recent version of the NDK (r13b), `exec_elf.h` has been removed for API level >= 20. On 64 bits, we need the API level 21, and then, a defined (ELF64_ST_INFO) is missing. We readd it where (and if) we need it. --- dependencies.py | 3 ++- patches/icu4c_android_elf64_st_info.patch | 13 +++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 patches/icu4c_android_elf64_st_info.patch diff --git a/dependencies.py b/dependencies.py index fcd87a7..d9140c7 100644 --- a/dependencies.py +++ b/dependencies.py @@ -177,7 +177,8 @@ class Icu(Dependency): class Source(ReleaseDownload): archive = Remotefile('icu4c-56_1-src.tgz', '3a64e9105c734dcf631c0b3ed60404531bce6c0f5a64bfe1a6402a4cc2314816') - patches = ["icu4c_fix_static_lib_name_mingw.patch"] + patches = ["icu4c_fix_static_lib_name_mingw.patch", + "icu4c_android_elf64_st_info.patch"] data = Remotefile('icudt56l.dat', 'e23d85eee008f335fc49e8ef37b1bc2b222db105476111e3d16f0007d371cbca') diff --git a/patches/icu4c_android_elf64_st_info.patch b/patches/icu4c_android_elf64_st_info.patch new file mode 100644 index 0000000..12e901f --- /dev/null +++ b/patches/icu4c_android_elf64_st_info.patch @@ -0,0 +1,13 @@ +diff -ur icu4c-58_2/source/tools/toolutil/pkg_genc.c icu4c-58_2.patched/source/tools/toolutil/pkg_genc.c +--- icu4c-58_2/source/tools/toolutil/pkg_genc.c 2016-06-15 20:58:17.000000000 +0200 ++++ icu4c-58_2.patched/source/tools/toolutil/pkg_genc.c 2017-02-27 10:23:39.985471339 +0100 +@@ -35,6 +35,9 @@ + # define EM_X86_64 62 + # endif + # define ICU_ENTRY_OFFSET 0 ++# ifndef ELF64_ST_INFO ++# define ELF64_ST_INFO(b,t) (((b) << 4) + ((t) & 0xf)) ++# endif + #endif + + #include