From bd65e74eb31b8ae0b6d4c1b088caa4f93d8ed7bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=89=E7=A9=BA=E6=9C=89=E7=A9=BA?= <93474460+ykykzq@users.noreply.github.com> Date: Thu, 12 Sep 2024 11:26:22 +0800 Subject: [PATCH] Update main.yml --- .github/workflows/main.yml | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e7327fa..8f17285 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,6 +1,5 @@ name: Build and Lint -# 触发事件,选择 push 和 pull request 事件,触发分支为 main 或 master on: push: branches: @@ -20,18 +19,23 @@ jobs: - name: Checkout code uses: actions/checkout@v2 - # 设置 Xilinx Vivado 环境 - - name: Set up Xilinx Vivado 2019.2 - run: | - sudo apt-get update - sudo apt-get install -y vivado - source /opt/Xilinx/Vivado/2019.2/settings64.sh - # 设置 LoongArch 工具链 - name: Set up LoongArch toolchain run: | export PATH=/opt/loongarch32r-linux-gnusf-2022-05-20/bin:${PATH} + # 安装 Xilinx Vivado + - name: Install Xilinx Vivado 2019.2 + run: | + mkdir -p /opt/xilinx + wget https://www.xilinx.com/support/download/index.html -O vivado_installer.tar.gz + tar -xzvf vivado_installer.tar.gz -C /opt/xilinx + /opt/xilinx/vivado/2019.2/installer/xsetup --silent --agree XilinxEULA --noexec + + # 设置 Xilinx Vivado 环境 + - name: Source Vivado environment + run: source /opt/xilinx/vivado/2019.2/settings64.sh + # 编译 asm 文件 - name: Build asm run: make -C asm