xref: /DragonOS/user/apps/test_kvm/Makefile (revision bc6f0a967c8cb1e9379ced184b25a7722fbda2a4)
1*bc6f0a96S裕依ifeq ($(ARCH), x86_64)
2*bc6f0a96S裕依	CROSS_COMPILE=x86_64-linux-musl-
3*bc6f0a96S裕依else ifeq ($(ARCH), riscv64)
4*bc6f0a96S裕依	CROSS_COMPILE=riscv64-linux-musl-
5*bc6f0a96S裕依endif
640314b30SXiaoye Zheng
7*bc6f0a96S裕依CC=$(CROSS_COMPILE)gcc
840314b30SXiaoye Zheng
9*bc6f0a96S裕依.PHONY: all
10*bc6f0a96S裕依all: main.c
11*bc6f0a96S裕依	$(CC) -static -o test_kvm main.c
1240314b30SXiaoye Zheng
13*bc6f0a96S裕依.PHONY: install clean
14*bc6f0a96S裕依install: all
15*bc6f0a96S裕依	mv test_kvm $(DADK_CURRENT_BUILD_DIR)/test_kvm
16*bc6f0a96S裕依
17*bc6f0a96S裕依clean:
18*bc6f0a96S裕依	rm test_kvm *.o
19*bc6f0a96S裕依
20*bc6f0a96S裕依fmt:
21