Skip to content

Commit

Permalink
add Makefile prerequisites
Browse files Browse the repository at this point in the history
Signed-off-by: MorningTZH <morningtzh@yeah.net>
  • Loading branch information
morningtzh committed Feb 5, 2024
1 parent b4d451f commit e1272f3
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,13 @@ SYSTEMD_CONF_DIR := /etc/sysconfig

all: vmm quark wasm

bin/vmm-sandboxer:
vmm-sandboxer-sources := $(shell find vmm/sandbox -type f)
bin/vmm-sandboxer: $(vmm-sandboxer-sources)
@cd vmm/sandbox && cargo build --release --bin ${HYPERVISOR}
@mkdir -p bin && cp vmm/sandbox/target/release/${HYPERVISOR} bin/vmm-sandboxer

bin/vmm-task:
vmm-task-sources := $(shell find vmm/task -type f)
bin/vmm-task: $(vmm-task-sources)
@cd vmm/task && cargo build --release --target=${ARCH}-unknown-linux-musl
@mkdir -p bin && cp vmm/task/target/${ARCH}-unknown-linux-musl/release/vmm-task bin/vmm-task

Expand All @@ -34,15 +36,18 @@ bin/kuasar.initrd:
@bash -x vmm/scripts/image/${GUESTOS_IMAGE}/build.sh initrd
@mkdir -p bin && cp /tmp/kuasar.initrd bin/kuasar.initrd && rm /tmp/kuasar.initrd

bin/wasm-sandboxer:
wasm-sources := $(shell find wasm -type f)
bin/wasm-sandboxer: $(wasm-sources)
@cd wasm && cargo build --release --features=${WASM_RUNTIME}
@mkdir -p bin && cp wasm/target/release/wasm-sandboxer bin/wasm-sandboxer

bin/quark-sandboxer:
quark-sources := $(shell find quark -type f)
bin/quark-sandboxer: $(quark-sources)
@cd quark && cargo build --release
@mkdir -p bin && cp quark/target/release/quark-sandboxer bin/quark-sandboxer

bin/runc-sandboxer:
runc-sources := $(shell find runc -type f)
bin/runc-sandboxer: $(runc-sources)
@cd runc && cargo build --release
@mkdir -p bin && cp runc/target/release/runc-sandboxer bin/runc-sandboxer

Expand Down

0 comments on commit e1272f3

Please sign in to comment.