2015-10-12 17:15:57 +02:00
|
|
|
# Copyright 2015 syzkaller project authors. All rights reserved.
|
|
|
|
# Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
|
|
|
|
|
2016-01-25 10:57:56 +01:00
|
|
|
NOSTATIC ?= 0
|
|
|
|
ifeq ($(NOSTATIC), 0)
|
|
|
|
STATIC_FLAG=-static
|
|
|
|
endif
|
|
|
|
|
2016-08-26 07:09:25 +02:00
|
|
|
.PHONY: all format clean manager fuzzer executor execprog mutate prog2c stress extract generate
|
2015-10-12 17:15:57 +02:00
|
|
|
|
2015-12-17 16:06:33 +01:00
|
|
|
all: manager fuzzer executor
|
2015-10-12 17:15:57 +02:00
|
|
|
|
2015-12-28 12:49:19 +01:00
|
|
|
all-tools: execprog mutate prog2c stress repro upgrade
|
2015-12-21 12:38:27 +00:00
|
|
|
|
2016-01-25 10:57:56 +01:00
|
|
|
executor:
|
2016-01-25 11:04:49 +01:00
|
|
|
$(CC) -o ./bin/syz-executor executor/executor.cc -pthread -Wall -O1 -g $(STATIC_FLAG) $(CFLAGS)
|
2016-01-25 10:57:56 +01:00
|
|
|
|
2015-12-17 16:06:33 +01:00
|
|
|
manager:
|
|
|
|
go build -o ./bin/syz-manager github.com/google/syzkaller/syz-manager
|
2015-10-12 17:15:57 +02:00
|
|
|
|
2015-12-17 16:06:33 +01:00
|
|
|
fuzzer:
|
|
|
|
go build -o ./bin/syz-fuzzer github.com/google/syzkaller/syz-fuzzer
|
2015-10-12 17:15:57 +02:00
|
|
|
|
2015-12-21 12:38:27 +00:00
|
|
|
execprog:
|
|
|
|
go build -o ./bin/syz-execprog github.com/google/syzkaller/tools/syz-execprog
|
|
|
|
|
2015-12-23 19:19:45 +01:00
|
|
|
repro:
|
|
|
|
go build -o ./bin/syz-repro github.com/google/syzkaller/tools/syz-repro
|
|
|
|
|
2015-12-21 12:38:27 +00:00
|
|
|
mutate:
|
|
|
|
go build -o ./bin/syz-mutate github.com/google/syzkaller/tools/syz-mutate
|
|
|
|
|
|
|
|
prog2c:
|
|
|
|
go build -o ./bin/syz-prog2c github.com/google/syzkaller/tools/syz-prog2c
|
|
|
|
|
|
|
|
stress:
|
|
|
|
go build -o ./bin/syz-stress github.com/google/syzkaller/tools/syz-stress
|
|
|
|
|
2015-12-28 12:49:19 +01:00
|
|
|
upgrade:
|
|
|
|
go build -o ./bin/syz-upgrade github.com/google/syzkaller/tools/syz-upgrade
|
|
|
|
|
2016-08-26 07:09:25 +02:00
|
|
|
extract: bin/syz-extract
|
|
|
|
LINUX=$(LINUX) LINUXBLD=$(LINUXBLD) ./extract.sh
|
|
|
|
bin/syz-extract: ./syz-extract
|
|
|
|
go build -o $@ ./syz-extract
|
|
|
|
|
|
|
|
generate: bin/syz-sysgen
|
|
|
|
bin/syz-sysgen
|
2016-03-10 14:19:09 +00:00
|
|
|
bin/syz-sysgen: sysgen/*.go
|
2016-08-26 07:09:25 +02:00
|
|
|
go build -o $@ ./sysgen
|
2015-12-24 14:40:46 +01:00
|
|
|
|
2015-10-12 17:15:57 +02:00
|
|
|
format:
|
2015-11-10 20:32:03 +01:00
|
|
|
go fmt ./...
|
2015-10-12 17:15:57 +02:00
|
|
|
clang-format --style=file -i executor/executor.cc
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -rf ./bin/
|