From e5c271bc0f8071e1c952b607111ecd8fb805587c Mon Sep 17 00:00:00 2001
From: yangfl <yangfl@users.noreply.github.com>
Date: Sat, 15 Jul 2023 12:24:10 +0800
Subject: [PATCH 2/3] Rewrite tests/Makefile

---
 tests/Makefile | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/tests/Makefile b/tests/Makefile
index 4e7b0561e14a..0b322bdf39b8 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -1,12 +1,13 @@
-CXX?=g++
-CXXFLAGS+=-Wall -std=c++14 `pkg-config --cflags gtest_main`
-LDFLAGS+=`pkg-config --libs gtest_main`
+PKG_CONFIG?=pkg-config
+
+CXXFLAGS+=-Wall -DSI_CONVERT_ICU -DSI_SUPPORT_IOSTREAMS
+LDFLAGS+=-lpthread -lgtest -lgtest_main -lpthread -lsimpleini $(shell $(PKG_CONFIG) --libs icu-io) -L.. -Wl,-rpath-link=$(pwd)
 
 OBJS=ts-roundtrip.o ts-snippets.o ts-utf8.o ts-bugfix.o ts-quotes.o ts-noconvert.o
 
 BIN=./tests
 
-all: $(BIN)
+all: test
 
 $(BIN): $(OBJS)
 	$(CXX) -o $(BIN) $(OBJS) $(LDFLAGS)
-- 
2.43.0

