mirror of
https://gitea.com/Lydanne/buildx.git
synced 2025-07-31 07:38:04 +08:00
vendor: update buildkit to 539be170
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
This commit is contained in:
46
vendor/go.opentelemetry.io/otel/Makefile
generated
vendored
46
vendor/go.opentelemetry.io/otel/Makefile
generated
vendored
@@ -40,8 +40,11 @@ $(TOOLS)/%: | $(TOOLS)
|
||||
cd $(TOOLS_MOD_DIR) && \
|
||||
$(GO) build -o $@ $(PACKAGE)
|
||||
|
||||
SEMCONVGEN = $(TOOLS)/semconv-gen
|
||||
$(TOOLS)/semconv-gen: PACKAGE=go.opentelemetry.io/otel/$(TOOLS_MOD_DIR)/semconv-gen
|
||||
MULTIMOD = $(TOOLS)/multimod
|
||||
$(TOOLS)/multimod: PACKAGE=go.opentelemetry.io/build-tools/multimod
|
||||
|
||||
SEMCONVGEN = $(TOOLS)/semconvgen
|
||||
$(TOOLS)/semconvgen: PACKAGE=go.opentelemetry.io/build-tools/semconvgen
|
||||
|
||||
CROSSLINK = $(TOOLS)/crosslink
|
||||
$(TOOLS)/crosslink: PACKAGE=go.opentelemetry.io/otel/$(TOOLS_MOD_DIR)/crosslink
|
||||
@@ -50,16 +53,22 @@ GOLANGCI_LINT = $(TOOLS)/golangci-lint
|
||||
$(TOOLS)/golangci-lint: PACKAGE=github.com/golangci/golangci-lint/cmd/golangci-lint
|
||||
|
||||
MISSPELL = $(TOOLS)/misspell
|
||||
$(TOOLS)/misspell: PACKAGE= github.com/client9/misspell/cmd/misspell
|
||||
$(TOOLS)/misspell: PACKAGE=github.com/client9/misspell/cmd/misspell
|
||||
|
||||
GOCOVMERGE = $(TOOLS)/gocovmerge
|
||||
$(TOOLS)/gocovmerge: PACKAGE=github.com/wadey/gocovmerge
|
||||
|
||||
STRINGER = $(TOOLS)/stringer
|
||||
$(TOOLS)/stringer: PACKAGE=golang.org/x/tools/cmd/stringer
|
||||
|
||||
PORTO = $(TOOLS)/porto
|
||||
$(TOOLS)/porto: PACKAGE=github.com/jcchavezs/porto/cmd/porto
|
||||
|
||||
GOJQ = $(TOOLS)/gojq
|
||||
$(TOOLS)/gojq: PACKAGE=github.com/itchyny/gojq/cmd/gojq
|
||||
|
||||
.PHONY: tools
|
||||
tools: $(CROSSLINK) $(GOLANGCI_LINT) $(MISSPELL) $(STRINGER) $(TOOLS)/gojq $(SEMCONVGEN)
|
||||
|
||||
tools: $(CROSSLINK) $(GOLANGCI_LINT) $(MISSPELL) $(GOCOVMERGE) $(STRINGER) $(PORTO) $(GOJQ) $(SEMCONVGEN) $(MULTIMOD)
|
||||
|
||||
# Build
|
||||
|
||||
@@ -71,11 +80,12 @@ examples:
|
||||
$(GO) build .); \
|
||||
done
|
||||
|
||||
generate: $(STRINGER)
|
||||
generate: $(STRINGER) $(PORTO)
|
||||
set -e; for dir in $(ALL_GO_MOD_DIRS); do \
|
||||
echo "$(GO) generate $${dir}/..."; \
|
||||
(cd "$${dir}" && \
|
||||
PATH="$(TOOLS):$${PATH}" $(GO) generate ./...); \
|
||||
PATH="$(TOOLS):$${PATH}" $(GO) generate ./... && \
|
||||
$(PORTO) -w .); \
|
||||
done
|
||||
|
||||
build: generate
|
||||
@@ -111,19 +121,18 @@ test:
|
||||
COVERAGE_MODE = atomic
|
||||
COVERAGE_PROFILE = coverage.out
|
||||
.PHONY: test-coverage
|
||||
test-coverage:
|
||||
test-coverage: | $(GOCOVMERGE)
|
||||
@set -e; \
|
||||
printf "" > coverage.txt; \
|
||||
for dir in $(ALL_COVERAGE_MOD_DIRS); do \
|
||||
echo "$(GO) test -coverpkg=./... -covermode=$(COVERAGE_MODE) -coverprofile="$(COVERAGE_PROFILE)" $${dir}/..."; \
|
||||
echo "$(GO) test -coverpkg=go.opentelemetry.io/otel/... -covermode=$(COVERAGE_MODE) -coverprofile="$(COVERAGE_PROFILE)" $${dir}/..."; \
|
||||
(cd "$${dir}" && \
|
||||
$(GO) list ./... \
|
||||
| grep -v third_party \
|
||||
| xargs $(GO) test -coverpkg=./... -covermode=$(COVERAGE_MODE) -coverprofile="$(COVERAGE_PROFILE)" && \
|
||||
$(GO) tool cover -html=coverage.out -o coverage.html); \
|
||||
[ -f "$${dir}/coverage.out" ] && cat "$${dir}/coverage.out" >> coverage.txt; \
|
||||
done; \
|
||||
sed -i.bak -e '2,$$ { /^mode: /d; }' coverage.txt
|
||||
$(GOCOVMERGE) $$(find . -name coverage.out) > coverage.txt
|
||||
|
||||
.PHONY: lint
|
||||
lint: misspell lint-modules | $(GOLANGCI_LINT)
|
||||
@@ -134,6 +143,10 @@ lint: misspell lint-modules | $(GOLANGCI_LINT)
|
||||
$(GOLANGCI_LINT) run); \
|
||||
done
|
||||
|
||||
.PHONY: vanity-import-check
|
||||
vanity-import-check: | $(PORTO)
|
||||
$(PORTO) --include-internal -l .
|
||||
|
||||
.PHONY: misspell
|
||||
misspell: | $(MISSPELL)
|
||||
$(MISSPELL) -w $(ALL_DOCS)
|
||||
@@ -181,3 +194,14 @@ check-clean-work-tree:
|
||||
git status; \
|
||||
exit 1; \
|
||||
fi
|
||||
|
||||
.PHONY: prerelease
|
||||
prerelease: | $(MULTIMOD)
|
||||
@[ "${MODSET}" ] || ( echo ">> env var MODSET is not set"; exit 1 )
|
||||
$(MULTIMOD) verify && $(MULTIMOD) prerelease -m ${MODSET}
|
||||
|
||||
COMMIT ?= "HEAD"
|
||||
.PHONY: add-tags
|
||||
add-tags: | $(MULTIMOD)
|
||||
@[ "${MODSET}" ] || ( echo ">> env var MODSET is not set"; exit 1 )
|
||||
$(MULTIMOD) verify && $(MULTIMOD) tag -m ${MODSET} -c ${COMMIT}
|
||||
|
Reference in New Issue
Block a user