initial commit
This commit is contained in:
25
Makefile
Normal file
25
Makefile
Normal file
@@ -0,0 +1,25 @@
|
||||
JC ?= jasminc
|
||||
CC ?= gcc
|
||||
MAKE ?= make
|
||||
|
||||
JASMIN_ARGS = -protect-calls -return-address-kind=mmx
|
||||
|
||||
.PHONY: clean run
|
||||
|
||||
all: build
|
||||
@true
|
||||
|
||||
build: build/agent.o
|
||||
ar -crs build/libagent.a build/agent.o
|
||||
|
||||
build/%.o: build/%.S
|
||||
$(CC) $< -c -o $@
|
||||
|
||||
clean:
|
||||
rm build/* 2> /dev/null || true
|
||||
$(MAKE) -C syscall clean
|
||||
|
||||
build/%.S: src/%.jazz
|
||||
$(JC) $(JASMIN_ARGS) $< -o $@
|
||||
# remove the remaining ret calls to make sure that we don't execute any return. Those returns should not be called anyways due to the infinit loop
|
||||
sed -i 's/ret/hlt/g' $@
|
||||
Reference in New Issue
Block a user