Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:hammer: Update build scripts

Daniel971bfb4786de
diff --git a/Dockerfile b/Dockerfile
index 6b176f34da..175a7fbfc6 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -37,7 +37,7 @@ RUN --mount=type=cache,target=/root/.cache/go-build --mount=type=cache,target=/g
ADD kernel/ .
RUN --mount=type=cache,target=/root/.cache/go-build --mount=type=cache,target=/go/pkg \
- go build -tags fts5 -v -ldflags "-s -w"
+ go build -tags fts5 -ldflags "-s -w"
FROM alpine:latest
LABEL maintainer="Liang Ding<[email protected]>"
diff --git a/kernel/harmony/build-win.sh b/kernel/harmony/build-win.sh
index d8b9683589..a8d6008516 100755
--- a/kernel/harmony/build-win.sh
+++ b/kernel/harmony/build-win.sh
@@ -24,4 +24,4 @@ export GOARCH=amd64
export CGO_CFLAGS="-I${LOG_ADAPTOR_HOME}/include -g -O2 `$LLVMCONFIG --cflags` --target=x86_64-linux-ohos --sysroot=$OHOS_NDK_HOME/native/sysroot"
export CGO_LDFLAGS="--target=x86_64-linux-ohos -fuse-ld=lld -L${LOG_ADAPTOR_HOME}/dist/x86_64"
-go build -tags fts5 -ldflags "-s -w" -buildmode=c-shared -v -o libkernel.so .
+go build -tags fts5 -ldflags "-s -w" -buildmode=c-shared -o libkernel.so .
diff --git a/kernel/harmony/build.sh b/kernel/harmony/build.sh
index c4b26c2e87..6893e3f250 100755
--- a/kernel/harmony/build.sh
+++ b/kernel/harmony/build.sh
@@ -24,5 +24,5 @@ export GOARCH=arm64
export CGO_CFLAGS="-I${LOG_ADAPTOR_HOME}/include -g -O2 `$LLVMCONFIG --cflags` --target=aarch64-linux-ohos --sysroot=$OHOS_NDK_HOME/native/sysroot"
export CGO_LDFLAGS="--target=aarch64-linux-ohos -fuse-ld=lld -L${LOG_ADAPTOR_HOME}/dist/arm64-v8a"
-go build -tags fts5 -ldflags "-s -w" -buildmode=c-shared -v -o libkernel.so .
-#go build -tags fts5 -buildmode=c-shared -v -o libkernel.so .
+go build -tags fts5 -ldflags "-s -w" -buildmode=c-shared -o libkernel.so .
+#go build -tags fts5 -buildmode=c-shared -o libkernel.so .
diff --git a/scripts/darwin-build.sh b/scripts/darwin-build.sh
index 1de95e9e1e..4577a4920e 100755
--- a/scripts/darwin-build.sh
+++ b/scripts/darwin-build.sh
@@ -70,13 +70,13 @@ if [[ "$TARGET" == 'amd64' || "$TARGET" == 'all' ]]; then
echo
echo 'Building Kernel amd64'
export GOARCH=amd64
- go build -tags fts5 -v -o "../app/kernel-darwin/SiYuan-Kernel" -ldflags "-s -w" .
+ go build -tags fts5 -o "../app/kernel-darwin/SiYuan-Kernel" -ldflags "-s -w" .
fi
if [[ "$TARGET" == 'arm64' || "$TARGET" == 'all' ]]; then
echo
echo 'Building Kernel arm64'
export GOARCH=arm64
- go build -tags fts5 -v -o "../app/kernel-darwin-arm64/SiYuan-Kernel" -ldflags "-s -w" .
+ go build -tags fts5 -o "../app/kernel-darwin-arm64/SiYuan-Kernel" -ldflags "-s -w" .
fi
echo
diff --git a/scripts/linux-build.sh b/scripts/linux-build.sh
index 4ea89bb9b4..94327f08e9 100755
--- a/scripts/linux-build.sh
+++ b/scripts/linux-build.sh
@@ -105,14 +105,14 @@ if [[ "$TARGET" == 'amd64' || "$TARGET" == 'all' ]]; then
echo 'Building Kernel amd64'
export GOARCH=amd64
setup_cc amd64
- go build -buildmode=pie -tags fts5 -v -o "../app/kernel-linux/SiYuan-Kernel" -ldflags "-s -w -extldflags -static-pie" .
+ go build -buildmode=pie -tags fts5 -o "../app/kernel-linux/SiYuan-Kernel" -ldflags "-s -w -extldflags -static-pie" .
fi
if [[ "$TARGET" == 'arm64' || "$TARGET" == 'all' ]]; then
echo
echo 'Building Kernel arm64'
export GOARCH=arm64
setup_cc arm64
- go build -buildmode=pie -tags fts5 -v -o "../app/kernel-linux-arm64/SiYuan-Kernel" -ldflags "-s -w -extldflags -static-pie" .
+ go build -buildmode=pie -tags fts5 -o "../app/kernel-linux-arm64/SiYuan-Kernel" -ldflags "-s -w -extldflags -static-pie" .
fi
echo
diff --git a/scripts/win-build.bat b/scripts/win-build.bat
index 402ce86983..c05c3dcad4 100755
--- a/scripts/win-build.bat
+++ b/scripts/win-build.bat
@@ -101,7 +101,7 @@ if defined BUILD_AMD64 (
echo.
echo Building Kernel amd64
set GOARCH=amd64
- go build -tags fts5 -v -o "%PROJECT_ROOT%\app\kernel\SiYuan-Kernel.exe" -ldflags "-s -w -H=windowsgui" .
+ go build -tags fts5 -o "%PROJECT_ROOT%\app\kernel\SiYuan-Kernel.exe" -ldflags "-s -w -H=windowsgui" .
if errorlevel 1 (
exit /b %errorlevel%
)
@@ -112,7 +112,7 @@ if defined BUILD_ARM64 (
set GOARCH=arm64
@REM if you want to build arm64, you need to install aarch64-w64-mingw32-gcc
set CC="D:/Program Files/llvm-mingw-20240518-ucrt-x86_64/bin/aarch64-w64-mingw32-gcc.exe"
- go build -tags fts5 -v -o "%PROJECT_ROOT%\app\kernel-arm64\SiYuan-Kernel.exe" -ldflags "-s -w -H=windowsgui" .
+ go build -tags fts5 -o "%PROJECT_ROOT%\app\kernel-arm64\SiYuan-Kernel.exe" -ldflags "-s -w -H=windowsgui" .
if errorlevel 1 (
exit /b %errorlevel%
)