Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 37 additions & 13 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:

strategy:
matrix:
ARCH: ['x86_64']
ARCH: ['x86_64', 'loong64']
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
Expand All @@ -45,8 +45,8 @@ jobs:
name='${{ github.ref_name }}'
fi
echo "tag result: $tag - $name"
echo "::set-output name=tag::$tag"
echo "::set-output name=name::$name"
echo "tag=$tag" >> $GITHUB_OUTPUT
echo "name=$name" >> $GITHUB_OUTPUT

# - name: Configure the project
# uses: threeal/cmake-action@v1.3.0
Expand All @@ -55,10 +55,32 @@ jobs:
# run: cmake --build build

- name: Build the project
if: matrix.ARCH == 'x86_64'
run: |
export DOCKER_UID=$UID
export DOCKER_GID=$GID
tools/build-with-docker.sh

- name: Use Node.js ${{ matrix.node-version }}
if: matrix.ARCH == 'loong64'
uses: actions/setup-node@v3
with:
# Version Spec of the version to use in SemVer notation.
# It also emits such aliases as lts, latest, nightly and canary builds
# Examples: 12.x, 10.15.1, >=10.15.0, lts/Hydrogen, 16-nightly, latest, node
node-version: '22'
check-latest: false
- name: Prepare PNPM
if: matrix.ARCH == 'loong64'
run: |
corepack enable
pnpm install --no-frozen-lockfile
- name: Build the project
if: matrix.ARCH == 'loong64'
run: |
export DOCKER_UID=$UID
export DOCKER_GID=$GID
docker compose up
tools/build-loong64.sh

- name: Upload prepare
run: |
Expand All @@ -68,6 +90,10 @@ jobs:
mkdir -p tmp/build
mv build/{wcc,wcsc,wcc_module.node,wcsc_module.node} tmp/build
cd tmp/build
mv wcc wcc-${{ matrix.ARCH }}
mv wcsc wcsc-${{ matrix.ARCH }}
mv wcc_module.node wcc-${{ matrix.ARCH }}.node
mv wcsc_module.node wcsc-${{ matrix.ARCH }}.node
ls -l

- name: Upload artifact
Expand Down Expand Up @@ -123,10 +149,10 @@ jobs:
corepack enable
ls -l
mkdir build
cp **build/wcc build
cp **build/wcsc build
cp **build/wcc_module.node build
cp **build/wcsc_module.node build
cp **-${{ matrix.ARCH }}.build/wcc-${{ matrix.ARCH }} build/wcc
cp **-${{ matrix.ARCH }}.build/wcsc-${{ matrix.ARCH }} build/wcsc
cp **-${{ matrix.ARCH }}.build/wcc-${{ matrix.ARCH }}.node build/wcc_module.node
cp **-${{ matrix.ARCH }}.build/wcsc-${{ matrix.ARCH }}.node build/wcsc_module.node
chmod +x build/*
ls -l build
node -v
Expand Down Expand Up @@ -178,7 +204,7 @@ jobs:
sudo apt install -y fuse
wget -q https://github.com/TheAssassin/pyuploadtool/releases/download/continuous/pyuploadtool-x86_64.AppImage
chmod +x pyuploadtool-x86_64.AppImage
./pyuploadtool-x86_64.AppImage **build/wcc **build/wcsc **build/wcc_module.node **build/wcsc_module.node
./pyuploadtool-x86_64.AppImage **build/wcc* **build/wcsc*

- name: Release
uses: softprops/action-gh-release@v1
Expand All @@ -189,7 +215,5 @@ jobs:
name: ${{ steps.tag.outputs.name }}
tag_name: ${{ steps.tag.outputs.tag }}
files: |
**build/wcc
**build/wcsc
**build/wcc_module.node
**build/wcsc_module.node
**build/wcc*
**build/wcsc*
3 changes: 1 addition & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.0.0)
project(wx_complier VERSION 0.1.0 LANGUAGES C CXX)

set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(TARGET_ARCH x64)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D_REENTRANT")
Expand Down Expand Up @@ -93,7 +93,6 @@ add_executable(test1
# src/wxml/expr_lib/transit_table.cpp
# )

include(CTest)
enable_testing()
add_test(transit_table_test
$<TARGET_FILE:transit_table>
Expand Down
11 changes: 11 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
## 🌈 v0.1.6 / 2025-11-

🚀Features
- 架构:添加龙芯支持

## 🌈 v0.1.5 / 2025-05-02

🚀Features

- Node模块:使用NAPI重写

## 🌈 v0.1.4 / 2025-05-01

🐞 Bug Fixes
Expand Down
17 changes: 0 additions & 17 deletions docker-compose.yml

This file was deleted.

Loading
Loading