55 lines
1.5 KiB
TOML
55 lines
1.5 KiB
TOML
#TODO: ICU 75.1 — Unicode and internationalization (BiDi, character properties).
|
|
# Two-step cross-build: host-native build for data tools, then cross-compile.
|
|
# Static-only build; cmake find_package(ICU) works with static libs via ICU_USE_STATIC.
|
|
# Required by konsole for bidirectional text rendering.
|
|
[source]
|
|
tar = "https://github.com/unicode-org/icu/releases/download/release-75-1/icu4c-75_1-src.tgz"
|
|
|
|
[build]
|
|
template = "custom"
|
|
script = """
|
|
DYNAMIC_INIT
|
|
|
|
ICU_SRC="${COOKBOOK_SOURCE}/source"
|
|
ICU_HOST_BUILD="${COOKBOOK_RECIPE}/target/icu-host"
|
|
|
|
mkdir -p "${ICU_HOST_BUILD}"
|
|
cd "${ICU_HOST_BUILD}"
|
|
|
|
CC=gcc CXX=g++ "${ICU_SRC}/configure" \
|
|
--prefix="${ICU_HOST_BUILD}/install" \
|
|
--disable-tests \
|
|
--disable-samples \
|
|
--disable-extras \
|
|
--disable-docs \
|
|
--enable-static \
|
|
--disable-shared
|
|
|
|
make -j"${COOKBOOK_MAKE_JOBS}"
|
|
make install
|
|
|
|
cd "${COOKBOOK_BUILD}"
|
|
|
|
ln -sf mh-linux "${ICU_SRC}/config/mh-unknown"
|
|
|
|
"${ICU_SRC}/configure" \
|
|
--host="${GNU_TARGET}" \
|
|
--prefix=/usr \
|
|
--with-cross-build="${ICU_HOST_BUILD}" \
|
|
--disable-tests \
|
|
--disable-samples \
|
|
--disable-extras \
|
|
--disable-docs \
|
|
--enable-static \
|
|
--disable-shared \
|
|
--with-data-packaging=static \
|
|
CFLAGS="-DU_HAVE_CHAR16_T=0 -Wno-deprecated-declarations" \
|
|
CXXFLAGS="-DU_HAVE_CHAR16_T=0 -Wno-deprecated-declarations" \
|
|
icu_cv_host_frag=mh-linux
|
|
|
|
make -j"${COOKBOOK_MAKE_JOBS}"
|
|
make install DESTDIR="${COOKBOOK_STAGE}"
|
|
|
|
mkdir -p "${COOKBOOK_STAGE}/usr/lib/pkgconfig"
|
|
"""
|