mirror of
https://github.com/DragonOS-Community/DragonOS.git
synced 2025-06-23 03:53:26 +00:00
feat(CI): Build both platform image without edit configs (#3)
* feat(ci): additional dadk manifest for CI, add container capable rv64 run arg and gendisk cmd * feat(build): kernel compiling(linking) from diff-arch nolonger needs to make clean * breaking: use ci-command to run targets, enable both arch to build together * fix: specify toolchains and the dadk menifest for user program, and add nessesary toolchain. Now riscv64 ver of DragonOS can run into user mode. * fix(env): cleanup dirty configs, add make clean back * fix(build): update permission with whoami, and nolonger compile grub in rv64 building. * feat(ide): support for vscode debuging, using lldb plugin * feat(ci): automate u-boot download and installation for riscv64
This commit is contained in:
@ -3,7 +3,9 @@ user_sub_dirs = apps
|
||||
DADK_VERSION=$(shell dadk -V | awk 'END {print $$2}')
|
||||
# 最小的DADK版本
|
||||
MIN_DADK_VERSION = 0.2.0
|
||||
DADK_CACHE_DIR = $(ROOT_PATH)/bin/dadk_cache
|
||||
DADK_CACHE_DIR = $(ROOT_PATH)/bin/$(ARCH)/dadk_cache
|
||||
SYSROOT_DIR = $(ROOT_PATH)/bin/$(ARCH)/sysroot
|
||||
DADK_MANIFEST_PATH = $(ROOT_PATH)/oscomp/manifest-${ARCH}.toml
|
||||
|
||||
ECHO:
|
||||
@echo "$@"
|
||||
@ -33,6 +35,8 @@ ifneq ($(shell printf '%s\n%s' "$(DADK_VERSION)" "$(MIN_DADK_VERSION)" | sort -V
|
||||
endif
|
||||
endif
|
||||
|
||||
DADK = $(shell which dadk) --manifest $(DADK_MANIFEST_PATH)
|
||||
|
||||
.PHONY: dadk_run
|
||||
dadk_run: install_dadk
|
||||
mkdir -p $(DADK_CACHE_DIR)
|
||||
@ -44,7 +48,7 @@ dadk_clean: install_dadk
|
||||
@echo dadk_clean
|
||||
|
||||
all:
|
||||
mkdir -p $(ROOT_PATH)/bin/sysroot
|
||||
mkdir -p $(SYSROOT_DIR)
|
||||
|
||||
$(MAKE) dadk_run
|
||||
$(MAKE) copy_sysconfig
|
||||
@ -53,7 +57,7 @@ all:
|
||||
|
||||
.PHONY: copy_sysconfig
|
||||
copy_sysconfig:
|
||||
cp -r sysconfig/* $(ROOT_PATH)/bin/sysroot/
|
||||
cp -r sysconfig/* $(SYSROOT_DIR)
|
||||
|
||||
|
||||
.PHONY: clean
|
||||
|
@ -54,4 +54,5 @@ test-release:
|
||||
|
||||
.PHONY: install
|
||||
install:
|
||||
cargo install bpf-linker
|
||||
RUSTFLAGS=$(RUSTFLAGS) cargo $(TOOLCHAIN) install --target $(RUST_TARGET) --path ./syscall_ebpf --no-track --root $(INSTALL_DIR) --force
|
||||
|
@ -1,5 +1,5 @@
|
||||
TOOLCHAIN=
|
||||
RUSTFLAGS=
|
||||
TOOLCHAIN="+nightly-2024-11-05-x86_64-unknown-linux-gnu"
|
||||
RUSTFLAGS+=""
|
||||
|
||||
ifdef DADK_CURRENT_BUILD_DIR
|
||||
# 如果是在dadk中编译,那么安装到dadk的安装目录中
|
||||
|
@ -1,5 +1,5 @@
|
||||
TOOLCHAIN=
|
||||
RUSTFLAGS=
|
||||
TOOLCHAIN="+nightly-2024-11-05-x86_64-unknown-linux-gnu"
|
||||
RUSTFLAGS+=""
|
||||
|
||||
ifdef DADK_CURRENT_BUILD_DIR
|
||||
# 如果是在dadk中编译,那么安装到dadk的安装目录中
|
||||
|
Reference in New Issue
Block a user