forked from VirusTotal/vt-cli
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
25 lines (19 loc) · 731 Bytes
/
Makefile
File metadata and controls
25 lines (19 loc) · 731 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# This how we want to name the binary output
BINARY=./build/vt
# Setup the -ldflags option for go build here, interpolate the variable values
LDFLAGS=-ldflags "-X github.com/VirusTotal/vt-cli/cmd.Version=${VERSION}"
# Builds the project
build:
go build ${LDFLAGS} -o ${BINARY} ./vt/main.go
# Installs our project: copies binaries
install:
go install ${LDFLAGS} github.com/VirusTotal/vt-cli/vt
# Build the project for multiple architectures
all:
gox ${LDFLAGS} \
-osarch="linux/amd64 linux/386 windows/amd64 windows/386 darwin/amd64 freebsd/amd64 freebsd/386" \
-output "build/{{.OS}}/{{.Arch}}/{{.Dir}}" github.com/VirusTotal/vt-cli/vt
# Cleans our project: deletes binaries
clean:
rm -rf ./build
.PHONY: clean install