-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
39 lines (31 loc) · 777 Bytes
/
Makefile
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
26
27
28
29
30
31
32
33
34
35
36
37
38
PROJECTNAME=$(shell basename "$(PWD)")
# Go related variables.
# Make is verbose in Linux. Make it silent.
MAKEFLAGS += --silent
.PHONY: help
## help: Prints this help message
help: Makefile
@echo
@echo " Choose a command run in "$(PROJECTNAME)":"
@echo
@sed -n 's/^##//p' $< | column -t -s ':' | sed -e 's/^/ /'
@echo
.PHONY: setup
## setup: Setup installes dependencies
setup:
@go mod tidy
.PHONY: run
## run: Runs gopwn
run:
@go run $$(ls -1 cmd/*.go | grep -v _test.go) checksec testdata/elf.i386
.PHONY: build
## build: Builds a beta version of gopwn
build:
go build -o dist/gopwn cmd/*.go
.PHONY: ci
## ci: Run all the tests and code checks
ci: build test
.PHONY: test
## test: Runs go test with default values
test:
@go test -v -race -count=1 ./...