Selaa lähdekoodia

chore: Bump dadk to 0.2.0 (#1058)

# 概述

把dadk版本升级到0.2.0

dadk 0.2.0能够提升编译速度,并且支持使用dadk对内核进行profiling。
新版dadk的文档: https://docs.dragonos.org.cn/p/dadk/

# 注意

这是一个breaking change,升级后,将无法使用dadk 0.2.0去编译旧的项目。如有需要,请手动降级到dadk 0.1.11:
```shell
cargo install --git  https://git.mirrors.dragonos.org.cn/DragonOS-Community/DADK --tag v0.1.11
```

# 更改列表

* chore: 把管理用户程序编译的dadk配置文件改为新格式的

* feat: 使用新版dadk来创建\挂载\卸载磁盘镜像

* chore: bump dadk min version to 0.2.0

* chore: fix ci

* chore: 更新github ci镜像到1.7

* doc: 添加文档

---------
Co-Authored-by: xuzihao <[email protected]>
Signed-off-by: longjin <[email protected]>
LoGin 3 kuukautta sitten
vanhempi
commit
e8b1db320d
100 muutettua tiedostoa jossa 2016 lisäystä ja 1225 poistoa
  1. 45 44
      .github/workflows/makefile.yml
  2. 22 24
      Makefile
  3. 14 0
      config/rootfs.toml
  4. 24 0
      dadk-manifest.toml
  5. 1 0
      docs/kernel/debug/index.rst
  6. 95 0
      docs/kernel/debug/profiling-kernel-with-dadk.md
  7. 3 0
      docs/userland/appdev/c-cpp-quick-start.md
  8. 2 1
      docs/userland/appdev/index.rst
  9. 3 8
      docs/userland/appdev/rust-quick-start.md
  10. 3 0
      env.mk
  11. 1 1
      tools/BUILD_CONTAINER_VERSION
  12. 40 0
      tools/check_arch.sh
  13. 0 27
      tools/mount_virt_disk.sh
  14. 1 1
      tools/run-qemu.sh
  15. 0 19
      tools/umount_virt_disk.sh
  16. 25 41
      tools/write_disk_image.sh
  17. 5 7
      user/Makefile
  18. 0 25
      user/dadk/config/about.dadk
  19. 36 0
      user/dadk/config/about.toml
  20. 0 23
      user/dadk/config/clear-0.1.0.dadk
  21. 44 0
      user/dadk/config/clear-0.1.0.toml
  22. 0 27
      user/dadk/config/core_utils-9.4.0.dadk
  23. 39 0
      user/dadk/config/core_utils-9.4.0.toml
  24. 0 24
      user/dadk/config/dmesg-0.1.0.dadk
  25. 47 0
      user/dadk/config/dmesg-0.1.0.toml
  26. 0 34
      user/dadk/config/dog_0_1_0.dadk
  27. 51 0
      user/dadk/config/dog_0_1_0.toml
  28. 0 24
      user/dadk/config/dragon_reach-0.1.0.dadk
  29. 49 0
      user/dadk/config/dragon_reach-0.1.0.toml
  30. 0 24
      user/dadk/config/held-0.1.0.dadk
  31. 49 0
      user/dadk/config/held-0.1.0.toml
  32. 0 24
      user/dadk/config/http_server-0.1.0.dadk
  33. 40 0
      user/dadk/config/http_server-0.1.0.toml
  34. 0 28
      user/dadk/config/musl_1_2_4.dadk
  35. 40 0
      user/dadk/config/musl_1_2_4.toml
  36. 0 24
      user/dadk/config/nova_shell-0.1.0.dadk
  37. 44 0
      user/dadk/config/nova_shell-0.1.0.toml
  38. 0 27
      user/dadk/config/riscv_init-0.1.0.dadk
  39. 40 0
      user/dadk/config/riscv_init-0.1.0.toml
  40. 0 25
      user/dadk/config/tar_1_35.dadk
  41. 39 0
      user/dadk/config/tar_1_35.toml
  42. 0 27
      user/dadk/config/test_alarm_0_1_0.dadk
  43. 41 0
      user/dadk/config/test_alarm_0_1_0.toml
  44. 0 27
      user/dadk/config/test_backlog_0_1_0.dadk
  45. 40 0
      user/dadk/config/test_backlog_0_1_0.toml
  46. 0 24
      user/dadk/config/test_bind-0.1.0.dadk
  47. 40 0
      user/dadk/config/test_bind-0.1.0.toml
  48. 0 25
      user/dadk/config/test_blockcache_0_1_0.dadk
  49. 42 0
      user/dadk/config/test_blockcache_0_1_0.toml
  50. 0 29
      user/dadk/config/test_chown_0_1_0.dadk
  51. 46 0
      user/dadk/config/test_chown_0_1_0.toml
  52. 0 23
      user/dadk/config/test_cred-0.1.0.dadk
  53. 51 0
      user/dadk/config/test_cred-0.1.0.toml
  54. 0 23
      user/dadk/config/test_dup3_0_1_0.dadk
  55. 51 0
      user/dadk/config/test_dup3_0_1_0.toml
  56. 0 23
      user/dadk/config/test_ebpf_0_1_0.dadk
  57. 37 0
      user/dadk/config/test_ebpf_0_1_0.toml
  58. 0 23
      user/dadk/config/test_eventfd_0_1_0.dadk
  59. 32 0
      user/dadk/config/test_eventfd_0_1_0.toml
  60. 0 23
      user/dadk/config/test_filemap-0.1.0.dadk
  61. 36 0
      user/dadk/config/test_filemap-0.1.0.toml
  62. 0 25
      user/dadk/config/test_for_robustfutex_0_1_0.dadk
  63. 36 0
      user/dadk/config/test_for_robustfutex_0_1_0.toml
  64. 0 23
      user/dadk/config/test_fstat-0.1.0.dadk
  65. 36 0
      user/dadk/config/test_fstat-0.1.0.toml
  66. 0 27
      user/dadk/config/test_fstatfs_0_1_0.dadk
  67. 41 0
      user/dadk/config/test_fstatfs_0_1_0.toml
  68. 0 24
      user/dadk/config/test_gettimeofday-0.1.0.dadk
  69. 37 0
      user/dadk/config/test_gettimeofday-0.1.0.toml
  70. 0 25
      user/dadk/config/test_kvm_0_1_0.dadk
  71. 46 0
      user/dadk/config/test_kvm_0_1_0.toml
  72. 0 27
      user/dadk/config/test_lo_0_1_0.dadk
  73. 36 0
      user/dadk/config/test_lo_0_1_0.toml
  74. 0 23
      user/dadk/config/test_mkfifo-0.1.0.dadk
  75. 36 0
      user/dadk/config/test_mkfifo-0.1.0.toml
  76. 0 23
      user/dadk/config/test_mount_1_0_0.dadk
  77. 51 0
      user/dadk/config/test_mount_1_0_0.toml
  78. 0 25
      user/dadk/config/test_namespace.dadk
  79. 52 0
      user/dadk/config/test_namespace.toml
  80. 0 25
      user/dadk/config/test_overlayfs.dadk
  81. 46 0
      user/dadk/config/test_overlayfs.toml
  82. 0 24
      user/dadk/config/test_pty-0.1.0.dadk
  83. 46 0
      user/dadk/config/test_pty-0.1.0.toml
  84. 0 24
      user/dadk/config/test_ramfs-0.1.0.dadk
  85. 36 0
      user/dadk/config/test_ramfs-0.1.0.toml
  86. 0 24
      user/dadk/config/test_shm-0.1.0.dadk
  87. 52 0
      user/dadk/config/test_shm-0.1.0.toml
  88. 0 24
      user/dadk/config/test_sigint-0.1.0.dadk
  89. 36 0
      user/dadk/config/test_sigint-0.1.0.toml
  90. 0 24
      user/dadk/config/test_signal-0.1.0.dadk
  91. 41 0
      user/dadk/config/test_signal-0.1.0.toml
  92. 0 23
      user/dadk/config/test_socket-0.1.0.dadk
  93. 36 0
      user/dadk/config/test_socket-0.1.0.toml
  94. 0 24
      user/dadk/config/test_sqlite3-3.42.0.dadk
  95. 52 0
      user/dadk/config/test_sqlite3-3.42.0.toml
  96. 0 27
      user/dadk/config/test_statfs_0_1_0.dadk
  97. 41 0
      user/dadk/config/test_statfs_0_1_0.toml
  98. 0 26
      user/dadk/config/test_statx_0_1_0.dadk
  99. 41 0
      user/dadk/config/test_statx_0_1_0.toml
  100. 0 29
      user/dadk/config/test_symlink_0_1_0.dadk

+ 45 - 44
.github/workflows/makefile.yml

@@ -2,96 +2,97 @@ name: Build Check
 
 on:
   push:
-    branches: [ "master", "feat-*", "fix-*"]
+    branches: ["master", "feat-*", "fix-*"]
   pull_request:
-    branches: [ "master", "feat-*", "fix-*"]
+    branches: ["master", "feat-*", "fix-*"]
 
 jobs:
-  
   format-check:
     name: Format check ${{ matrix.arch }}
     runs-on: ubuntu-latest
     continue-on-error: true
-    container: dragonos/dragonos-dev:v1.6
+    container: dragonos/dragonos-dev:v1.7
 
     strategy:
       matrix:
         arch: [x86_64, riscv64]
 
     steps:
-    - run: echo "Running in dragonos/dragonos-dev:v1.6"
-    - uses: actions/checkout@v3
+      - run: echo "Running in dragonos/dragonos-dev:v1.7"
+      - uses: actions/checkout@v3
 
-    - name: Format check
-      env:
+      - name: Format check
+        env:
           ARCH: ${{ matrix.arch }}
           HOME: /root
-      shell: bash -ileo pipefail {0}
-      run: |
-            printf "\n" >> kernel/src/include/bindings/bindings.rs
-            FMT_CHECK=1 make fmt
-  
+        shell: bash -ileo pipefail {0}
+        run: |
+          printf "\n" >> kernel/src/include/bindings/bindings.rs
+          sed -i 's/arch = ".*"/arch = "${{ matrix.arch }}"/' dadk-manifest.toml
+          FMT_CHECK=1 make fmt
+
   kernel-static-test:
     name: Kernel static test ${{ matrix.arch }}
     runs-on: ubuntu-latest
     continue-on-error: true
-    container: dragonos/dragonos-dev:v1.6
+    container: dragonos/dragonos-dev:v1.7
 
     strategy:
       matrix:
         arch: [x86_64, riscv64]
 
     steps:
-    - run: echo "Running in dragonos/dragonos-dev:v1.6"
+      - run: echo "Running in dragonos/dragonos-dev:v1.7"
 
-    - uses: actions/checkout@v3
+      - uses: actions/checkout@v3
 
-    - name: Run kernel static test
-      shell: bash -ileo pipefail {0}
-      env:
+      - name: Run kernel static test
+        shell: bash -ileo pipefail {0}
+        env:
           ARCH: ${{ matrix.arch }}
           HOME: /root
-      run: bash -c "source /root/.cargo/env && cd kernel && make test && make test-rbpf"
+        run: bash -c "source /root/.cargo/env && cd kernel && make test && make test-rbpf"
 
   build-x86_64:
-
     runs-on: ubuntu-latest
-    container: dragonos/dragonos-dev:v1.6
+    container: dragonos/dragonos-dev:v1.7
 
     steps:
-    - run: echo "Running in dragonos/dragonos-dev:v1.6"
+      - run: echo "Running in dragonos/dragonos-dev:v1.7"
 
-    - uses: actions/checkout@v3
-    - name: build the DragonOS
-      env:
+      - uses: actions/checkout@v3
+      - name: build the DragonOS
+        env:
           ARCH: x86_64
           HOME: /root
-      shell: bash -ileo pipefail {0}
+        shell: bash -ileo pipefail {0}
 
-      run: |
-        source ~/.bashrc
-        source ~/.cargo/env
-        export DragonOS_GCC=$HOME/opt/dragonos-gcc/gcc-x86_64-unknown-none/bin
-        
-        make -j $(nproc)
+        run: |
+          source ~/.bashrc
+          source ~/.cargo/env
+          export DragonOS_GCC=$HOME/opt/dragonos-gcc/gcc-x86_64-unknown-none/bin
+          sed -i 's/arch = ".*"/arch = "${{ env.ARCH }}"/' dadk-manifest.toml
 
-  build-riscv64:
+          make all -j $(nproc)
 
+  build-riscv64:
     runs-on: ubuntu-latest
-    container: dragonos/dragonos-dev:v1.6
+    container: dragonos/dragonos-dev:v1.7
 
     steps:
-    - run: echo "Running in dragonos/dragonos-dev:v1.6"
+      - run: echo "Running in dragonos/dragonos-dev:v1.7"
 
-    - uses: actions/checkout@v3
-      with:
-        submodules: 'recursive'
+      - uses: actions/checkout@v3
+        with:
+          submodules: "recursive"
 
-    - name: build the DragonOS
-      shell: bash -ileo pipefail {0}
-      env:
+      - name: build the DragonOS
+        shell: bash -ileo pipefail {0}
+        env:
           ARCH: riscv64
           HOME: /root
 
-      run: source ~/.bashrc && source ~/.cargo/env && make kernel -j $(nproc)
-
+        run: |
+          source ~/.bashrc && source ~/.cargo/env
+          sed -i 's/arch = ".*"/arch = "${{ env.ARCH }}"/' dadk-manifest.toml
+          make kernel -j $(nproc)

+ 22 - 24
Makefile

@@ -34,19 +34,22 @@ else
 	FMT_CHECK=
 endif
 
+# Check if ARCH matches the arch field in dadk-manifest.toml
+check_arch:
+	@bash tools/check_arch.sh
 
 .PHONY: all 
 all: kernel user
 
 
 .PHONY: kernel
-kernel:
+kernel: check_arch
 	mkdir -p bin/kernel/
 	
 	$(MAKE) -C ./kernel all ARCH=$(ARCH) || (sh -c "echo 内核编译失败" && exit 1)
 	
 .PHONY: user
-user:
+user: check_arch
 	$(MAKE) -C ./user all ARCH=$(ARCH) || (sh -c "echo 用户程序编译失败" && exit 1)
 
 .PHONY: clean
@@ -61,11 +64,6 @@ clean:
 ECHO:
 	@echo "$@"
 
-cppcheck-xml: 
-	cppcheck kernel user --platform=unix64 --std=c11 -I user/libs/ -I=kernel/ --force -j $(NPROCS) --xml 2> cppcheck.xml
-
-cppcheck:
-	cppcheck kernel user --platform=unix64 --std=c11 -I user/libs/ -I=kernel/ --force -j $(NPROCS)
 
 docs: ECHO
 	bash -c "cd docs && make html && cd .."
@@ -81,74 +79,74 @@ else
 endif
 
 # 写入磁盘镜像
-write_diskimage:
+write_diskimage: check_arch
 	@echo "write_diskimage arch=$(ARCH)"
-	bash -c "export ARCH=$(ARCH); cd tools && bash grub_auto_install.sh && sudo ARCH=$(ARCH) bash $(ROOT_PATH)/tools/write_disk_image.sh --bios=legacy && cd .."
+	bash -c "export ARCH=$(ARCH); cd tools && bash grub_auto_install.sh && sudo DADK=$(DADK) ARCH=$(ARCH) bash $(ROOT_PATH)/tools/write_disk_image.sh --bios=legacy && cd .."
 
 # 写入磁盘镜像(uefi)
-write_diskimage-uefi:
-	bash -c "export ARCH=$(ARCH); cd tools && bash grub_auto_install.sh && sudo ARCH=$(ARCH) bash $(ROOT_PATH)/tools/write_disk_image.sh --bios=uefi && cd .."
+write_diskimage-uefi: check_arch
+	bash -c "export ARCH=$(ARCH); cd tools && bash grub_auto_install.sh && sudo DADK=$(DADK) ARCH=$(ARCH) bash $(ROOT_PATH)/tools/write_disk_image.sh --bios=uefi && cd .."
 # 不编译,直接启动QEMU
-qemu:
+qemu: check_arch
 	sh -c "cd tools && bash run-qemu.sh --bios=legacy --display=window && cd .."
 
 # 不编译,直接启动QEMU,不显示图像
-qemu-nographic:
+qemu-nographic: check_arch
 	sh -c "cd tools && bash run-qemu.sh --bios=legacy --display=nographic && cd .."
 
 # 不编译,直接启动QEMU(UEFI)
-qemu-uefi:
+qemu-uefi: check_arch
 	sh -c "cd tools && bash run-qemu.sh --bios=uefi --display=window && cd .."
 # 不编译,直接启动QEMU,使用VNC Display作为图像输出
-qemu-vnc:
+qemu-vnc: check_arch
 	sh -c "cd tools && bash run-qemu.sh --bios=legacy --display=vnc && cd .."
 # 不编译,直接启动QEMU(UEFI),使用VNC Display作为图像输出
-qemu-uefi-vnc:
+qemu-uefi-vnc: check_arch
 	sh -c "cd tools && bash run-qemu.sh --bios=uefi --display=vnc && cd .."
 	
 # 编译并写入磁盘镜像
-build:
+build: check_arch
 	$(MAKE) all -j $(NPROCS)
 	$(MAKE) write_diskimage || exit 1
 
 # 在docker中编译,并写入磁盘镜像
-docker:
+docker: check_arch
 	@echo "使用docker构建"
 	sudo bash tools/build_in_docker.sh || exit 1
 	$(MAKE) write_diskimage || exit 1
 	
 # uefi方式启动
-run-uefi:
+run-uefi: check_arch
 	$(MAKE) all -j $(NPROCS)
 	$(MAKE) write_diskimage-uefi || exit 1
 	$(MAKE) qemu-uefi
 	
 # 编译并启动QEMU
-run:
+run: check_arch
 	$(MAKE) all -j $(NPROCS)
 	$(MAKE) write_diskimage || exit 1
 	$(MAKE) qemu
 
 # uefi方式启动,使用VNC Display作为图像输出
-run-uefi-vnc:
+run-uefi-vnc: check_arch
 	$(MAKE) all -j $(NPROCS)
 	$(MAKE) write_diskimage-uefi || exit 1
 	$(MAKE) qemu-uefi-vnc
 	
 # 编译并启动QEMU,使用VNC Display作为图像输出
-run-vnc:
+run-vnc: check_arch
 	$(MAKE) all -j $(NPROCS)
 	$(MAKE) write_diskimage || exit 1
 	$(MAKE) qemu-vnc
 
 # 在docker中编译,并启动QEMU
-run-docker:
+run-docker: check_arch
 	@echo "使用docker构建并运行"
 	sudo bash tools/build_in_docker.sh || exit 1
 	$(MAKE) write_diskimage || exit 1
 	$(MAKE) qemu
 
-fmt:
+fmt: check_arch
 	@echo "格式化代码" 
 	FMT_CHECK=$(FMT_CHECK) $(MAKE) fmt -C kernel
 	FMT_CHECK=$(FMT_CHECK) $(MAKE) fmt -C user

+ 14 - 0
config/rootfs.toml

@@ -0,0 +1,14 @@
+[metadata]
+# Filesystem type (options: `fat32`)
+fs_type = "fat32"
+# Size of the rootfs disk image (eg, `1G`, `1024M`)
+size = "1G"
+
+[partition]
+# Partition type (options: "none", "mbr", "gpt")
+#
+# If "none" is specified, no partition table will be created, 
+# and the entire disk will be treated as a single partition.
+#
+# Note that the "none" option is incompatible with GRUB boot.
+type = "mbr"

+ 24 - 0
dadk-manifest.toml

@@ -0,0 +1,24 @@
+# DADK 总控文件
+
+[metadata]
+# Target architecture. Options: x86_64, riscv64
+arch = "x86_64"
+
+# Hypervisor config path
+hypervisor-config = "config/hypervisor.toml"
+
+# RootFS config path
+rootfs-config = "config/rootfs.toml"
+
+# Boot config path
+boot-config = "config/boot.toml"
+
+# System root directory folder (DADK will copy the files in this directory to the root directory of the disk image)
+sysroot-dir = "bin/sysroot"
+
+# DADK Root Cache directory path
+cache-root-dir = "bin/dadk_cache"
+
+# User configuration directory path
+# 这个字段只是临时用于兼容旧版本,v0.2版本重构完成后会删除
+user-config-dir = "user/dadk/config"

+ 1 - 0
docs/kernel/debug/index.rst

@@ -9,3 +9,4 @@
 
    traceback
    debug-kernel-with-gdb
+   profiling-kernel-with-dadk

+ 95 - 0
docs/kernel/debug/profiling-kernel-with-dadk.md

@@ -0,0 +1,95 @@
+# 使用DADK对内核进行性能分析
+
+## 1. 概述
+
+本文将教你使用DADK,对DragonOS内核进行性能分析,以识别和解决潜在的性能瓶颈。
+
+### 1.1 准备工作
+
+::: {note}
+在开始之前,请确保你已经安装了DADK,并且已经配置好了DragonOS内核的编译环境。
+:::
+
+### 1.2 什么是火焰图?
+
+如果你没有听说过火焰图,可以先阅读这篇文章:[《如何读懂火焰图?- 阮一峰》](https://www.ruanyifeng.com/blog/2017/09/flame-graph.html)
+
+简单的说,火焰图是基于性能采样结果产生的 SVG 图片,用来展示 CPU 的调用栈。
+
+![](https://web-static2.dragonos.org.cn//longjin/flame2.svg?imageSlim)
+
+x 轴表示抽样数,如果一个函数在 x 轴占据的宽度越宽,就表示它被抽到的次数多,即执行的时间长。注意,x 轴不代表时间,而是所有的调用栈合并后,按字母顺序排列的。
+
+火焰图就是看顶层的哪个函数占据的宽度最大。只要有"平顶"(plateaus),就表示该函数可能存在性能问题。
+
+颜色没有特殊含义,因为火焰图表示的是 CPU 的繁忙程度,所以一般选择暖色调。
+
+## 2. 配置DragonOS内核
+
+由于性能分析需要详尽的符号表数据,因此我们需要在编译内核时,需要进行以下配置:
+
+在`kernel/Cargo.toml`中的`[profile.release]`部分,设置以下两项:
+
+```toml
+[profile.release]
+debug = true
+opt-level = 1
+```
+
+这样,编译出来的内核就会包含符号表数据,方便我们进行性能分析。
+
+## 3. 使用DADK进行性能分析
+
+### 3.1 启动内核
+
+首先,我们需要启动DragonOS内核。
+
+```shell
+# 使用你喜欢的方式启动内核,例如:
+make run
+# 或者
+make build && make qemu-nographic
+```
+
+### 3.2 运行你的工作负载
+
+在启动内核后,我们需要运行一些工作负载,以便进行性能分析。
+
+这可以是一个应用程序,也可以是别的东西。甚至你可以什么都不运行,只是单纯看看DragonOS内核在空闲时的调用栈情况。
+
+### 3.3 启动DADK进行性能分析
+
+在DragonOS项目目录下,运行以下命令:
+
+```shell
+dadk profile sample --format flamegraph  --output flame.svg --interval 200ms --duration 20s  --cpu-mask 0x1
+```
+
+上面的命令,将会对DragonOS内核进行性能分析,并生成一个火焰图。
+
+详细解释:
+
+- `--format flamegraph`:指定输出格式为火焰图。
+- `--output flame.svg`:指定输出文件名为`flame.svg`。
+- `--interval 200ms`:指定采样间隔为200ms。
+- `--duration 20s`:指定采样时间为20s。
+- `--cpu-mask 0x1`:指定采样的CPU为0号CPU。(这是个按位掩码,也就是说,如果要采样0和1号CPU,那么cpu-mask为0x3)
+
+*更多参数请参考`dadk profile sample --help`.*
+
+::: {note}
+由于采样时会暂停vCPU,因此采样时间不宜过短,否则会影响系统的正常运行。
+:::
+
+经过一段时间的等待,你将会得到一个`flame.svg`文件。
+
+### 3.4 分析火焰图
+
+使用浏览器打开`flame.svg`文件,你将会看到一个火焰图。
+
+你可以通过点击火焰图中的某个函数,来查看它的调用栈。
+
+**你可以右键下面的图片,在新的标签页打开,体验交互效果。**
+
+![](https://web-static2.dragonos.org.cn//longjin/flame2.svg?imageSlim)
+

+ 3 - 0
docs/userland/appdev/c-cpp-quick-start.md

@@ -13,3 +13,6 @@ musl-gcc -static -o hello hello.c
 
 在移植现有程序时,可能需要配置`CFLAGS`和`LDFLAGS`,以及`CPPFLAGS`,以便正确地编译,具体请以实际为准。
 
+## 配置dadk
+
+请参考:[Quick Start | DADK](https://docs.dragonos.org.cn/p/dadk/user-manual/quickstart.html)

+ 2 - 1
docs/userland/appdev/index.rst

@@ -8,4 +8,5 @@
 
    rust-quick-start
    c-cpp-quick-start
-   DADK文档 <https://docs.dragonos.org.cn/p/dadk/>
+   快速使用DADK打包一个应用到DragonOS <https://docs.dragonos.org.cn/p/dadk/user-manual/quickstart.html>
+   DADK完整文档 <https://docs.dragonos.org.cn/p/dadk/>

+ 3 - 8
docs/userland/appdev/rust-quick-start.md

@@ -2,19 +2,14 @@
 
 ## 编译环境
 
-&emsp;&emsp;DragonOS与Linux具有部分二进制兼容性,因此可以使用Linux的Rust编译器进行编译,但是需要进行一些配置:
-
-您可以参考DragonOS的`tools/bootstrap.sh`中,`initialize_userland_musl_toolchain()`函数的实现,进行配置。
-或者,只要运行一下bootstrap.sh就可以了。
-
-主要是因为DragonOS还不支持动态链接,但是默认的工具链里面,包含了动态链接解释器相关的代码,因此像脚本内那样,进行替换就能运行。
+&emsp;&emsp;DragonOS与Linux具有部分二进制兼容性,因此可以使用Linux的Rust编译器进行编译。
 
 ## 配置项目
 
 ### 从模板创建
 
 :::{note}
-该功能需要dadk 0.1.4及以上版本方能支持
+该功能需要dadk 0.2.0及以上版本方能支持。旧版的请参考历史版本的DragonOS文档。
 :::
 
 1. 使用DragonOS的tools目录下的`bootstrap.sh`脚本初始化环境
@@ -30,7 +25,7 @@ cargo generate --git https://git.mirrors.dragonos.org/DragonOS-Community/Rust-Ap
 ```
 
 4. 使用`cargo run`来运行项目
-5. 在DragonOS的`user/dadk/config`目录下,使用`dadk new`命令,创建编译配置,安装到DragonOS的`/`目录下。 
+5. 在DragonOS的`user/dadk/config`目录下,参考模版[userapp_config.toml](https://github.com/DragonOS-Community/DADK/blob/main/dadk-config/templates/config/userapp_config.toml),创建编译配置,安装到DragonOS的`/`目录下。 
 (在dadk的编译命令选项处,请使用Makefile里面的`make install`配置进行编译、安装)
 6. 编译DragonOS即可安装
 

+ 3 - 0
env.mk

@@ -8,3 +8,6 @@ endif
 ifeq ($(EMULATOR), )
 export EMULATOR=__NO_EMULATION__
 endif
+
+
+export DADK?=$(shell which dadk)

+ 1 - 1
tools/BUILD_CONTAINER_VERSION

@@ -1 +1 @@
-v1.6
+v1.7

+ 40 - 0
tools/check_arch.sh

@@ -0,0 +1,40 @@
+#!/bin/bash
+
+BASE_PATH=$(pwd)
+# 定义错误信息
+ARCH_MISMATCH_ERROR="Error: ARCH in env.mk does not match arch in dadk-manifest.toml"
+
+if [ -z "$ARCH" ]; then
+    echo "Error: ARCH environment variable is not set." >&2
+    exit 1
+fi
+
+
+# Check if ROOT_PATH is set
+if [ -n "$ROOT_PATH" ]; then
+    CHECK_PATH="$ROOT_PATH"
+else
+    # Check if the current directory name is "tools"
+    if [ "$(basename "$BASE_PATH")" = "tools" ]; then
+        # Try the parent directory's dadk-manifest
+        CHECK_PATH=$(dirname "$BASE_PATH")/
+    else
+        # Otherwise, check the current directory
+        CHECK_PATH="$BASE_PATH"
+    fi
+fi
+
+echo "Checking $CHECK_PATH"
+
+
+# 读取dadk-manifest.toml文件中的arch字段
+DADK_ARCH=$(grep -oP '(?<=arch = ")[^"]+' $CHECK_PATH/dadk-manifest.toml)
+
+# 检查arch字段是否为x86_64
+if [ "$ARCH" != $DADK_ARCH ]; then
+    echo "$ARCH_MISMATCH_ERROR" >&2
+    exit 1
+else
+    echo "Arch check passed."
+    exit 0
+fi

+ 0 - 27
tools/mount_virt_disk.sh

@@ -1,27 +0,0 @@
-# ======检查是否以sudo运行=================
-uid=`id -u`
-if [ ! $uid == "0" ];then
- echo "请以sudo权限运行"
- exit
-fi
-
-# 检查是否设置ARCH环境变量
-
-if [ ! ${ARCH} ];then
- echo "请设置ARCH环境变量"
- exit
-fi
-
-
-DISK_NAME=disk-${ARCH}.img
-
-echo "Mounting virtual disk image '${DISK_NAME}'..."
-
-LOOP_DEVICE=$(losetup -f --show -P ../bin/${DISK_NAME}) \
-    || exit 1
-
-echo ${LOOP_DEVICE}p1
-
-mkdir -p ../bin/disk_mount/
-mount ${LOOP_DEVICE}p1 ../bin/disk_mount/ 
-lsblk

+ 1 - 1
tools/run-qemu.sh

@@ -65,7 +65,7 @@ UBOOT_VERSION="v2023.10"
 RISCV64_UBOOT_PATH="arch/riscv64/u-boot-${UBOOT_VERSION}-riscv64"
 
 
-DISK_NAME="disk-${ARCH}.img"
+DISK_NAME="disk-image-${ARCH}.img"
 
 QEMU=qemu-system-${ARCH}
 QEMU_DISK_IMAGE="../bin/${DISK_NAME}"

+ 0 - 19
tools/umount_virt_disk.sh

@@ -1,19 +0,0 @@
-# ======检查是否以sudo运行=================
-uid=`id -u`
-if [ ! $uid == "0" ];then
- echo "请以sudo权限运行"
- exit
-fi
-
-if [ ! ${ARCH} ];then
- echo "请设置ARCH环境变量"
- exit
-fi
-
-DISK_NAME=disk-${ARCH}.img
-
-LOOP_DEVICE=$(lsblk | grep disk_mount|sed 's/.*\(loop[0-9]*\)p1.*/\1/1g'|awk 'END{print $0}')
-
-umount -f ../bin/disk_mount/
-losetup -d /dev/$LOOP_DEVICE
-echo $LOOP_DEVICE

+ 25 - 41
tools/write_disk_image.sh

@@ -1,5 +1,5 @@
 ###############################################
-# 该脚本用于将disk_mount目录下的文件写入到disk-${ARCH}.img的第一个分区中,
+# 该脚本用于将文件拷贝到磁盘镜像中,
 #       并在磁盘镜像中安装grub引导程序
 #
 # 用法:bash write_disk_image.sh --bios legacy/uefi
@@ -11,15 +11,16 @@
 echo "ARCH=${ARCH}"
 # 给ARCH变量赋默认值
 export ARCH=${ARCH:=x86_64}
+export DADK=${DADK:=dadk}
 
-DISK_NAME=disk-${ARCH}.img
 
 # 内核映像
 root_folder=$(dirname $(pwd))
 kernel="${root_folder}/bin/kernel/kernel.elf"
-boot_folder="${root_folder}/bin/disk_mount/boot"
+mount_folder=$($DADK -w $root_folder rootfs show-mountpoint || exit 1)
+boot_folder="${mount_folder}/boot"
 GRUB_INSTALL_PATH="${boot_folder}/grub"
-mount_folder="${root_folder}/bin/disk_mount"
+
 ARGS=`getopt -o p -l bios: -- "$@"`
 eval set -- "${ARGS}"
 #echo formatted parameters=[$@]
@@ -67,34 +68,17 @@ if [ ${ARCH} == "i386" ] || [ ${ARCH} == "x86_64" ]; then
     fi
 fi
 
-# 判断是否存在硬盘镜像文件,如果不存在,就创建一个(docker模式下,由于镜像中缺少qemu-img不会创建)
-if [ ! -f "${root_folder}/bin/${DISK_NAME}" ]; then
-    echo "创建硬盘镜像文件..."
-    case "$1" in
-        --bios) 
-        case "$2" in
-                uefi)
-            sudo ARCH=${ARCH} bash ./create_hdd_image.sh -P MBR #GPT分区    用GPT分区uefi启动不了 内核没有针对gpt分区表来做处理
-            ;;
-                legacy)
-            sudo ARCH=${ARCH} bash ./create_hdd_image.sh -P MBR #MBR分区
-            ;;
-            esac       
-        ;;
-    *)
-        # 默认创建MBR分区
-        sudo ARCH=${ARCH} bash ./create_hdd_image.sh -P MBR #MBR分区
-        ;;
-    esac
-fi
+# 判断是否存在硬盘镜像文件,如果不存在,就创建一个
+echo "创建硬盘镜像文件..."
+$DADK -w $root_folder rootfs create --skip-if-exists || exit 1
+
+$DADK -w $root_folder rootfs mount || exit 1
 
-# 拷贝程序到硬盘
-mkdir -p ${root_folder}/bin/disk_mount
-bash mount_virt_disk.sh || exit 1
 
-LOOP_DEVICE=$(lsblk | grep disk_mount|sed 's/.*\(loop[0-9]*\)p1.*/\1/1g'|awk 'END{print $0}')
-echo $LOOP_DEVICE
 
+LOOP_DEVICE=$($DADK -w $root_folder rootfs show-loop-device || exit 1)
+echo $LOOP_DEVICE
+echo ${mount_folder}
 # mkdir -p ${GRUB_INSTALL_PATH}
 
 # 检测grub文件夹是否存在
@@ -107,21 +91,20 @@ fi
 
 
 if [ ${ARCH} == "i386" ] || [ ${ARCH} == "x86_64" ]; then
-    cp ${kernel} ${root_folder}/bin/disk_mount/boot/
+    cp ${kernel} ${mount_folder}/boot/
 fi
 
 # 拷贝用户程序到磁盘镜像
-mkdir -p ${root_folder}/bin/disk_mount/bin
-mkdir -p ${root_folder}/bin/disk_mount/dev
-mkdir -p ${root_folder}/bin/disk_mount/proc
-mkdir -p ${root_folder}/bin/disk_mount/usr
-touch ${root_folder}/bin/disk_mount/dev/keyboard.dev
-cp -r ${root_folder}/bin/sysroot/* ${root_folder}/bin/disk_mount/
+mkdir -p ${mount_folder}/bin
+mkdir -p ${mount_folder}/dev
+mkdir -p ${mount_folder}/proc
+mkdir -p ${mount_folder}/usr
+cp -r ${root_folder}/bin/sysroot/* ${mount_folder}/
 
 # 设置 grub 相关数据
 if [ ${ARCH} == "i386" ] || [ ${ARCH} == "x86_64" ]; then
     
-    touch ${root_folder}/bin/disk_mount/boot/grub/grub.cfg
+    touch ${mount_folder}/boot/grub/grub.cfg
 cfg_content='set timeout=15
     set default=0
     insmod efi_gop
@@ -154,7 +137,7 @@ if [ "${INSTALL_GRUB_TO_IMAGE}" = "1" ];then
                 ;;
                     legacy) #传统bios
                     if [ ${ARCH} == "x86_64" ];then
-                        ${GRUB_PATH_I386_LEGACY_INSTALL} --target=i386-pc --boot-directory=${boot_folder} /dev/$LOOP_DEVICE
+                        ${GRUB_PATH_I386_LEGACY_INSTALL} --target=i386-pc --boot-directory=${boot_folder} $LOOP_DEVICE
                     elif [ ${ARCH} == "riscv64" ];then
                         install_riscv64_efi
                     else
@@ -165,11 +148,12 @@ if [ "${INSTALL_GRUB_TO_IMAGE}" = "1" ];then
             ;;
         *)
         #传统bios
-        ${GRUB_PATH_I386_LEGACY_INSTALL} --target=i386-pc --boot-directory=${boot_folder} /dev/$LOOP_DEVICE
+        ${GRUB_PATH_I386_LEGACY_INSTALL} --target=i386-pc --boot-directory=${boot_folder} $LOOP_DEVICE
         ;;
-            
+
     esac
 fi
 
 sync
-bash umount_virt_disk.sh
+
+$DADK -w $root_folder rootfs umount || exit 1

+ 5 - 7
user/Makefile

@@ -2,7 +2,7 @@ user_sub_dirs = apps
 
 DADK_VERSION=$(shell dadk -V | awk 'END {print $$2}')
 # 最小的DADK版本
-MIN_DADK_VERSION = 0.1.11
+MIN_DADK_VERSION = 0.2.0
 DADK_CACHE_DIR = $(ROOT_PATH)/bin/dadk_cache
 
 ECHO:
@@ -36,15 +36,12 @@ endif
 .PHONY: dadk_run
 dadk_run: install_dadk
 	mkdir -p $(DADK_CACHE_DIR)
-	dadk --config-dir dadk/config --cache-dir $(DADK_CACHE_DIR) --dragonos-dir $(ROOT_PATH)/bin/sysroot build
-	dadk --config-dir dadk/config --cache-dir $(DADK_CACHE_DIR) --dragonos-dir $(ROOT_PATH)/bin/sysroot install
+	$(DADK) user build -w $(ROOT_PATH)
+	$(DADK) user install -w $(ROOT_PATH)
 
 .PHONY: dadk_clean
 dadk_clean: install_dadk
 	@echo dadk_clean
-# 不运行dadk clean的原因是,把clean的工作交给应用程序自己去做,这样可以节省编译时间
-#dadk --config-dir dadk/config --cache-dir $(DADK_CACHE_DIR) --dragonos-dir $(ROOT_PATH)/bin/sysroot clean src
-#dadk --config-dir dadk/config --cache-dir $(DADK_CACHE_DIR) --dragonos-dir $(ROOT_PATH)/bin/sysroot clean target
 
 all:
 	mkdir -p $(ROOT_PATH)/bin/sysroot
@@ -54,7 +51,8 @@ all:
 
 	@echo 用户态程序编译完成
 
-copy_sysconfig: dadk_run
+.PHONY: copy_sysconfig
+copy_sysconfig:
 	cp -r sysconfig/* $(ROOT_PATH)/bin/sysroot/
 
 

+ 0 - 25
user/dadk/config/about.dadk

@@ -1,25 +0,0 @@
-{
-    "name": "about",
-    "version": "0.1.0",
-    "description": "",
-    "rust_target": null,
-    "task_type": {
-      "BuildFromSource": {
-        "Local": {
-          "path": "apps/about"
-        }
-      }
-    },
-    "depends": [],
-    "build": {
-      "build_command": "make install"
-    },
-    "install": {
-      "in_dragonos_path": "/bin"
-    },
-    "clean": {
-      "clean_command": "make clean"
-    },
-    "envs": [],
-    "target_arch": ["x86_64"]
-  }

+ 36 - 0
user/dadk/config/about.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "about"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = ""
+# (可选)是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/about"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 23
user/dadk/config/clear-0.1.0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "clear",
-  "version": "0.1.0",
-  "description": "清屏",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/clear"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "target_arch": ["x86_64"]
-}

+ 44 - 0
user/dadk/config/clear-0.1.0.toml

@@ -0,0 +1,44 @@
+# 用户程序名称
+name = "clear"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "清屏"
+# (可选)是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/clear"
+
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 由于原配置中没有依赖项,这里忽略[[depends]]部分
+# (可选)环境变量
+# 由于原配置中没有环境变量,这里忽略[[envs]]部分

+ 0 - 27
user/dadk/config/core_utils-9.4.0.dadk

@@ -1,27 +0,0 @@
-{
-  "name": "Core utils",
-  "version": "9.4.0",
-  "description": "GNU Core utils",
-  "task_type": {
-    "BuildFromSource": {
-      "Archive": {
-        "url": "https://mirrors.dragonos.org.cn/pub/third_party/gnu/coreutils/coreutils-9.4.tar.xz"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "./configure CC=x86_64-linux-musl-gcc CFLAGS=-static && make -j $(nproc) && DESTDIR=$DADK_CURRENT_BUILD_DIR make install"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-
-  "build_once": true,
-
-  "install_once": true,
-  "target_arch": ["x86_64"]
-}

+ 39 - 0
user/dadk/config/core_utils-9.4.0.toml

@@ -0,0 +1,39 @@
+# 用户程序名称
+name = "core utils"
+# 版本号
+version = "9.4.0"
+# 用户程序描述信息
+description = "GNU Core utils"
+# (可选)是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = true
+#  (可选) 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = true
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "archive"
+# 路径或URL
+source-path = "https://mirrors.dragonos.org.cn/pub/third_party/gnu/coreutils/coreutils-9.4.tar.xz"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "./configure CC=x86_64-linux-musl-gcc CFLAGS=-static && make -j $(nproc) && DESTDIR=$DADK_CURRENT_BUILD_DIR make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 此处无依赖项,故忽略

+ 0 - 24
user/dadk/config/dmesg-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "dmesg",
-  "version": "0.1.0",
-  "description": "查看日志",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/dmesg"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install -j $(nproc)"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 47 - 0
user/dadk/config/dmesg-0.1.0.toml

@@ -0,0 +1,47 @@
+# 用户程序名称
+name = "dmesg"
+
+# 版本号
+version = "0.1.0"
+
+# 用户程序描述信息
+description = "查看内核日志"
+
+# 是否只构建一次
+build-once = false
+
+# 是否只安装一次
+install-once = false
+
+# 目标架构
+target-arch = ["x86_64"]
+
+# 任务源
+[task-source]
+# 构建类型
+type = "build-from-source"
+# 构建来源
+source = "local"
+# 路径或URL
+source-path = "user/apps/dmesg"
+
+# 构建相关信息
+[build]
+# 构建命令
+build-command = "make install -j $(nproc)"
+
+# 安装相关信息
+[install]
+# 安装到DragonOS的路径
+in-dragonos-path = "/bin"
+
+# 清除相关信息
+[clean]
+# 清除命令
+clean-command = "make clean"
+
+# 依赖项
+# 注意:因为没有依赖项,所以这里不包含[[depends]]部分
+
+# 环境变量
+# 注意:因为没有环境变量,所以这里不包含[[envs]]部分

+ 0 - 34
user/dadk/config/dog_0_1_0.dadk

@@ -1,34 +0,0 @@
-{
-  "name": "dog",
-  "version": "0.1.0",
-  "description": "dns client",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Git": {
-        "url": "https://git.mirrors.dragonos.org.cn/DragonOS-Community/dog.git",
-        "branch": null,
-        "revision": "6f2c0c8f12"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [
-    {
-      "key": "CC",
-      "value": "x86_64-linux-musl-gcc"
-    }
-  ],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["x86_64"]
-}

+ 51 - 0
user/dadk/config/dog_0_1_0.toml

@@ -0,0 +1,51 @@
+# 用户程序名称
+name = "dog"
+
+# 版本号
+version = "0.1.0"
+
+# 用户程序描述信息
+description = "dns client"
+
+# 目标架构
+target-arch = ["x86_64"]
+
+# 是否只构建一次
+build-once = false
+
+# 是否只安装一次
+install-once = false
+
+# 任务源
+[task-source]
+# 构建类型
+type = "build-from-source"
+# 构建来源
+source = "git"
+# 路径或URL
+source-path = "https://git.mirrors.dragonos.org.cn/DragonOS-Community/dog.git"
+# git标签或分支
+revision = "6f2c0c8f12"
+
+# 构建相关信息
+[build]
+# 构建命令
+build-command = "make install"
+
+# 安装相关信息
+[install]
+# 安装到DragonOS的路径
+in-dragonos-path = "/"
+
+# 清除相关信息
+[clean]
+# 清除命令
+clean-command = "make clean"
+
+# 依赖项
+# 注意:因为没有依赖项,所以这里不包含[[depends]]部分
+
+# 环境变量
+[[envs]]
+key = "CC"
+value = "x86_64-linux-musl-gcc"

+ 0 - 24
user/dadk/config/dragon_reach-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "DragonReach",
-  "version": "0.1.0",
-  "description": "init程序",
-  "task_type": {
-    "BuildFromSource": {
-      "Git": {
-        "url" : "https://git.mirrors.dragonos.org.cn/DragonOS-Community/DragonReach.git",
-        "revision": "e945c217b3"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "target_arch": ["x86_64"]
-}

+ 49 - 0
user/dadk/config/dragon_reach-0.1.0.toml

@@ -0,0 +1,49 @@
+# 用户程序名称
+name = "DragonReach"
+
+# 版本号
+version = "0.1.0"
+
+# 用户程序描述信息
+description = "init程序"
+
+# 目标架构
+target-arch = ["x86_64"]
+
+# 是否只构建一次
+build-once = false
+
+# 是否只安装一次
+install-once = false
+
+# 任务源
+[task-source]
+# 构建类型
+type = "build-from-source"
+# 构建来源
+source = "git"
+# 路径或URL
+source-path = "https://git.mirrors.dragonos.org.cn/DragonOS-Community/DragonReach.git"
+# git标签或分支
+revision = "e945c217b3"
+
+# 构建相关信息
+[build]
+# 构建命令
+build-command = "make install"
+
+# 安装相关信息
+[install]
+# 安装到DragonOS的路径
+in-dragonos-path = "/"
+
+# 清除相关信息
+[clean]
+# 清除命令
+clean-command = "make clean"
+
+# 依赖项
+# 注意:因为没有依赖项,所以这里不包含[[depends]]部分
+
+# 环境变量
+# 注意:因为没有环境变量,所以这里不包含[[envs]]部分

+ 0 - 24
user/dadk/config/held-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "Held",
-  "version": "0.1.0",
-  "description": "中断文本编辑器",
-  "task_type": {
-    "BuildFromSource": {
-      "Git": {
-        "url" : "https://git.mirrors.dragonos.org.cn/DragonOS-Community/Held.git",
-        "revision": "f192df4"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install-dragonos"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "target_arch": ["x86_64"]
-}

+ 49 - 0
user/dadk/config/held-0.1.0.toml

@@ -0,0 +1,49 @@
+# 用户程序名称
+name = "Held"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "终端文本编辑器"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "git"
+# 路径或URL
+source-path = "https://git.mirrors.dragonos.org.cn/DragonOS-Community/Held.git"
+# git标签或分支
+# 注意: branch和revision只能二选一,且source要设置为"git"
+revision = "f192df4"
+
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install-dragonos"
+# 安装相关信息
+
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 此处没有依赖项,因此省略[[depends]]部分
+# (可选)环境变量
+# 此处没有环境变量,因此省略[[envs]]部分

+ 0 - 24
user/dadk/config/http_server-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "Http_Server",
-  "version": "0.1.0",
-  "description": "一个简单的http server",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/http_server"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 40 - 0
user/dadk/config/http_server-0.1.0.toml

@@ -0,0 +1,40 @@
+# 用户程序名称
+name = "Http_Server"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "一个简单的http server"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/http_server"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]

+ 0 - 28
user/dadk/config/musl_1_2_4.dadk

@@ -1,28 +0,0 @@
-{
-  "name": "musl",
-  "version": "1.2.4",
-  "description": "musl libc",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Archive": {
-        "url": "https://mirrors.dragonos.org.cn/pub/third_party/musl/musl-1.2.4.tar.gz"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "touch config.mak && DESTDIR=$DADK_CURRENT_BUILD_DIR make install -j $(nproc)"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": true,
-
-  "install_once": true,
-  "target_arch": ["x86_64"]
-}

+ 40 - 0
user/dadk/config/musl_1_2_4.toml

@@ -0,0 +1,40 @@
+# 用户程序名称
+name = "musl"
+# 版本号
+version = "1.2.4"
+# 用户程序描述信息
+description = "musl libc"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = true
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = true
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "archive"
+# 路径或URL
+source-path = "https://mirrors.dragonos.org.cn/pub/third_party/musl/musl-1.2.4.tar.gz"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "touch config.mak && DESTDIR=$DADK_CURRENT_BUILD_DIR make install -j $(nproc)"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]

+ 0 - 24
user/dadk/config/nova_shell-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "NovaShell",
-  "version": "0.1.0",
-  "description": "NovaShell程序",
-  "task_type": {
-    "BuildFromSource": {
-      "Git": {
-        "url": "https://git.mirrors.dragonos.org.cn/DragonOS-Community/NovaShell.git",
-        "revision": "cb835e03e4"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "target_arch": ["x86_64"]
-}

+ 44 - 0
user/dadk/config/nova_shell-0.1.0.toml

@@ -0,0 +1,44 @@
+# 用户程序名称
+name = "NovaShell"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "NovaShell程序"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "git"
+# 路径或URL
+source-path = "https://git.mirrors.dragonos.org.cn/DragonOS-Community/NovaShell.git"
+# git标签或分支
+# 注意: branch和revision只能二选一,且source要设置为"git"
+revision = "cb835e03e4"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 由于原配置中没有依赖项,此处省略[[depends]]部分
+# (可选)环境变量
+# 由于原配置中没有环境变量,此处省略[[envs]]部分

+ 0 - 27
user/dadk/config/riscv_init-0.1.0.dadk

@@ -1,27 +0,0 @@
-{
-  "name": "riscv_init",
-  "version": "0.1.0",
-  "description": "临时的riscv下的初始化程序",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/riscv_init"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["riscv64"]
-}

+ 40 - 0
user/dadk/config/riscv_init-0.1.0.toml

@@ -0,0 +1,40 @@
+# 用户程序名称
+name = "riscv_init"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "临时的riscv下的初始化程序"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["riscv64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/riscv_init"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]

+ 0 - 25
user/dadk/config/tar_1_35.dadk

@@ -1,25 +0,0 @@
-{
-  "name": "tar",
-  "version": "1.35",
-  "description": "gnu tar",
-  "rust_target": null,
-  "task_type": {
-    "InstallFromPrebuilt": {
-      "Archive": {
-        "url": "https://mirrors.dragonos.org.cn/pub/third_party/gnu/tar/tar-1.35-x86_64-linux-gnu.tar.xz"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    
-  },
-  "install": {
-    "in_dragonos_path": "/usr"
-  },
-  "clean": {
-    "clean_command": null
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 39 - 0
user/dadk/config/tar_1_35.toml

@@ -0,0 +1,39 @@
+# 用户程序名称
+name = "tar"
+# 版本号
+version = "1.35"
+# 用户程序描述信息
+description = "gnu tar"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "install-from-prebuilt"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "archive"
+# 路径或URL
+source-path = "https://mirrors.dragonos.org.cn/pub/third_party/gnu/tar/tar-1.35-x86_64-linux-gnu.tar.xz"
+
+[build]
+
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/usr"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = ""
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]

+ 0 - 27
user/dadk/config/test_alarm_0_1_0.dadk

@@ -1,27 +0,0 @@
-{
-  "name": "test_alarm",
-  "version": "0.1.0",
-  "description": "test for alarm",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_alarm"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["x86_64"]
-}

+ 41 - 0
user/dadk/config/test_alarm_0_1_0.toml

@@ -0,0 +1,41 @@
+# 用户程序名称
+name = "test_alarm"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "test for alarm"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_alarm"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 由于原配置中没有依赖项,这里忽略[[depends]]
+# (可选)环境变量
+# 由于原配置中没有环境变量,这里忽略[[envs]]

+ 0 - 27
user/dadk/config/test_backlog_0_1_0.dadk

@@ -1,27 +0,0 @@
-{
-  "name": "test-backlog",
-  "version": "0.1.0",
-  "description": "test the tcp backlog",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test-backlog"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["x86_64"]
-}

+ 40 - 0
user/dadk/config/test_backlog_0_1_0.toml

@@ -0,0 +1,40 @@
+# 用户程序名称
+name = "test-backlog"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "test the tcp backlog"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test-backlog"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]

+ 0 - 24
user/dadk/config/test_bind-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_bind",
-  "version": "0.1.0",
-  "description": "一个简单的test bind",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_bind"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 40 - 0
user/dadk/config/test_bind-0.1.0.toml

@@ -0,0 +1,40 @@
+# 用户程序名称
+name = "test_bind"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "一个简单的test bind"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_bind"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]

+ 0 - 25
user/dadk/config/test_blockcache_0_1_0.dadk

@@ -1,25 +0,0 @@
-{
-  "name": "test-blockcache",
-  "version": "0.1.0",
-  "description": "用于测试blockcach小程序",
-  "rust_target": "x86_64-unknown-dragonos",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test-blockcache"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 42 - 0
user/dadk/config/test_blockcache_0_1_0.toml

@@ -0,0 +1,42 @@
+# 用户程序名称
+name = "test-blockcache"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "用于测试blockcach小程序"
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test-blockcache"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"

+ 0 - 29
user/dadk/config/test_chown_0_1_0.dadk

@@ -1,29 +0,0 @@
-{
-  "name": "test-chown",
-  "version": "0.1.0",
-  "description": "chown系列系统调用",
-  "rust_target": "x86_64-unknown-dragonos",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test-chown"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": [
-    "x86_64"
-  ]
-}

+ 46 - 0
user/dadk/config/test_chown_0_1_0.toml

@@ -0,0 +1,46 @@
+# 用户程序名称
+name = "test-chown"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "chown系列系统调用"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from-source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test-chown"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"

+ 0 - 23
user/dadk/config/test_cred-0.1.0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_cred",
-  "version": "0.1.0",
-  "description": "测试cred",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_cred"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "target_arch": ["x86_64"]
-}

+ 51 - 0
user/dadk/config/test_cred-0.1.0.toml

@@ -0,0 +1,51 @@
+# 用户程序名称
+name = "test_cred"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试cred"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_cred"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# [[depends]]
+# name = "depend2"
+# version = "0.1.2"
+# (可选)环境变量
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"
+# [[envs]]
+# key = "LD_LIBRARY_PATH"
+# value = "/usr/lib"

+ 0 - 23
user/dadk/config/test_dup3_0_1_0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_dup3",
-  "version": "0.1.0",
-  "description": "测试dup3",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_dup3"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "target_arch": ["x86_64"]
-}

+ 51 - 0
user/dadk/config/test_dup3_0_1_0.toml

@@ -0,0 +1,51 @@
+# 用户程序名称
+name = "test_dup3"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试dup3"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_dup3"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# [[depends]]
+# name = "depend2"
+# version = "0.1.2"
+# (可选)环境变量
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"
+# [[envs]]
+# key = "LD_LIBRARY_PATH"
+# value = "/usr/lib"

+ 0 - 23
user/dadk/config/test_ebpf_0_1_0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_ebpf",
-  "version": "0.1.0",
-  "description": "to test eBPF",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_ebpf"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "target_arch": ["x86_64"]
-}

+ 37 - 0
user/dadk/config/test_ebpf_0_1_0.toml

@@ -0,0 +1,37 @@
+# 用户程序名称
+name = "test_ebpf"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "to test eBPF"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_ebpf"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+

+ 0 - 23
user/dadk/config/test_eventfd_0_1_0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_eventfd",
-  "version": "0.1.0",
-  "description": "test_eventfd",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_eventfd"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "target_arch": ["x86_64"]
-}

+ 32 - 0
user/dadk/config/test_eventfd_0_1_0.toml

@@ -0,0 +1,32 @@
+# 用户程序名称
+name = "test_eventfd"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "test_eventfd"
+# 目标架构
+target-arch = ["x86_64"]
+
+# 任务源
+[task-source]
+# 构建类型
+type = "build-from-source"
+# 构建来源
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_eventfd"
+
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 23
user/dadk/config/test_filemap-0.1.0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_filemap",
-  "version": "0.1.0",
-  "description": "测试filemap",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_filemap"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_filemap-0.1.0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test_filemap"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试filemap"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_filemap"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 25
user/dadk/config/test_for_robustfutex_0_1_0.dadk

@@ -1,25 +0,0 @@
-{
-  "name": "test-for-robustfutex",
-  "version": "0.1.0",
-  "description": "some tests for robust futex",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test-for-robustfutex"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_for_robustfutex_0_1_0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test-for-robustfutex"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "some tests for robust futex"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test-for-robustfutex"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 23
user/dadk/config/test_fstat-0.1.0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_fstat",
-  "version": "0.1.0",
-  "description": "一个用来测试fstat能够正常运行的app",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_fstat"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_fstat-0.1.0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test_fstat"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "一个用来测试fstat能够正常运行的app"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_fstat"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 27
user/dadk/config/test_fstatfs_0_1_0.dadk

@@ -1,27 +0,0 @@
-{
-  "name": "test_fstatfs",
-  "version": "0.1.0",
-  "description": "测试fstatfs",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_fstatfs"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["x86_64"]
-}

+ 41 - 0
user/dadk/config/test_fstatfs_0_1_0.toml

@@ -0,0 +1,41 @@
+# 用户程序名称
+name = "test_fstatfs"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试fstatfs"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_fstatfs"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 由于原文件中依赖项为空,此处省略[[depends]]部分
+# (可选)环境变量
+# 由于原文件中环境变量为空,此处省略[[envs]]部分

+ 0 - 24
user/dadk/config/test_gettimeofday-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_gettimeofday",
-  "version": "0.1.0",
-  "description": "一个用来测试gettimeofday能够正常运行的app",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_gettimeofday"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 37 - 0
user/dadk/config/test_gettimeofday-0.1.0.toml

@@ -0,0 +1,37 @@
+# 用户程序名称
+name = "test_gettimeofday"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "一个用来测试gettimeofday能够正常运行的app"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_gettimeofday"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+

+ 0 - 25
user/dadk/config/test_kvm_0_1_0.dadk

@@ -1,25 +0,0 @@
-{
-  "name": "test_kvm",
-  "version": "0.1.0",
-  "description": "测试kvm的程序",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_kvm"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 46 - 0
user/dadk/config/test_kvm_0_1_0.toml

@@ -0,0 +1,46 @@
+# 用户程序名称
+name = "test_kvm"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试kvm的程序"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_kvm"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"

+ 0 - 27
user/dadk/config/test_lo_0_1_0.dadk

@@ -1,27 +0,0 @@
-{
-  "name": "test_lo",
-  "version": "0.1.0",
-  "description": "test for lo interface",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_lo"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_lo_0_1_0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test_lo"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "test for lo interface"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_lo"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 23
user/dadk/config/test_mkfifo-0.1.0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_mkfifo",
-  "version": "0.1.0",
-  "description": "一个用来测试mkfifo能够正常运行的app",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_mkfifo"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_mkfifo-0.1.0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test_mkfifo"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "一个用来测试mkfifo能够正常运行的app"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_mkfifo"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 23
user/dadk/config/test_mount_1_0_0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_mount",
-  "version": "1.0.0",
-  "description": "to test user mode mount",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test-mount"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "target_arch": ["x86_64"]
-}

+ 51 - 0
user/dadk/config/test_mount_1_0_0.toml

@@ -0,0 +1,51 @@
+# 用户程序名称
+name = "test_mount"
+# 版本号
+version = "1.0.0"
+# 用户程序描述信息
+description = "to test user mode mount"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test-mount"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# [[depends]]
+# name = "depend2"
+# version = "0.1.2"
+# (可选)环境变量
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"
+# [[envs]]
+# key = "LD_LIBRARY_PATH"
+# value = "/usr/lib"

+ 0 - 25
user/dadk/config/test_namespace.dadk

@@ -1,25 +0,0 @@
-{
-  "name": "test_namespace",
-  "version": "0.1.0",
-  "description": "test namespace",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_namespace"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 52 - 0
user/dadk/config/test_namespace.toml

@@ -0,0 +1,52 @@
+# 用户程序名称
+name = "test_namespace"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "test namespace"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_namespace"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# [[depends]]
+# name = "depend2"
+# version = "0.1.2"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"
+# [[envs]]
+# key = "LD_LIBRARY_PATH"
+# value = "/usr/lib"

+ 0 - 25
user/dadk/config/test_overlayfs.dadk

@@ -1,25 +0,0 @@
-{
-  "name": "test_overlayfs",
-  "version": "0.1.0",
-  "description": "test overlayfs",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_overlayfs"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 46 - 0
user/dadk/config/test_overlayfs.toml

@@ -0,0 +1,46 @@
+# 用户程序名称
+name = "test_overlayfs"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "test overlayfs"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_overlayfs"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"

+ 0 - 24
user/dadk/config/test_pty-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_pty",
-  "version": "0.1.0",
-  "description": "简单的pty测试程序",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_pty"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install -j $(nproc)"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 46 - 0
user/dadk/config/test_pty-0.1.0.toml

@@ -0,0 +1,46 @@
+# 用户程序名称
+name = "test_pty"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "简单的pty测试程序"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_pty"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install -j $(nproc)"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"

+ 0 - 24
user/dadk/config/test_ramfs-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_ramfs",
-  "version": "0.1.0",
-  "description": "ramfs test bench",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_ramfs"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_ramfs-0.1.0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test_ramfs"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "ramfs test bench"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_ramfs"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 24
user/dadk/config/test_shm-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_shm",
-  "version": "0.1.0",
-  "description": "测试共享内存",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_shm"
-      }
-    }
-  },
-  "depends": [ ],
-  "build": {
-    "build_command": "make install -j $(nproc)"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 52 - 0
user/dadk/config/test_shm-0.1.0.toml

@@ -0,0 +1,52 @@
+# 用户程序名称
+name = "test_shm"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试共享内存"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_shm"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install -j $(nproc)"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# [[depends]]
+# name = "depend2"
+# version = "0.1.2"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"
+# [[envs]]
+# key = "LD_LIBRARY_PATH"
+# value = "/usr/lib"

+ 0 - 24
user/dadk/config/test_sigint-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_sigint",
-  "version": "0.1.0",
-  "description": "一个用来测试sigint信号传递的app",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_sigint"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_sigint-0.1.0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test_sigint"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "一个用来测试sigint信号传递的app"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_sigint"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 24
user/dadk/config/test_signal-0.1.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_signal",
-  "version": "0.1.0",
-  "description": "一个用来测试signal能够正常运行的app",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_signal"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 41 - 0
user/dadk/config/test_signal-0.1.0.toml

@@ -0,0 +1,41 @@
+# 用户程序名称
+name = "test_signal"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "一个用来测试signal能够正常运行的app"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_signal"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 由于原文件中依赖项为空,此处省略[[depends]]部分
+# (可选)环境变量
+# 由于原文件中环境变量为空,此处省略[[envs]]部分

+ 0 - 23
user/dadk/config/test_socket-0.1.0.dadk

@@ -1,23 +0,0 @@
-{
-  "name": "test_socket",
-  "version": "0.1.0",
-  "description": "测试socket",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_socket"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "target_arch": ["x86_64"]
-}

+ 36 - 0
user/dadk/config/test_socket-0.1.0.toml

@@ -0,0 +1,36 @@
+# 用户程序名称
+name = "test_socket"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试socket"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_socket"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"

+ 0 - 24
user/dadk/config/test_sqlite3-3.42.0.dadk

@@ -1,24 +0,0 @@
-{
-  "name": "test_sqlite3",
-  "version": "3.42.0",
-  "description": "测试sqlite3",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_sqlite3"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make download_sqlite3 && make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "target_arch": ["x86_64"]
-}

+ 52 - 0
user/dadk/config/test_sqlite3-3.42.0.toml

@@ -0,0 +1,52 @@
+# 用户程序名称
+name = "test_sqlite3"
+# 版本号
+version = "3.42.0"
+# 用户程序描述信息
+description = "测试sqlite3"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_sqlite3"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make download_sqlite3 && make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# [[depends]]
+# name = "depend1"
+# version = "0.1.1"
+# [[depends]]
+# name = "depend2"
+# version = "0.1.2"
+# (可选)环境变量
+# 注意:如果没有环境变量,忽略此项,不允许只留一个[[envs]]
+# [[envs]]
+# key = "PATH"
+# value = "/usr/bin"
+# [[envs]]
+# key = "LD_LIBRARY_PATH"
+# value = "/usr/lib"

+ 0 - 27
user/dadk/config/test_statfs_0_1_0.dadk

@@ -1,27 +0,0 @@
-{
-  "name": "test_statfs",
-  "version": "0.1.0",
-  "description": "测试statfs",
-  "rust_target": null,
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_statfs"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/bin"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["x86_64"]
-}

+ 41 - 0
user/dadk/config/test_statfs_0_1_0.toml

@@ -0,0 +1,41 @@
+# 用户程序名称
+name = "test_statfs"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "测试statfs"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_statfs"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/bin"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 由于原JSON中依赖项为空,此处省略[[depends]]部分
+# (可选)环境变量
+# 由于原JSON中环境变量为空,此处省略[[envs]]部分

+ 0 - 26
user/dadk/config/test_statx_0_1_0.dadk

@@ -1,26 +0,0 @@
-{
-  "name": "test_statx",
-  "version": "0.1.0",
-  "description": "statx测试",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test_statx"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": ["x86_64"]
-}

+ 41 - 0
user/dadk/config/test_statx_0_1_0.toml

@@ -0,0 +1,41 @@
+# 用户程序名称
+name = "test_statx"
+# 版本号
+version = "0.1.0"
+# 用户程序描述信息
+description = "statx测试"
+# (可选)默认: false 是否只构建一次,如果为true,DADK会在构建成功后,将构建结果缓存起来,下次构建时,直接使用缓存的构建结果
+build-once = false
+#  (可选) 默认: false 是否只安装一次,如果为true,DADK会在安装成功后,不再重复安装
+install-once = false
+# 目标架构
+# 可选值:"x86_64", "aarch64", "riscv64"
+target-arch = ["x86_64"]
+# 任务源
+[task-source]
+# 构建类型
+# 可选值:"build-from_source", "install-from-prebuilt"
+type = "build-from-source"
+# 构建来源
+# "build_from_source" 可选值:"git", "local", "archive"
+# "install_from_prebuilt" 可选值:"local", "archive"
+source = "local"
+# 路径或URL
+source-path = "user/apps/test_statx"
+# 构建相关信息
+[build]
+# (可选)构建命令
+build-command = "make install"
+# 安装相关信息
+[install]
+# (可选)安装到DragonOS的路径
+in-dragonos-path = "/"
+# 清除相关信息
+[clean]
+# (可选)清除命令
+clean-command = "make clean"
+# (可选)依赖项
+# 注意:如果没有依赖项,忽略此项,不允许只留一个[[depends]]
+# 由于依赖项为空,此处忽略
+# (可选)环境变量
+# 由于环境变量为空,此处忽略

+ 0 - 29
user/dadk/config/test_symlink_0_1_0.dadk

@@ -1,29 +0,0 @@
-{
-  "name": "test-symlink",
-  "version": "0.1.0",
-  "description": "测试symlink系统调用",
-  "rust_target": "x86_64-unknown-dragonos",
-  "task_type": {
-    "BuildFromSource": {
-      "Local": {
-        "path": "apps/test-symlink"
-      }
-    }
-  },
-  "depends": [],
-  "build": {
-    "build_command": "make install"
-  },
-  "install": {
-    "in_dragonos_path": "/"
-  },
-  "clean": {
-    "clean_command": "make clean"
-  },
-  "envs": [],
-  "build_once": false,
-  "install_once": false,
-  "target_arch": [
-    "x86_64"
-  ]
-}

Kaikkia tiedostoja ei voida näyttää, sillä liian monta tiedostoa muuttui tässä diffissä