github.com/gmemcc/yaegi@v0.12.1-0.20221128122509-aa99124c5d16/Makefile (about) 1 # Static linting of source files. See .golangci.toml for options 2 check: 3 golangci-lint run 4 5 # Generate stdlib/syscall/syscall_GOOS_GOARCH.go for all platforms 6 gen_all_syscall: internal/cmd/extract/extract 7 @for v in $$(go tool dist list); do \ 8 echo syscall_$${v%/*}_$${v#*/}.go; \ 9 GOOS=$${v%/*} GOARCH=$${v#*/} go generate ./stdlib/syscall ./stdlib/unrestricted; \ 10 done 11 12 internal/cmd/extract/extract: 13 rm -f internal/cmd/extract/extract 14 go generate ./internal/cmd/extract 15 16 generate: gen_all_syscall 17 go generate 18 19 install: 20 GOFLAGS=-ldflags=-X=main.version=$$(git describe --tags) go install ./... 21 22 tests: 23 go test -v ./... 24 go test -race ./interp 25 26 # https://github.com/goreleaser/godownloader 27 install.sh: .goreleaser.yml 28 godownloader --repo=traefik/yaegi -o install.sh .goreleaser.yml 29 30 .PHONY: check gen_all_syscall gen_tests generate_downloader internal/cmd/extract/extract install