refactor: improve Makefile structure and usability #11
10
Makefile
10
Makefile
@@ -1,20 +1,20 @@
|
|||||||
BINARY_NAME=lambda.exe
|
BINARY_NAME=lambda.exe
|
||||||
|
|
||||||
.PHONY: it run profile explain graph docs
|
.PHONY: build run profile explain graph docs
|
||||||
|
|
||||||
it:
|
build:
|
||||||
@ go build -o ${BINARY_NAME} ./cmd/lambda
|
@ go build -o ${BINARY_NAME} ./cmd/lambda
|
||||||
@ chmod +x ${BINARY_NAME}
|
@ chmod +x ${BINARY_NAME}
|
||||||
|
|
||||||
TEST=simple
|
TEST=simple
|
||||||
|
|
||||||
run: it
|
run: build
|
||||||
@ ./lambda.exe - < ./samples/$(TEST).txt > program.out
|
@ ./lambda.exe - < ./samples/$(TEST).txt > program.out
|
||||||
|
|
||||||
profile: it
|
profile: build
|
||||||
@ ./lambda.exe -p profile/cpu.prof - < ./samples/$(TEST).txt > program.out
|
@ ./lambda.exe -p profile/cpu.prof - < ./samples/$(TEST).txt > program.out
|
||||||
|
|
||||||
explain: it
|
explain: build
|
||||||
@ ./lambda.exe -x -p profile/cpu.prof - < ./samples/$(TEST).txt > program.out
|
@ ./lambda.exe -x -p profile/cpu.prof - < ./samples/$(TEST).txt > program.out
|
||||||
|
|
||||||
graph:
|
graph:
|
||||||
|
|||||||
Reference in New Issue
Block a user