From f0f3d6d4eb7f7de92fe56aae235b62864c6e8a42 Mon Sep 17 00:00:00 2001 From: Jarred SUmner Date: Mon, 4 Oct 2021 20:41:27 -0700 Subject: [PATCH] Statically link libicu on Linux so it doesn't require installing icu separately. this doubles the binary size :( --- Makefile | 7 ++++++- build-id | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index aa33f1978f..ad36a7417f 100644 --- a/Makefile +++ b/Makefile @@ -298,9 +298,14 @@ MACOS_ICU_INCLUDE := $(HOMEBREW_PREFIX)opt/icu4c/include ICU_FLAGS := +# TODO: find a way to make this more resilient +# Ideally, we could just look up the linker search paths +LIB_ICU_PATH ?= /usr/lib/x86_64-linux-gnu + ifeq ($(OS_NAME),linux) - ICU_FLAGS += -licuuc -licudata -licui18n + ICU_FLAGS += $(LIB_ICU_PATH)/libicuuc.a $(LIB_ICU_PATH)/libicudata.a $(LIB_ICU_PATH)/libicui18n.a endif + ifeq ($(OS_NAME),darwin) ICU_FLAGS += -l icucore \ $(MACOS_ICU_FILES) \ diff --git a/build-id b/build-id index e85087affd..f5c89552bd 100644 --- a/build-id +++ b/build-id @@ -1 +1 @@ -31 +32