Skip to content

Commit

Permalink
Revert "Merge pull request #105 from aws/dev"
Browse files Browse the repository at this point in the history
This reverts commit 13a9b8d, reversing
changes made to a04bd6e.
  • Loading branch information
fierlion committed Feb 16, 2023
1 parent 13a9b8d commit 515943c
Showing 1 changed file with 3 additions and 13 deletions.
16 changes: 3 additions & 13 deletions Makefile
Expand Up @@ -6,7 +6,6 @@ LOCAL_IPAM_PLUGIN_BINARY=bin/plugins/ecs-ipam
LOCAL_BRIDGE_PLUGIN_BINARY=bin/plugins/ecs-bridge
VERSION=$(shell cat $(ROOT)/VERSION)
GO_EXECUTABLE=$(shell command -v go 2> /dev/null)
GO_VERSION=`go version | cut -d' ' -f3 | cut -c 3-`

# We want to embed some git details in the build. We support pulling
# these details from the environment in order support builds outside
Expand All @@ -26,15 +25,6 @@ ifeq ($(strip $(GIT_PORCELAIN)),)
GIT_PORCELAIN=1
endif

# buildvcs=false excludes version control information in golang >= 1.18.
# This is required for compiling agent with included repositories
ifeq ($(shell expr $(GO_VERSION) \>= 1.18), 1)
BUILD_VCS := -buildvcs=false
else
# leaving BUILD_VCS empty as it is not required for golang < 1.18.
BUILD_VCS :=
endif

.PHONY: get-deps

get-deps:
Expand All @@ -47,23 +37,23 @@ get-deps:
plugins: $(LOCAL_ENI_PLUGIN_BINARY) $(LOCAL_IPAM_PLUGIN_BINARY) $(LOCAL_BRIDGE_PLUGIN_BINARY)

$(LOCAL_ENI_PLUGIN_BINARY): $(SOURCES)
GOOS=linux CGO_ENABLED=0 go build $(BUILD_VCS) -installsuffix cgo -a -ldflags "\
GOOS=linux CGO_ENABLED=0 go build -installsuffix cgo -a -ldflags "\
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.GitShortHash=$(GIT_SHORT_HASH) \
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.GitPorcelain=$(GIT_PORCELAIN) \
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.Version=$(VERSION) -s" \
-o ${ROOT}/${LOCAL_ENI_PLUGIN_BINARY} github.com/aws/amazon-ecs-cni-plugins/plugins/eni
@echo "Built eni plugin"

$(LOCAL_IPAM_PLUGIN_BINARY): $(SOURCES)
GOOS=linux CGO_ENABLED=0 go build $(BUILD_VCS) -installsuffix cgo -a -ldflags "\
GOOS=linux CGO_ENABLED=0 go build -installsuffix cgo -a -ldflags "\
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.GitShortHash=$(GIT_SHORT_HASH) \
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.GitPorcelain=$(GIT_PORCELAIN) \
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.Version=$(VERSION) -s" \
-o ${ROOT}/${LOCAL_IPAM_PLUGIN_BINARY} github.com/aws/amazon-ecs-cni-plugins/plugins/ipam
@echo "Built ipam plugin"

$(LOCAL_BRIDGE_PLUGIN_BINARY): $(SOURCES)
GOOS=linux CGO_ENABLED=0 go build $(BUILD_VCS) -installsuffix cgo -a -ldflags "\
GOOS=linux CGO_ENABLED=0 go build -installsuffix cgo -a -ldflags "\
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.GitShortHash=$(GIT_SHORT_HASH) \
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.GitPorcelain=$(GIT_PORCELAIN) \
-X github.com/aws/amazon-ecs-cni-plugins/pkg/version.Version=$(VERSION) -s" \
Expand Down

0 comments on commit 515943c

Please sign in to comment.