From 3e6659d64a22fe664d72f9eb83310f697ff27a94 Mon Sep 17 00:00:00 2001 From: ax_rd <ax_rd@aisim.cn> Date: Thu, 03 Sep 2026 11:40:07 +0800 Subject: [PATCH] feat: 悬空双链自动补全(RetryUnresolved,Reconcile 末尾自动调用)+ 3 个 Task3 审查 Minor 修复 --- Makefile | 20 ++++++++++++-------- 1 files changed, 12 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index 31dd685..f0daa47 100644 --- a/Makefile +++ b/Makefile @@ -1,20 +1,24 @@ -.PHONY: build test clean install +# Makefile +CGO_CFLAGS := -DSQLITE_ENABLE_FTS5 +CGO_LDFLAGS := -lm + +.PHONY: build test clean install test-v run-search run-index run-status # 构建 build: - CGO_ENABLED=1 go build -tags fts5 -o bin/kb . + CGO_CFLAGS="$(CGO_CFLAGS)" CGO_LDFLAGS="$(CGO_LDFLAGS)" go build -o bin/kb-cli . # 安装到 ~/go/bin install: - CGO_ENABLED=1 go install -tags fts5 . + CGO_CFLAGS="$(CGO_CFLAGS)" CGO_LDFLAGS="$(CGO_LDFLAGS)" go install . # 测试 test: - CGO_ENABLED=1 go test -tags fts5 ./... + CGO_CFLAGS="$(CGO_CFLAGS)" CGO_LDFLAGS="$(CGO_LDFLAGS)" go test ./... 2>&1 | grep -v "no test files" # 详细测试 test-v: - CGO_ENABLED=1 go test -tags fts5 -v ./... + CGO_CFLAGS="$(CGO_CFLAGS)" CGO_LDFLAGS="$(CGO_LDFLAGS)" go test -v ./... 2>&1 | grep -v "no test files" # 清理 clean: @@ -23,10 +27,10 @@ # 运行示例 run-search: - ./bin/kb search 充装 --top 5 + ./bin/kb-cli search 充装 --top 5 run-index: - ./bin/kb index build + ./bin/kb-cli index build run-status: - ./bin/kb index status + ./bin/kb-cli index status -- Gitblit v1.10.0