Compare commits
30
Commits
de4130ff88
..
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d13f6cb8b3 | ||
|
|
0eb4535dc8 | ||
|
|
94c8d59201 | ||
|
|
5fd695266f | ||
|
|
698e123a26 | ||
|
|
751071d670 | ||
|
|
af260c1610 | ||
|
|
caa636018b | ||
|
|
94aea3524e | ||
|
|
906df8b40a | ||
|
|
38d3fd5667 | ||
|
|
eb3ca273b4 | ||
|
|
af92cd0a53 | ||
|
|
61da61b28e | ||
|
|
c042d2c391 | ||
|
|
1ccae2ebed | ||
|
|
ead5e96c13 | ||
|
|
47bb9119dd | ||
|
|
20c8751540 | ||
|
|
5cfc64b518 | ||
|
|
3ada35e863 | ||
|
|
df5cc85fa7 | ||
|
|
72c5619f59 | ||
|
|
f9a2a2e0d9 | ||
|
|
41cca8c4e1 | ||
|
|
c467f2fa0b | ||
|
|
5467577b07 | ||
|
|
9955c87eaf | ||
|
|
34048913c6 | ||
|
|
d68aee0411 |
@@ -143,6 +143,24 @@
|
|||||||
|
|
||||||
其中 `%~dp0` 表示当前 `.bat` 文件所在目录。上述模板配置假设配置文件和相关工具脚本与 `.bat` 在同一目录,并在该目录下的 `build` 文件夹中创建工程。该脚本实现了自动创建工程并完成相关配置最后加载对应 IDE 的功能。
|
其中 `%~dp0` 表示当前 `.bat` 文件所在目录。上述模板配置假设配置文件和相关工具脚本与 `.bat` 在同一目录,并在该目录下的 `build` 文件夹中创建工程。该脚本实现了自动创建工程并完成相关配置最后加载对应 IDE 的功能。
|
||||||
|
|
||||||
|
## 常见问题
|
||||||
|
|
||||||
|
1. 在 Xilinx Vitis 中打开构建的工程后,点击符号时可能无法跳转,并且在 IDE 左下角会显示如下错误信息:
|
||||||
|
|
||||||
|
```plaintext
|
||||||
|
Could not find symbol 'XXXX' in index
|
||||||
|
```
|
||||||
|
|
||||||
|
这是因为源文件在导入时被直接链接或复制到了工程目录中,未触发 C++ Indexer 更新索引。此外,新版本的 Vitis 没有直接的命令或 UI 选项来重建或更新索引。最简单的解决方法是随意打开一个源文件,在任意行末输入一个空格并保存。IDE 会自动删除该空格,不会对源文件造成任何更改,但此操作可触发索引的自动更新。
|
||||||
|
|
||||||
|
2. 在 Windows 上运行 `.bat` 构建脚本时可能会出现以下错误:
|
||||||
|
|
||||||
|
```plaintext
|
||||||
|
Failed to create file symbolic link using mklink: 你没有足够的权限执行此操作。
|
||||||
|
```
|
||||||
|
|
||||||
|
这是因为 `tcl` 在 Windows 上只能为文件夹创建符号链接,无法直接为文件创建链接。为文件创建符号链接需要使用 `mklink` 命令,该命令要求管理员权限。解决方法是以管理员身份运行 `.bat` 脚本。
|
||||||
|
|
||||||
## 待办事项
|
## 待办事项
|
||||||
|
|
||||||
- [x] 支持 Xilinx SDK 的 XSCT 接口
|
- [x] 支持 Xilinx SDK 的 XSCT 接口
|
||||||
@@ -153,4 +171,4 @@
|
|||||||
|
|
||||||
## 贡献指南
|
## 贡献指南
|
||||||
|
|
||||||
如果您对该项目有任何改进意见或功能需求,欢迎提交 issue 或 pull request.
|
如果您对该项目有任何改进意见或功能需求,欢迎提交 issue 或 pull request,commit 格式请参考 [Angular convention](https://github.com/angular/angular/blob/main/CONTRIBUTING.md#commit).
|
||||||
|
|||||||
+39
-65
@@ -5,53 +5,48 @@ HIDE = > /dev/zero
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
TIMESTAMP = $(shell date +"%T")
|
TIMESTAMP = $(shell date +"%T")
|
||||||
copy_files = cp $(1) $(2)
|
cmd_copy = cp -a $(1) $(2)
|
||||||
copy_dir = cp -r $(1) $(2)
|
cmd_link = ln -sfr $(1) $(2)
|
||||||
remove_file = rm -rf $(1)
|
cmd_remove = rm -rf $(1)
|
||||||
remove_dir = rm -rf $(1)
|
cmd_mkdir = mkdir -p $(1)
|
||||||
mk_dir = mkdir -p $(1)
|
cmd_cat = cat $(1) 2>/dev/null
|
||||||
read_file = cat $(1) 2>/dev/null
|
cmd_print_lines = echo $(1) | tr ' ' '\n'
|
||||||
print_lines = echo $(1) | tr ' ' '\n'
|
|
||||||
green = \\e[32m$(1)\\e[39m
|
color_green = \033[32m$(1)\033[0m
|
||||||
print = printf "$(call green,[$(TIMESTAMP)]) $(1)\n"
|
log = @printf "$(call color_green,[$(TIMESTAMP)]) %s\n" "$(1)"
|
||||||
make_dir_link = ln -sfr $(1) $(2)
|
show_build_type = $(call log,Building for $(call green,$(1)))
|
||||||
make_link = ln -sfr $(1) $(2)
|
|
||||||
|
check-var = $(if $(strip $($(1))),,$(error [ERROR] Missing required variable: $(1)))
|
||||||
check_command = $(shell which $(1) > /dev/null 2>&1 && echo y || echo n)
|
check_command = $(shell which $(1) > /dev/null 2>&1 && echo y || echo n)
|
||||||
print_build_type = $(call print,Building for $(call green,$(1)))
|
|
||||||
|
|
||||||
ifeq ('y', '$(strip $(LINK_SRCS))')
|
$(call check-var,PROJECT)
|
||||||
update_files = $(call make_link,$(1),$(2))
|
$(call check-var,PLATFORM)
|
||||||
update_dir = $(call make_dir_link,$(1),$(2))
|
$(call check-var,BUILD_DIR)
|
||||||
ACTION = Linking
|
$(call check-var,CONFIG_FILE)
|
||||||
else
|
$(call check-var,LINK_SRCS)
|
||||||
update_files = $(call copy_files,$(1),$(dir $(2)))
|
|
||||||
update_dir = $(call copy_dir,$(1),$(2))
|
|
||||||
ACTION = Copying
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifndef PROJECT
|
|
||||||
$(error "PROJECT variable needs to be set")
|
|
||||||
endif
|
|
||||||
ifndef PLATFORM
|
|
||||||
$(error "PLATFORM variable needs to be set")
|
|
||||||
endif
|
|
||||||
ifndef BUILD_DIR
|
|
||||||
$(error "BUILD_DIR variable needs to be set")
|
|
||||||
endif
|
|
||||||
ifndef CONFIG_FILE
|
|
||||||
$(error "CONFIG_FILE variable needs to be set")
|
|
||||||
endif
|
|
||||||
ifndef SCRIPT_DIR
|
ifndef SCRIPT_DIR
|
||||||
CURRENT_FILE := $(lastword $(MAKEFILE_LIST))
|
CURRENT_FILE := $(lastword $(MAKEFILE_LIST))
|
||||||
CURRENT_DIR := $(patsubst %/,%,$(dir $(CURRENT_FILE)))
|
CURRENT_DIR := $(patsubst %/,%,$(dir $(CURRENT_FILE)))
|
||||||
SCRIPT_DIR := $(CURRENT_DIR)
|
SCRIPT_DIR := $(CURRENT_DIR)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq ($(strip $(LINK_SRCS)),y)
|
||||||
|
update_files = $(call cmd_link,$(1),$(2))
|
||||||
|
update_dir = $(call cmd_link,$(1),$(2))
|
||||||
|
ACTION = Linking
|
||||||
|
else
|
||||||
|
update_files = $(call cmd_copy,$(1),$(dir $(2)))
|
||||||
|
update_dir = $(call cmd_copy,$(1),$(2))
|
||||||
|
ACTION = Copying
|
||||||
|
endif
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
# COMMON INITIALIZATION
|
# COMMON INITIALIZATION
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
PLATFORM_TOOLS = $(SCRIPT_DIR)/platform/$(PLATFORM)
|
PLATFORM_TOOLS = $(SCRIPT_DIR)/platform/$(PLATFORM)
|
||||||
BUILD_LOCK = $(BUILD_DIR)/.project.lock
|
BUILD_LOCK = $(BUILD_DIR)/.build.lock
|
||||||
|
PROJECT_LOCK = $(BUILD_DIR)/.project.lock
|
||||||
|
|
||||||
ifeq ('xilinx', '$(PLATFORM)')
|
ifeq ('xilinx', '$(PLATFORM)')
|
||||||
include $(PLATFORM_TOOLS)/xilinx.mk
|
include $(PLATFORM_TOOLS)/xilinx.mk
|
||||||
@@ -62,49 +57,28 @@ endif
|
|||||||
# Generic Goals
|
# Generic Goals
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
.DEFAULT_GOAL := all
|
PHONY := clean reset project build sdkopen
|
||||||
PHONY += all
|
.DEFAULT_GOAL := project
|
||||||
ifneq ($(wildcard $(BUILD_LOCK)),)
|
|
||||||
all:
|
|
||||||
$(call print_build_type,$(PLATFORM))
|
|
||||||
$(MAKE) --no-print-directory build
|
|
||||||
$(call print,Done ($(notdir $(BUILD_DIR))))
|
|
||||||
else
|
|
||||||
all:
|
|
||||||
$(call print_build_type,$(PLATFORM))
|
|
||||||
$(MAKE) --no-print-directory project
|
|
||||||
$(MAKE) --no-print-directory build
|
|
||||||
$(call print,Done ($(notdir $(BUILD_DIR))))
|
|
||||||
endif
|
|
||||||
|
|
||||||
|
# Create project using corresponding SDK
|
||||||
project: $(PLATFORM)_project
|
project: $(PLATFORM)_project
|
||||||
@echo "$(TIMESTAMP): Build lock." > $(BUILD_LOCK)
|
|
||||||
|
|
||||||
standalone:
|
# Build project using corresponding compiler
|
||||||
$(MAKE) --no-print-directory project LINK_SRCS=n
|
build: project $(PLATFORM)_sdkbuild
|
||||||
|
|
||||||
# Build project using generic compiler
|
|
||||||
build: $(PLATFORM)_sdkbuild
|
|
||||||
|
|
||||||
# Open the project using the corresponding SDK
|
# Open the project using the corresponding SDK
|
||||||
sdkopen: $(PLATFORM)_sdkopen
|
sdkopen: project $(PLATFORM)_sdkopen
|
||||||
|
|
||||||
# Remove build artefacts
|
# Remove build artefacts
|
||||||
PHONY += clean
|
|
||||||
ifneq ($(wildcard $(BUILD_LOCK)),)
|
ifneq ($(wildcard $(BUILD_LOCK)),)
|
||||||
clean:
|
clean: $(PLATFORM)_sdkclean
|
||||||
$(call print,Cleaning sdk build uploaded to board)
|
|
||||||
$(MAKE) --no-print-directory $(PLATFORM)_sdkclean
|
|
||||||
else
|
else
|
||||||
clean:
|
clean: reset
|
||||||
$(call print,No project found, cleaning dummy files)
|
|
||||||
$(MAKE) --no-print-directory reset
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Remove the whole build directory
|
# Remove the whole build directory
|
||||||
PHONY += reset
|
|
||||||
reset: $(PLATFORM)_reset
|
reset: $(PLATFORM)_reset
|
||||||
$(call print,[Delete] $(BUILD_DIR))
|
@$(call log,[Delete] $(BUILD_DIR))
|
||||||
$(call remove_dir,$(BUILD_DIR))
|
@$(call cmd_remove,$(BUILD_DIR))
|
||||||
|
|
||||||
.PHONY: $(PHONY)
|
.PHONY: $(PHONY)
|
||||||
|
|||||||
+43
-41
@@ -10,15 +10,33 @@
|
|||||||
|
|
||||||
- **template.gitignore**: 针对 Xilinx 工具的 `.gitignore` 模板文件,用户可以将其内容复制到实际的 `.gitignore` 文件中;
|
- **template.gitignore**: 针对 Xilinx 工具的 `.gitignore` 模板文件,用户可以将其内容复制到实际的 `.gitignore` 文件中;
|
||||||
|
|
||||||
- **template.json**: 项目的 JSON 配置模板文件,定义了工程的基本配置,具体配置参数请参考[配置文件结构](#配置文件结构);
|
- **template.json**: 项目的 JSON 配置模板文件,定义了工程的基本配置,具体配置参数请参考[配置文件说明](#配置文件说明);
|
||||||
|
|
||||||
- **util.tcl**: 包含一组通用工具命令的 TCL 脚本,用于辅助自动化构建过程。此文件在构建过程中被调用,用于与开发工具交互执行 Xilinx 工具相关的特定操作;
|
- **util.tcl**: 包含一组通用工具命令的 TCL 脚本,用于辅助自动化构建过程。此文件在构建过程中被调用,用于与开发工具交互执行 Xilinx 工具相关的特定操作;
|
||||||
|
|
||||||
- **xilinx.mk**: 被 [`generic.mk`](../../generic.mk) 定义了 Xilinx 平台的特定的编译规则;
|
- **xilinx.mk**: 被 [`generic.mk`](../../generic.mk) 定义了 Xilinx 平台的特定的编译规则;
|
||||||
|
|
||||||
## 配置文件结构
|
## 配置文件说明
|
||||||
|
|
||||||
配置文件用于定义 Xilinx 平台项目的构建参数、应用配置和库依赖关系等信息,以便于在 `embedded-autobuild` 项目中自动化生成工程。以下是 Xilinx 配置文件各部分的详细说明。
|
配置文件用于定义 Xilinx 平台项目的构建参数、应用配置和库依赖关系等信息,以便于在 `embedded-autobuild` 项目中自动化生成工程。以下为最小化完整配置示例,包含了所有必填字段,可作为基础配置参考。
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"project_name": "demo",
|
||||||
|
"version": "0.0.0",
|
||||||
|
"hw_design": "demo_v0.0.0.hdf",
|
||||||
|
"apps": {
|
||||||
|
"demo_app": {
|
||||||
|
"sources": ["source/"],
|
||||||
|
"target_cpu": "ps7_cortexa9_0",
|
||||||
|
"os": "standalone",
|
||||||
|
"language": "C",
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
如需添加更多配置请详细阅读后续 Xilinx 配置文件各部分的详细说明。
|
||||||
|
|
||||||
> **注**:以下针对字段的解释中 **加粗** 字段为必须参数,*斜体* 标注的字段为可选参数,可选参数不填写则使用对应 IDE 的默认配置。
|
> **注**:以下针对字段的解释中 **加粗** 字段为必须参数,*斜体* 标注的字段为可选参数,可选参数不填写则使用对应 IDE 的默认配置。
|
||||||
|
|
||||||
@@ -26,7 +44,7 @@
|
|||||||
|
|
||||||
- **project_name**: 项目名称,例如 `"demo"`。
|
- **project_name**: 项目名称,例如 `"demo"`。
|
||||||
- **version**: 项目版本,例如 `"0.0.0"`。
|
- **version**: 项目版本,例如 `"0.0.0"`。
|
||||||
- **hw_design**: 硬件设计文件(`.hdf` 或 `.xsa` 文件)路径(相对配置文件路径),例如 `"demo_v0.0.0.hdf"`。
|
- **hw_design**: 硬件设计文件(`.hdf` 或 `.xsa` 文件)路径(相对档案工作路径),例如 `"demo_v0.0.0.hdf"`。
|
||||||
|
|
||||||
### *fsbl_patch* (TODO)
|
### *fsbl_patch* (TODO)
|
||||||
|
|
||||||
@@ -75,7 +93,7 @@
|
|||||||
- **target_cpu**: 目标 CPU[^2],例如 "ps7_cortexa9_0" 表示 Zynq-7000 系列的 ARM Cortex-A9 核;
|
- **target_cpu**: 目标 CPU[^2],例如 "ps7_cortexa9_0" 表示 Zynq-7000 系列的 ARM Cortex-A9 核;
|
||||||
-*libs*: 必要的库及其版本配置[^1],该配置项下可包含多个 `lib` 配置,默认不添加任何 `lib`;
|
-*libs*: 必要的库及其版本配置[^1],该配置项下可包含多个 `lib` 配置,默认不添加任何 `lib`;
|
||||||
- **version**: `lib` 版本 [^1];
|
- **version**: `lib` 版本 [^1];
|
||||||
-*config*: 其他具体 `lib` 设置[^1],不填写则使用 IDE 默认配置;
|
- *config*: 其他具体 `lib` 设置[^1],不填写则使用 IDE 默认配置;
|
||||||
-*config*: 其他具体 BSP/Domain 设置[^1],不填写则使用 IDE 默认配置;
|
-*config*: 其他具体 BSP/Domain 设置[^1],不填写则使用 IDE 默认配置;
|
||||||
|
|
||||||
以下配置添加了一个名为 "standalone" 的 BSP/Domain 工程,添加了 `xilffs` 和 `xilrsa` 两个 `lib,其中` `xilffs` 启用了长文件名(use_lfn)以及exFAT(enable_exfat)支持,并设置了标准输入输出为 `ps7_coresight_comp_0`,sleep 计数器使用 `ps7_globaltimer_0`.
|
以下配置添加了一个名为 "standalone" 的 BSP/Domain 工程,添加了 `xilffs` 和 `xilrsa` 两个 `lib,其中` `xilffs` 启用了长文件名(use_lfn)以及exFAT(enable_exfat)支持,并设置了标准输入输出为 `ps7_coresight_comp_0`,sleep 计数器使用 `ps7_globaltimer_0`.
|
||||||
@@ -117,6 +135,7 @@
|
|||||||
"target_cpu": "<cpu_id>",
|
"target_cpu": "<cpu_id>",
|
||||||
"os": "<os_type>",
|
"os": "<os_type>",
|
||||||
"language": "<language>",
|
"language": "<language>",
|
||||||
|
"template": "<app_template>",
|
||||||
"bsp": "<bsp_name>",
|
"bsp": "<bsp_name>",
|
||||||
"bsp_lib": {
|
"bsp_lib": {
|
||||||
"<lib_name>": {
|
"<lib_name>": {
|
||||||
@@ -153,27 +172,28 @@
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
- **sources**: 源文件列表(相对配置文件路径);
|
- **sources**: 源文件列表,可使用通配符。例如,`"src/*"` 会将当前工作路径下的 `src` 文件夹中的所有文件复制或链接到相应工程目录下的 `src` 文件夹中。
|
||||||
- **target_cpu**: 目标 CPU ID[^2];
|
- **target_cpu**: 目标 CPU ID[^2];
|
||||||
- **os**: 操作系统类型[^1],必须与 BSP/Domain 匹配;
|
- **os**: 操作系统类型[^1],必须与 BSP/Domain 匹配;
|
||||||
- **language**: 编程语言,"C" 或 "C++";
|
- **language**: 编程语言,"C" 或 "C++";
|
||||||
-*bsp*: 应用所使用的 BSP 名称,若未指定则会自动创建名为 `<os>_<cpu_id>` 的 BSP/Domain.
|
- *template*: 所使用的应用模板名称,不指定则默认为对应语言的 “Empty Application”;
|
||||||
-*bsp_lib*: 针对自动创建的 BSP/Domain 所使用库的配置,与 [bsps](#-bsps) 中 `libs` 对应;
|
- *bsp*: 应用所使用的 BSP 名称,若未指定则会自动创建名为 `<app_name>_bsp` 的 BSP/Domain.
|
||||||
-*bsp_config*: 针对自动创建的 BSP/Domain 配置与 [bsps](#-bsps) 中 `config` 对应;
|
- *bsp_lib*: 针对自动创建的 BSP/Domain 所使用库的配置,与 [bsps](#bsps) 中 `libs` 对应;
|
||||||
-*mem_layout*: 应用内存布局,包括堆栈大小和堆大小等;
|
- *bsp_config*: 针对自动创建的 BSP/Domain 配置与 [bsps](#bsps) 中 `config` 对应;
|
||||||
|
- *mem_layout*: 应用内存布局,包括堆栈大小和堆大小等;
|
||||||
-*heap_size*: 堆大小,必须写为十六进制,例如 "0x80000";
|
-*heap_size*: 堆大小,必须写为十六进制,例如 "0x80000";
|
||||||
-*stack_size*: 栈大小,必须写为十六进制,例如 "0x4000";
|
-*stack_size*: 栈大小,必须写为十六进制,例如 "0x4000";
|
||||||
-*build_config*: 编译目标配置,`release` 或 `debug`;
|
- *build_config*: 编译目标配置,`release` 或 `debug`;
|
||||||
-`assembler-flags`: 汇编器标志;
|
- `assembler-flags`: 汇编器标志;
|
||||||
-`compiler-misc`: 其他编译器选项;
|
- `compiler-misc`: 其他编译器选项;
|
||||||
-`compiler-optimization`: 编译优化选项;
|
- `compiler-optimization`: 编译优化选项;
|
||||||
-`linker-misc`: 链接器选项;
|
- `linker-misc`: 链接器选项;
|
||||||
-`linker-script`: 链接脚本路径;
|
- `linker-script`: 链接脚本路径[^3];
|
||||||
-`define-compiler-symbols`: 自定义的编译器宏定义符号列表;
|
- `define-compiler-symbols`: 自定义的编译器宏定义符号列表;
|
||||||
-`undef-compiler-symbols`: 要取消定义的符号列表;
|
- `undef-compiler-symbols`: 要取消定义的符号列表;
|
||||||
-`include-path`: 包含文件路径;
|
- `include-path`: 包含文件路径[^3];
|
||||||
-`libraries`: 需要链接的库;
|
- `libraries`: 需要链接的库;
|
||||||
-`library-search-path`: 库搜索路径;
|
- `library-search-path`: 库搜索路径[^3];
|
||||||
|
|
||||||
以下配置添加了一个名为 `demo_app` 的 Application 工程,该工程没有指定 BSP/Domain 但能够通过 `bsp_lib` 和 `bsp_config` 自动生成一个名为 `standalone_ps7_cortexa9_0` 的 BSP/Domain 工程。
|
以下配置添加了一个名为 `demo_app` 的 Application 工程,该工程没有指定 BSP/Domain 但能够通过 `bsp_lib` 和 `bsp_config` 自动生成一个名为 `standalone_ps7_cortexa9_0` 的 BSP/Domain 工程。
|
||||||
|
|
||||||
@@ -216,26 +236,8 @@
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
### 完整配置示例
|
|
||||||
|
|
||||||
以下为最小化完整配置示例,包含了所有必填字段,可作为基础配置参考。
|
|
||||||
|
|
||||||
```json
|
|
||||||
{
|
|
||||||
"project_name": "demo",
|
|
||||||
"version": "0.0.0",
|
|
||||||
"hw_design": "demo_v0.0.0.hdf",
|
|
||||||
"apps": {
|
|
||||||
"demo_app": {
|
|
||||||
"sources": ["source/"],
|
|
||||||
"target_cpu": "ps7_cortexa9_0",
|
|
||||||
"os": "standalone",
|
|
||||||
"language": "C",
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
[^1]: 具体可配置项取决于对应 IDE 版本;
|
[^1]: 具体可配置项取决于对应 IDE 版本;
|
||||||
|
|
||||||
[^2]: 具体可选 CPU ID 取决于硬件型号;
|
[^2]: 具体可选 CPU ID 取决于硬件型号;
|
||||||
|
|
||||||
|
[^3]: 相对对应工程的文件夹的路径;
|
||||||
|
|||||||
@@ -14,11 +14,20 @@ set "xilinx_version=%1"
|
|||||||
set "version_pattern=20[12][01234789][.][12]"
|
set "version_pattern=20[12][01234789][.][12]"
|
||||||
echo %xilinx_version% | findstr /r /c:"%version_pattern%" >nul
|
echo %xilinx_version% | findstr /r /c:"%version_pattern%" >nul
|
||||||
if %errorlevel% NEQ 0 (
|
if %errorlevel% NEQ 0 (
|
||||||
echo Error: %xilinx_version% is not a valid version coede ^(e.g., 2019.1^)
|
echo Error: %xilinx_version% is not a valid version code ^(e.g., 2019.1^)
|
||||||
exit /b 1
|
exit /b 1
|
||||||
)
|
)
|
||||||
|
|
||||||
REM Convert it to a integer
|
REM Prompt user for Xilinx installation path, default to C:\Xilinx if not provided
|
||||||
|
set "default_path=C:\Xilinx"
|
||||||
|
set /p "xilinx_path=Enter Xilinx installation path (press Enter for default: %default_path%): "
|
||||||
|
if "%xilinx_path%"=="" (
|
||||||
|
set "xilinx_path=%default_path%"
|
||||||
|
)
|
||||||
|
REM Reset ERRORLEVEL to avoid false error codes
|
||||||
|
verify > nul
|
||||||
|
|
||||||
|
REM Convert version to integer
|
||||||
for /f "tokens=1,2 delims=." %%a in ("%xilinx_version%") do (
|
for /f "tokens=1,2 delims=." %%a in ("%xilinx_version%") do (
|
||||||
set major=%%a
|
set major=%%a
|
||||||
set minor=%%b
|
set minor=%%b
|
||||||
@@ -26,13 +35,13 @@ for /f "tokens=1,2 delims=." %%a in ("%xilinx_version%") do (
|
|||||||
set /a version_number=%major%%minor%
|
set /a version_number=%major%%minor%
|
||||||
set /a lowest_vitis_version=20192
|
set /a lowest_vitis_version=20192
|
||||||
|
|
||||||
REM Determine the correct settings.bat path based on the Xilinx version
|
REM Determine the correct settings.bat path based on the Xilinx version and user path
|
||||||
if %version_number% lss %lowest_vitis_version% (
|
if %version_number% lss %lowest_vitis_version% (
|
||||||
echo Setup enviroment for Xilinx SDK.
|
echo Setting up environment for Xilinx SDK %xilinx_version%.
|
||||||
set settings_bat=C:\Xilinx\SDK\%xilinx_version%\settings64.bat
|
set settings_bat=%xilinx_path%\SDK\%xilinx_version%\settings64.bat
|
||||||
) else (
|
) else (
|
||||||
echo Setup enviroment for Xilinx Vitis.
|
echo Setting up environment for Xilinx Vitis %xilinx_version%.
|
||||||
set settings_bat=C:\Xilinx\Vitis\%xilinx_version%\settings64.bat
|
set settings_bat=%xilinx_path%\Vitis\%xilinx_version%\settings64.bat
|
||||||
)
|
)
|
||||||
|
|
||||||
REM Check if the settings.bat file exists
|
REM Check if the settings.bat file exists
|
||||||
@@ -45,7 +54,7 @@ if not exist "%settings_bat%" (
|
|||||||
REM Call the settings.bat file to set up the environment
|
REM Call the settings.bat file to set up the environment
|
||||||
call "%settings_bat%"
|
call "%settings_bat%"
|
||||||
if "%ERRORLEVEL%" neq "0" (
|
if "%ERRORLEVEL%" neq "0" (
|
||||||
echo Error: Failed to source "%settings_bat%".
|
echo Error: Failed to call "%settings_bat%"
|
||||||
exit /b 1
|
exit /b 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -31,6 +31,7 @@
|
|||||||
"target_cpu": "<cpu_id>",
|
"target_cpu": "<cpu_id>",
|
||||||
"os": "<os_type>",
|
"os": "<os_type>",
|
||||||
"language": "<language>",
|
"language": "<language>",
|
||||||
|
"template": "<app_template>",
|
||||||
"bsp": "<bsp_name>",
|
"bsp": "<bsp_name>",
|
||||||
"bsp_lib": {
|
"bsp_lib": {
|
||||||
"<lib_name>": {
|
"<lib_name>": {
|
||||||
|
|||||||
+112
-29
@@ -81,6 +81,7 @@ proc _configure_bsp {bsp_name bsp_config platform_name is_vitis} {
|
|||||||
|
|
||||||
if {$is_vitis} {
|
if {$is_vitis} {
|
||||||
bsp regenerate
|
bsp regenerate
|
||||||
|
platform generate -domains "$bsp_name"
|
||||||
} else {
|
} else {
|
||||||
regenbsp -bsp $bsp_name
|
regenbsp -bsp $bsp_name
|
||||||
projects -build -type bsp -name $bsp_name
|
projects -build -type bsp -name $bsp_name
|
||||||
@@ -89,6 +90,46 @@ proc _configure_bsp {bsp_name bsp_config platform_name is_vitis} {
|
|||||||
return $bsp_name
|
return $bsp_name
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Helper procedure to recursively create hard links for files in a directory
|
||||||
|
proc _link_or_copy_dir {source_dir target_dir link_mode} {
|
||||||
|
# Create target directory if it doesn't exist
|
||||||
|
if {![file exists $target_dir]} {
|
||||||
|
file mkdir $target_dir
|
||||||
|
_info "Created directory: $target_dir"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Process each file and subdirectory in the source directory
|
||||||
|
foreach item [glob -nocomplain -directory $source_dir *] {
|
||||||
|
set item_name [file tail $item]
|
||||||
|
set target_item [file join $target_dir $item_name]
|
||||||
|
|
||||||
|
# Remove existing file or directory
|
||||||
|
if {[file exists $target_item]} {
|
||||||
|
file delete -force $target_item
|
||||||
|
_warn "Deleted existing item: $target_item"
|
||||||
|
}
|
||||||
|
|
||||||
|
if {[file isfile $item]} {
|
||||||
|
# Handle file - create hard link or copy
|
||||||
|
if {$link_mode eq "y"} {
|
||||||
|
if {[catch {
|
||||||
|
file link -hard $target_item $item
|
||||||
|
} err]} {
|
||||||
|
error "Failed to create hard link: $err"
|
||||||
|
} else {
|
||||||
|
_info "Created hard link: $target_item -> $item"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
file copy $item $target_item
|
||||||
|
_info "Copied file: $item to $target_item"
|
||||||
|
}
|
||||||
|
} elseif {[file isdirectory $item]} {
|
||||||
|
# Handle subdirectory recursively
|
||||||
|
_link_or_copy_dir $item $target_item $link_mode
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# Helper procedure to handle source files: link or copy based on LINK_SRCS
|
# Helper procedure to handle source files: link or copy based on LINK_SRCS
|
||||||
proc _handle_sources {app_name sources} {
|
proc _handle_sources {app_name sources} {
|
||||||
# Check environment variable LINK_SRCS
|
# Check environment variable LINK_SRCS
|
||||||
@@ -98,29 +139,46 @@ proc _handle_sources {app_name sources} {
|
|||||||
}
|
}
|
||||||
|
|
||||||
foreach source_file $sources {
|
foreach source_file $sources {
|
||||||
set source_path [file normalize $::root/$source_file]
|
# Expand wildcards
|
||||||
set target_path [file join $::ws $app_name [file tail $source_path]]
|
set expanded_sources [glob -nocomplain -directory $::root $source_file]
|
||||||
|
if {[llength $expanded_sources] == 0} {
|
||||||
|
_error "Source file not found" "No file or directory matches $source_file"
|
||||||
|
}
|
||||||
|
|
||||||
# Delete existing symbolic link or file if it exists
|
# Handle each expanded source
|
||||||
|
foreach eval_source $expanded_sources {
|
||||||
|
set relative_source [string range $eval_source [expr [string length $::root] + 1] end]
|
||||||
|
set target_path [file join $::ws $app_name $relative_source]
|
||||||
|
|
||||||
|
if {[file isfile $eval_source]} {
|
||||||
|
# For files, ensure the parent directory exists
|
||||||
|
set target_dir [file dirname $target_path]
|
||||||
|
if {![file exists $target_dir]} {
|
||||||
|
file mkdir $target_dir
|
||||||
|
_info "Created directory: $target_dir"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Delete existing file if it exists
|
||||||
if {[file exists $target_path]} {
|
if {[file exists $target_path]} {
|
||||||
file delete -force $target_path
|
file delete -force $target_path
|
||||||
_warn "Deleted existing link or file: $target_path"
|
_warn "Deleted existing file: $target_path"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Handle source based on the value of LINK_SRCS
|
# Handle file based on LINK_SRCS
|
||||||
switch $link_srcs {
|
if {$link_srcs eq "y"} {
|
||||||
"y" {
|
if {[catch {
|
||||||
# Create symbolic link
|
file link -hard $target_path $eval_source
|
||||||
file link -symbolic $target_path $source_path
|
} err]} {
|
||||||
_info "Created symbolic link: $target_path -> $source_path"
|
error "Failed to create hard link: $err"
|
||||||
}
|
}
|
||||||
"n" {
|
_info "Created hard link: $target_path -> $eval_source"
|
||||||
# Copy the source file
|
} else {
|
||||||
file copy $source_path $target_path
|
file copy $eval_source $target_path
|
||||||
_info "Copied source file: $source_path to $target_path"
|
_info "Copied file: $eval_source to $target_path"
|
||||||
}
|
}
|
||||||
default {
|
} else {
|
||||||
_error "Unknown value for LINK_SRCS: ${link_srcs}."
|
# For directories, use the helper function
|
||||||
|
_link_or_copy_dir $eval_source $target_path $link_srcs
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -166,7 +224,7 @@ proc _update_app_mem_layout {app_name mem_layout} {
|
|||||||
proc _update_app_build_config {app_name build_type build_config is_vitis} {
|
proc _update_app_build_config {app_name build_type build_config is_vitis} {
|
||||||
set build_types {"debug" "release"}
|
set build_types {"debug" "release"}
|
||||||
if {[lsearch $build_types $build_type] == -1} {
|
if {[lsearch $build_types $build_type] == -1} {
|
||||||
_error "Invalid config type: $build_type" "available types: $build_types"
|
_error "Invalid config type: $build_type" "available types: $build_types"
|
||||||
}
|
}
|
||||||
|
|
||||||
set cmd [list]
|
set cmd [list]
|
||||||
@@ -181,16 +239,17 @@ proc _update_app_build_config {app_name build_type build_config is_vitis} {
|
|||||||
|
|
||||||
dict for {param value} $build_config {
|
dict for {param value} $build_config {
|
||||||
switch -exact -- $param {
|
switch -exact -- $param {
|
||||||
"include-path" {
|
"include-path" -
|
||||||
|
"library-search-path" {
|
||||||
foreach path $value {
|
foreach path $value {
|
||||||
eval $cmd $app_name include-path "../$path"
|
set path_str [format "\"\${workspace_loc:/%s/%s}\"" $app_name $path]
|
||||||
_info "Append included path: $path for $app_name."
|
eval $cmd $app_name $param [list $path_str]
|
||||||
|
_info "Append $param: $path for $app_name."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
"define-compiler-symbols" -
|
"define-compiler-symbols" -
|
||||||
"undef-compiler-symbols" -
|
"undef-compiler-symbols" -
|
||||||
"libraries" -
|
"libraries" {
|
||||||
"library-search-path" {
|
|
||||||
foreach item $value {
|
foreach item $value {
|
||||||
eval $cmd $app_name $param $item
|
eval $cmd $app_name $param $item
|
||||||
_info "Append parameter $param: $item for $app_name."
|
_info "Append parameter $param: $item for $app_name."
|
||||||
@@ -202,7 +261,8 @@ proc _update_app_build_config {app_name build_type build_config is_vitis} {
|
|||||||
"linker-misc" -
|
"linker-misc" -
|
||||||
"linker-script" {
|
"linker-script" {
|
||||||
if {$value ne ""} {
|
if {$value ne ""} {
|
||||||
eval $cmd $app_name -set $param $value
|
set value_list [list $value]
|
||||||
|
eval $cmd $app_name -set $param $value_list
|
||||||
_info "Set $param: $value for $app_name."
|
_info "Set $param: $value for $app_name."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -217,13 +277,33 @@ proc _update_app_build_config {app_name build_type build_config is_vitis} {
|
|||||||
proc _create_app {app_name app_config platform_name is_vitis} {
|
proc _create_app {app_name app_config platform_name is_vitis} {
|
||||||
set cpu [dict get $app_config target_cpu]
|
set cpu [dict get $app_config target_cpu]
|
||||||
set os [dict get $app_config os]
|
set os [dict get $app_config os]
|
||||||
set lang [dict get $app_config language]
|
|
||||||
set sources [dict get $app_config sources]
|
set sources [dict get $app_config sources]
|
||||||
set bsp_name "${os}_${cpu}"
|
set bsp_name "${app_name}_bsp"
|
||||||
|
set lang [dict get $app_config language]
|
||||||
|
if { $lang ne "C" && $lang ne "C++" } {
|
||||||
|
_error "Unsupport language" "language should be C or C++"
|
||||||
|
}
|
||||||
|
if { [dict exists $app_config template] } {
|
||||||
|
set template [dict get $app_config template]
|
||||||
|
} elseif { !$is_vitis } {
|
||||||
|
set template "Empty Application"
|
||||||
|
} elseif { $lang eq "C++" } {
|
||||||
|
set template "Empty Application (C++)"
|
||||||
|
} else {
|
||||||
|
set template "Empty Application(C)"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
# Configure BSP/Domain for application
|
# Configure BSP/Domain for application
|
||||||
if {[dict exists $app_config bsp] && [dict get $app_config bsp] ne ""} {
|
if {[dict exists $app_config bsp] && [dict get $app_config bsp] ne ""} {
|
||||||
set bsp_name [dict get $app_config bsp]
|
set bsp_name [dict get $app_config bsp]
|
||||||
|
if {![dict exists $::config bsps]} {
|
||||||
|
_error "BSP configuration missing" "The 'bsps' section is not found in the configuration."
|
||||||
|
} elseif {![dict exists [dict get $::config bsps] $bsp_name]} {
|
||||||
|
_error "BSP configuration missing" "No configuration found for BSP '$bsp_name' in the 'bsps' section."
|
||||||
|
} else {
|
||||||
|
_info "Configuring BSP '$bsp_name' for application '$app_name'."
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
set bsp_config [dict create]
|
set bsp_config [dict create]
|
||||||
set bsp_config [dict set bsp_config target_cpu $cpu]
|
set bsp_config [dict set bsp_config target_cpu $cpu]
|
||||||
@@ -236,6 +316,7 @@ proc _create_app {app_name app_config platform_name is_vitis} {
|
|||||||
set bsp_cfg [dict get $app_config bsp_config]
|
set bsp_cfg [dict get $app_config bsp_config]
|
||||||
set bsp_config [dict merge $bsp_config [dict create config $bsp_cfg]]
|
set bsp_config [dict merge $bsp_config [dict create config $bsp_cfg]]
|
||||||
}
|
}
|
||||||
|
_info "Creating BSP $bsp_name for Application $app_name ..."
|
||||||
_configure_bsp $bsp_name $bsp_config $platform_name $is_vitis
|
_configure_bsp $bsp_name $bsp_config $platform_name $is_vitis
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -249,7 +330,7 @@ proc _create_app {app_name app_config platform_name is_vitis} {
|
|||||||
-os $os \
|
-os $os \
|
||||||
-lang $lang \
|
-lang $lang \
|
||||||
-sysproj $::project_name \
|
-sysproj $::project_name \
|
||||||
-template "Empty Application($lang)"
|
-template "$template"
|
||||||
_info "Application '$app_name' created for Vitis."
|
_info "Application '$app_name' created for Vitis."
|
||||||
} else {
|
} else {
|
||||||
sdk createapp -name $app_name \
|
sdk createapp -name $app_name \
|
||||||
@@ -258,7 +339,7 @@ proc _create_app {app_name app_config platform_name is_vitis} {
|
|||||||
-proc $cpu \
|
-proc $cpu \
|
||||||
-os $os \
|
-os $os \
|
||||||
-lang $lang \
|
-lang $lang \
|
||||||
-app "Empty Application"
|
-app "$template"
|
||||||
_info "Application '$app_name' created for Xilinx SDK."
|
_info "Application '$app_name' created for Xilinx SDK."
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -316,9 +397,11 @@ proc create_project {} {
|
|||||||
_prepare_platform $::hw_file $platform_name $is_vitis
|
_prepare_platform $::hw_file $platform_name $is_vitis
|
||||||
|
|
||||||
# Process each bsp
|
# Process each bsp
|
||||||
|
if {[dict exists $::config bsps]} {
|
||||||
dict for {bsp_name bsp_config} [dict get $::config bsps] {
|
dict for {bsp_name bsp_config} [dict get $::config bsps] {
|
||||||
_configure_bsp $bsp_name $bsp_config $platform_name $is_vitis
|
_configure_bsp $bsp_name $bsp_config $platform_name $is_vitis
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# Process each application
|
# Process each application
|
||||||
dict for {app_name app_config} [dict get $::config apps] {
|
dict for {app_name app_config} [dict get $::config apps] {
|
||||||
@@ -383,10 +466,10 @@ _info "Working at $ws"
|
|||||||
set config_file_id [open $config_file r]
|
set config_file_id [open $config_file r]
|
||||||
set config_data [read $config_file_id]
|
set config_data [read $config_file_id]
|
||||||
close $config_file_id
|
close $config_file_id
|
||||||
set root [file dirname [file normalize $config_file]]
|
set root [pwd]
|
||||||
set config [json::json2dict $config_data]
|
set config [json::json2dict $config_data]
|
||||||
set project_name [dict get $config project_name]
|
set project_name [dict get $config project_name]
|
||||||
set hw_file [file normalize [file join [file dirname $config_file] [dict get $config hw_design]]]
|
set hw_file [file normalize [file join $root [dict get $config hw_design]]]
|
||||||
|
|
||||||
_info "Starting process: $function"
|
_info "Starting process: $function"
|
||||||
_info "Project name: $project_name"
|
_info "Project name: $project_name"
|
||||||
|
|||||||
+21
-14
@@ -1,14 +1,21 @@
|
|||||||
#------------------------------------------------------------------------------
|
$(call check-var,XILINX_VITIS_CLASSIC)
|
||||||
# ENVIRONMENT VARIABLES
|
$(call check-var,PLATFORM_TOOLS)
|
||||||
#------------------------------------------------------------------------------
|
$(call check-var,CONFIG_FILE)
|
||||||
|
$(call check-var,BUILD_DIR)
|
||||||
|
$(call check-var,PROJECT_LOCK)
|
||||||
|
$(call check-var,BUILD_LOCK)
|
||||||
|
$(call check-var,LINK_SRCS)
|
||||||
|
|
||||||
define tcl_util
|
define tcl_util
|
||||||
xsct -nodisp $(PLATFORM_TOOLS)/util.tcl \
|
xsct -nodisp $(PLATFORM_TOOLS)/util.tcl \
|
||||||
$(1) \
|
$(1) \
|
||||||
$(CONFIG_FILE) $(BUILD_DIR)
|
$(CONFIG_FILE) $(BUILD_DIR)
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
PHONY += xilinx_reset xilinx_project xilinx_sdkclean xilinx_sdkbuild
|
||||||
|
|
||||||
xilinx_sdkopen:
|
xilinx_sdkopen:
|
||||||
$(call print,Launching IDE...)
|
@$(call log,Launching IDE...)
|
||||||
@if [ "$(call check_command,vitis)" = "y" ]; then \
|
@if [ "$(call check_command,vitis)" = "y" ]; then \
|
||||||
if [ "$(XILINX_VITIS_CLASSIC)" = "y" ]; then \
|
if [ "$(XILINX_VITIS_CLASSIC)" = "y" ]; then \
|
||||||
vitis -classic -workspace=$(BUILD_DIR); \
|
vitis -classic -workspace=$(BUILD_DIR); \
|
||||||
@@ -21,22 +28,22 @@ xilinx_sdkopen:
|
|||||||
echo "No IDE found!" && exit 1; \
|
echo "No IDE found!" && exit 1; \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
PHONY += xilinx_sdkbuild
|
|
||||||
xilinx_sdkbuild:
|
xilinx_sdkbuild:
|
||||||
$(call print,[Build] SDK projects in $(BUILD_DIR))
|
@$(call log,[Build] SDK projects in $(BUILD_DIR))
|
||||||
$(call tcl_util, build) $(HIDE)
|
$(call tcl_util, build) $(HIDE)
|
||||||
|
@echo "$(TIMESTAMP): Build lock." > $(BUILD_LOCK)
|
||||||
|
|
||||||
PHONY += xilinx_sdkclean
|
|
||||||
xilinx_sdkclean:
|
xilinx_sdkclean:
|
||||||
$(call print,[Delete] SDK artefacts from $(BUILD_DIR))
|
@$(call log,[Delete] SDK artefacts from $(BUILD_DIR))
|
||||||
$(call tcl_util, clean_project) $(HIDE)
|
$(call tcl_util, clean_project) $(HIDE)
|
||||||
|
|
||||||
xilinx_project:
|
$(PROJECT_LOCK):
|
||||||
$(call mk_dir,$(BUILD_DIR))
|
@$(call log,Creating and configuring the IDE project)
|
||||||
$(call print,Creating and configuring the IDE project)
|
@$(call cmd_mkdir,$(BUILD_DIR))
|
||||||
$(call tcl_util, create_project) $(HIDE)
|
$(call tcl_util, create_project) $(HIDE)
|
||||||
|
@echo "$(TIMESTAMP): Project lock." > $@
|
||||||
|
|
||||||
xilinx_reset: xilinx_clean_all
|
xilinx_project: $(PROJECT_LOCK)
|
||||||
|
|
||||||
xilinx_clean_all:
|
xilinx_reset:
|
||||||
$(call remove_dir,.Xil) $(HIDE)
|
$(call cmd_remove,.Xil) $(HIDE)
|
||||||
+8
-6
@@ -1,14 +1,16 @@
|
|||||||
@echo off
|
@echo off
|
||||||
|
cd /d "%~dp0"
|
||||||
|
|
||||||
set "platform=xilinx"
|
set "platform=xilinx"
|
||||||
set "pltform_ver=2019.1"
|
set "platform_ver=2019.1"
|
||||||
set "work_dir=%~dp0build"
|
set "work_dir=%~dp0build"
|
||||||
set "config=%~dp0config.json"
|
set "config=%~dp0config.json"
|
||||||
set "tools_dir=%~dp0scripts\platform\%platform%"
|
set "tools_dir=%~dp0scripts\platform\%platform%"
|
||||||
|
|
||||||
REM Set up enviroment
|
REM Set up environment
|
||||||
call "%tools_dir%\setenv_xilinx.bat" "%pltform_ver%"
|
call "%tools_dir%\setenv.bat" "%platform_ver%"
|
||||||
if "%ERRORLEVEL%" neq "0" (
|
if "%ERRORLEVEL%" neq "0" (
|
||||||
echo Error: Failed to installize enviroment.
|
echo Error: Failed to initialize environment.
|
||||||
pause >nul
|
pause >nul
|
||||||
exit /b 1
|
exit /b 1
|
||||||
)
|
)
|
||||||
@@ -21,8 +23,8 @@ if "%ERRORLEVEL%" neq "0" (
|
|||||||
exit /b 1
|
exit /b 1
|
||||||
)
|
)
|
||||||
|
|
||||||
REM Lauch SDK
|
REM Launch SDK
|
||||||
call "%tools_dir%\launch.bat" "%pltform_ver%" "%work_dir%"
|
call "%tools_dir%\launch.bat" "%platform_ver%" "%work_dir%"
|
||||||
if "%ERRORLEVEL%" neq "0" (
|
if "%ERRORLEVEL%" neq "0" (
|
||||||
echo Error: Failed to launch SDK.
|
echo Error: Failed to launch SDK.
|
||||||
pause >nul
|
pause >nul
|
||||||
|
|||||||
Reference in New Issue
Block a user