fix: Enable CGO for SQLite3 database support
- Set CGO_ENABLED=1 in Makefile for all build targets - Set CGO_ENABLED=1 in Debian build script - Resolves "go-sqlite3 requires cgo to work" runtime error - Ensures proper SQLite3 database functionality 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
779384b748
commit
66a6b5b9a2
2 changed files with 4 additions and 4 deletions
6
Makefile
6
Makefile
|
|
@ -9,19 +9,19 @@ LDFLAGS=-w -s -X main.version=$(VERSION)
|
||||||
build:
|
build:
|
||||||
@echo "Building skyview..."
|
@echo "Building skyview..."
|
||||||
@mkdir -p $(BUILD_DIR)
|
@mkdir -p $(BUILD_DIR)
|
||||||
go build -ldflags="$(LDFLAGS)" -o $(BUILD_DIR)/skyview ./cmd/skyview
|
CGO_ENABLED=1 go build -ldflags="$(LDFLAGS)" -o $(BUILD_DIR)/skyview ./cmd/skyview
|
||||||
|
|
||||||
# Build beast-dump utility binary
|
# Build beast-dump utility binary
|
||||||
build-beast-dump:
|
build-beast-dump:
|
||||||
@echo "Building beast-dump..."
|
@echo "Building beast-dump..."
|
||||||
@mkdir -p $(BUILD_DIR)
|
@mkdir -p $(BUILD_DIR)
|
||||||
go build -ldflags="$(LDFLAGS)" -o $(BUILD_DIR)/beast-dump ./cmd/beast-dump
|
CGO_ENABLED=1 go build -ldflags="$(LDFLAGS)" -o $(BUILD_DIR)/beast-dump ./cmd/beast-dump
|
||||||
|
|
||||||
# Build skyview-data database management binary
|
# Build skyview-data database management binary
|
||||||
build-skyview-data:
|
build-skyview-data:
|
||||||
@echo "Building skyview-data..."
|
@echo "Building skyview-data..."
|
||||||
@mkdir -p $(BUILD_DIR)
|
@mkdir -p $(BUILD_DIR)
|
||||||
go build -ldflags="$(LDFLAGS)" -o $(BUILD_DIR)/skyview-data ./cmd/skyview-data
|
CGO_ENABLED=1 go build -ldflags="$(LDFLAGS)" -o $(BUILD_DIR)/skyview-data ./cmd/skyview-data
|
||||||
|
|
||||||
# Build all binaries
|
# Build all binaries
|
||||||
build-all: build build-beast-dump build-skyview-data
|
build-all: build build-beast-dump build-skyview-data
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@ cd "$PROJECT_DIR"
|
||||||
|
|
||||||
# Build the applications
|
# Build the applications
|
||||||
echo_info "Building SkyView applications..."
|
echo_info "Building SkyView applications..."
|
||||||
export CGO_ENABLED=0
|
export CGO_ENABLED=1
|
||||||
export GOOS=linux
|
export GOOS=linux
|
||||||
export GOARCH=amd64
|
export GOARCH=amd64
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue