|
@@ -41,7 +41,7 @@ build_prepare:
|
|
|
build_without_edgex: build_prepare
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -o kuiper cmd/kuiper/main.go
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -trimpath -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -o kuiperd cmd/kuiperd/main.go
|
|
|
- @if [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
+ @if [ "$$(uname -s)" = "Linux" ] && [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
@mv ./kuiper ./kuiperd $(BUILD_PATH)/$(PACKAGE_NAME)/bin
|
|
|
@echo "Build successfully"
|
|
|
|
|
@@ -53,7 +53,7 @@ pkg_without_edgex: build_without_edgex
|
|
|
build_with_edgex: build_prepare
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -tags "edgex include_nats_messaging" -o kuiper cmd/kuiper/main.go
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -trimpath -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -tags "edgex include_nats_messaging" -o kuiperd cmd/kuiperd/main.go
|
|
|
- @if [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
+ @if [ "$$(uname -s)" = "Linux" ] && [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
@mv ./kuiper ./kuiperd $(BUILD_PATH)/$(PACKAGE_NAME)/bin
|
|
|
@echo "Build successfully"
|
|
|
|
|
@@ -61,7 +61,7 @@ build_with_edgex: build_prepare
|
|
|
build_with_edgex_and_script: build_prepare
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -tags "edgex include_nats_messaging" -o kuiper cmd/kuiper/main.go
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -trimpath -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -tags "edgex include_nats_messaging script" -o kuiperd cmd/kuiperd/main.go
|
|
|
- @if [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
+ @if [ "$$(uname -s)" = "Linux" ] && [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
@mv ./kuiper ./kuiperd $(BUILD_PATH)/$(PACKAGE_NAME)/bin
|
|
|
@echo "Build successfully"
|
|
|
|
|
@@ -72,7 +72,7 @@ pkg_with_edgex: build_with_edgex
|
|
|
.PHONY: build_core
|
|
|
build_core: build_prepare
|
|
|
GO111MODULE=on CGO_ENABLED=0 go build -trimpath -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -tags core -o kuiperd cmd/kuiperd/main.go
|
|
|
- @if [ ! -z $$(which upx) ]; then upx ./kuiperd; fi
|
|
|
+ @if [ "$$(uname -s)" = "Linux" ] && [ ! -z $$(which upx) ]; then upx ./kuiperd; fi
|
|
|
@mv ./kuiperd $(BUILD_PATH)/$(PACKAGE_NAME)/bin
|
|
|
@echo "Build successfully"
|
|
|
|
|
@@ -96,7 +96,7 @@ real_pkg:
|
|
|
build_with_wasm: build_prepare
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -o kuiper cmd/kuiper/main.go
|
|
|
GO111MODULE=on CGO_ENABLED=1 go build -trimpath -ldflags="-s -w -X main.Version=$(VERSION) -X main.LoadFileType=relative" -tags "wasmedge" -o kuiperd cmd/kuiperd/main.go
|
|
|
- @if [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
+ @if [ "$$(uname -s)" = "Linux" ] && [ ! -z $$(which upx) ]; then upx ./kuiper; upx ./kuiperd; fi
|
|
|
@mv ./kuiper ./kuiperd $(BUILD_PATH)/$(PACKAGE_NAME)/bin
|
|
|
@echo "Build successfully"
|
|
|
|