CBL-Mariner/SPECS/node-problem-detector/001-remove_arch_specific_ma...

81 строка
2.8 KiB
Diff

diff --git a/Makefile b/Makefile
index 84caddc..20b14f1 100644
--- a/Makefile
+++ b/Makefile
@@ -22,8 +22,8 @@
all: build
# PLATFORMS is the set of OS_ARCH that NPD can build against.
-LINUX_PLATFORMS=linux_amd64 linux_arm64
-PLATFORMS=$(LINUX_PLATFORMS) windows_amd64
+LINUX_PLATFORMS=linux
+PLATFORMS=$(LINUX_PLATFORMS)
# VERSION is the version of the binary.
VERSION?=$(shell if [ -d .git ]; then echo `git describe --tags --dirty`; else echo "UNKNOWN"; fi)
@@ -125,47 +125,13 @@ ifeq ($(ENABLE_JOURNALD), 1)
endif
ALL_BINARIES = $(foreach binary, $(BINARIES) $(BINARIES_LINUX_ONLY), ./$(binary)) \
- $(foreach platform, $(LINUX_PLATFORMS), $(foreach binary, $(BINARIES) $(BINARIES_LINUX_ONLY), output/$(platform)/$(binary))) \
- $(foreach binary, $(BINARIES), output/windows_amd64/$(binary).exe)
+ $(foreach platform, $(LINUX_PLATFORMS), $(foreach binary, $(BINARIES) $(BINARIES_LINUX_ONLY), output/$(platform)/$(binary)))
ALL_TARBALLS = $(foreach platform, $(PLATFORMS), $(NPD_NAME_VERSION)-$(platform).tar.gz)
-output/windows_amd64/bin/%.exe: $(PKG_SOURCES)
- GOOS=windows GOARCH=amd64 CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on go build \
- -mod vendor \
- -o $@ \
- -ldflags '-X $(PKG)/pkg/version.version=$(VERSION)' \
- -tags "$(WINDOWS_BUILD_TAGS)" \
- ./cmd/$(subst -,,$*)
- touch $@
-
-output/windows_amd64/test/bin/%.exe: $(PKG_SOURCES)
- GOOS=windows GOARCH=amd64 CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on go build \
- -mod vendor \
- -o $@ \
- -tags "$(WINDOWS_BUILD_TAGS)" \
- ./test/e2e/$(subst -,,$*)
-
-output/linux_amd64/bin/%: $(PKG_SOURCES)
- GOOS=linux GOARCH=amd64 CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on \
- CC=x86_64-linux-gnu-gcc go build \
- -mod vendor \
- -o $@ \
- -ldflags '-X $(PKG)/pkg/version.version=$(VERSION)' \
- -tags "$(LINUX_BUILD_TAGS)" \
- ./cmd/$(subst -,,$*)
- touch $@
-
-output/linux_amd64/test/bin/%: $(PKG_SOURCES)
- GOOS=linux GOARCH=amd64 CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on \
- CC=x86_64-linux-gnu-gcc go build \
- -mod vendor \
- -o $@ \
- -tags "$(LINUX_BUILD_TAGS)" \
- ./test/e2e/$(subst -,,$*)
-output/linux_arm64/bin/%: $(PKG_SOURCES)
- GOOS=linux GOARCH=arm64 CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on \
- CC=aarch64-linux-gnu-gcc go build \
+output/linux/bin/%: $(PKG_SOURCES)
+ GOOS=linux CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on \
+ go build \
-mod vendor \
-o $@ \
-ldflags '-X $(PKG)/pkg/version.version=$(VERSION)' \
@@ -173,9 +139,9 @@ output/linux_arm64/bin/%: $(PKG_SOURCES)
./cmd/$(subst -,,$*)
touch $@
-output/linux_arm64/test/bin/%: $(PKG_SOURCES)
- GOOS=linux GOARCH=arm64 CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on \
- CC=aarch64-linux-gnu-gcc go build \
+output/linux/test/bin/%: $(PKG_SOURCES)
+ GOOS=linux CGO_ENABLED=$(CGO_ENABLED) GO111MODULE=on \
+ go build \
-mod vendor \
-o $@ \
-tags "$(LINUX_BUILD_TAGS)" \