Toggle navigation
Toggle navigation
此项目
正在载入...
Sign in
xuning
/
sherpaonnx
转到一个项目
Toggle navigation
项目
群组
代码片段
帮助
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
Fangjun Kuang
2023-11-18 16:13:09 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Committed by
GitHub
2023-11-18 16:13:09 +0800
Commit
ac00edab5bec3b2a5ef69ddde79bce40095d90c2
ac00edab
1 parent
1a6a41eb
Build MFC examples for Windows x86 (Win32) (#434)
Also, strip binaries on Linux before uploading.
隐藏空白字符变更
内嵌
并排对比
正在显示
5 个修改的文件
包含
71 行增加
和
31 行删除
.github/workflows/aarch64-linux-gnu-shared.yaml
.github/workflows/aarch64-linux-gnu-static.yaml
.github/workflows/arm-linux-gnueabihf.yaml
.github/workflows/linux.yaml
.github/workflows/mfc.yaml
.github/workflows/aarch64-linux-gnu-shared.yaml
查看文件 @
ac00eda
...
...
@@ -24,15 +24,6 @@ on:
-
'
toolchains/aarch64-linux-gnu.toolchain.cmake'
workflow_dispatch
:
inputs
:
release
:
description
:
"
Whether
to
release"
type
:
boolean
env
:
RELEASE
:
|-
# Release if there is a release tag name or a release flag in workflow_dispatch
${{ github.event.release.tag_name != '' || github.event.inputs.release == 'true' }}
concurrency
:
group
:
aarch64-linux-gnu-shared-${{ github.ref }}
...
...
@@ -150,6 +141,9 @@ jobs:
-
name
:
Copy files
shell
:
bash
run
:
|
export PATH=$GITHUB_WORKSPACE/toolchain/bin:$PATH
aarch64-none-linux-gnu-strip --version
SHERPA_ONNX_VERSION=v$(grep "SHERPA_ONNX_VERSION" ./CMakeLists.txt | cut -d " " -f 2 | cut -d '"' -f 2)
dst=sherpa-onnx-${SHERPA_ONNX_VERSION}-linux-aarch64-shared
...
...
@@ -158,6 +152,13 @@ jobs:
cp -a build-aarch64-linux-gnu/install/bin $dst/
cp -a build-aarch64-linux-gnu/install/lib $dst/
ls -lh build-aarch64-linux-gnu/install/lib
ls -lh build-aarch64-linux-gnu/install/bin
ls -lh $dst/bin/
echo "strip"
aarch64-none-linux-gnu-strip $dst/bin/*
tree $dst
tar cjvf ${dst}.tar.bz2 $dst
...
...
@@ -168,7 +169,7 @@ jobs:
path
:
sherpa-onnx-*linux-aarch64-shared.tar.bz2
-
name
:
Release pre-compiled binaries and libs for aarch64 linux
if
:
env.RELEASE == 'true'
if
:
github.repository_owner == 'csukuangfj' || github.repository_owner == 'k2-fsa' && github.event_name == 'push' && contains(github.ref, 'refs/tags/')
uses
:
svenstaro/upload-release-action@v2
with
:
file_glob
:
true
...
...
.github/workflows/aarch64-linux-gnu-static.yaml
查看文件 @
ac00eda
...
...
@@ -24,15 +24,6 @@ on:
-
'
toolchains/aarch64-linux-gnu.toolchain.cmake'
workflow_dispatch
:
inputs
:
release
:
description
:
"
Whether
to
release"
type
:
boolean
env
:
RELEASE
:
|-
# Release if there is a release tag name or a release flag in workflow_dispatch
${{ github.event.release.tag_name != '' || github.event.inputs.release == 'true' }}
concurrency
:
group
:
aarch64-linux-gnu-static-${{ github.ref }}
...
...
@@ -151,13 +142,21 @@ jobs:
-
name
:
Copy files
shell
:
bash
run
:
|
export PATH=$GITHUB_WORKSPACE/toolchain/bin:$PATH
aarch64-none-linux-gnu-strip --version
SHERPA_ONNX_VERSION=v$(grep "SHERPA_ONNX_VERSION" ./CMakeLists.txt | cut -d " " -f 2 | cut -d '"' -f 2)
dst=sherpa-onnx-${SHERPA_ONNX_VERSION}-linux-aarch64-static
mkdir $dst
ls -lh build-aarch64-linux-gnu/install/lib
cp -a build-aarch64-linux-gnu/install/bin $dst/
cp -a build-aarch64-linux-gnu/install/lib $dst/
ls -lh $dst/bin/
echo "strip"
aarch64-none-linux-gnu-strip $dst/bin/*
ls -lh $dst/bin/
tree $dst
...
...
@@ -169,7 +168,7 @@ jobs:
path
:
sherpa-onnx-*linux-aarch64-static.tar.bz2
-
name
:
Release pre-compiled binaries and libs for aarch64 linux
if
:
env.RELEASE == 'true'
if
:
github.repository_owner == 'csukuangfj' || github.repository_owner == 'k2-fsa' && github.event_name == 'push' && contains(github.ref, 'refs/tags/')
uses
:
svenstaro/upload-release-action@v2
with
:
file_glob
:
true
...
...
.github/workflows/arm-linux-gnueabihf.yaml
查看文件 @
ac00eda
...
...
@@ -150,13 +150,25 @@ jobs:
-
name
:
Copy files
shell
:
bash
run
:
|
export PATH=$GITHUB_WORKSPACE/toolchain/bin:$PATH
arm-none-linux-gnueabihf-strip --version
SHERPA_ONNX_VERSION=v$(grep "SHERPA_ONNX_VERSION" ./CMakeLists.txt | cut -d " " -f 2 | cut -d '"' -f 2)
dst=sherpa-onnx-${SHERPA_ONNX_VERSION}-linux-arm-gnueabihf-${{ matrix.lib_type }}
mkdir $dst
ls -lh build-arm-linux-gnueabihf/install/lib
cp -a build-arm-linux-gnueabihf/install/bin $dst/
cp -a build-arm-linux-gnueabihf/install/lib $dst/
ls -lh $dst/bin/*
arm-none-linux-gnueabihf-strip $dst/bin/*
ls -lh $dst
lib_type=${{ matrix.lib_type }}
if [[ $lib_type == "shared" ]]; then
cp -a build-arm-linux-gnueabihf/install/lib $dst/
fi
tree $dst
...
...
.github/workflows/linux.yaml
查看文件 @
ac00eda
...
...
@@ -88,9 +88,25 @@ jobs:
-
name
:
Display dependencies of sherpa-onnx for linux
shell
:
bash
run
:
|
ls -lh build/bin
ls -lh build/_deps/onnxruntime-src/lib/
echo "strip"
strip build/bin/*
echo "after strip"
ls -lh build/bin
file build/bin/sherpa-onnx
file build/bin/sherpa-onnx
ls -lh build/bin/sherpa-onnx
readelf -d build/bin/sherpa-onnx
-
uses
:
actions/upload-artifact@v3
if
:
matrix.shared_lib == 'OFF' && matrix.build_type == 'Release'
with
:
name
:
release-static
path
:
build/bin/*
-
name
:
Test online CTC
shell
:
bash
run
:
|
...
...
@@ -186,3 +202,4 @@ jobs:
with
:
name
:
tts-generated-test-files
path
:
tts
...
...
.github/workflows/mfc.yaml
查看文件 @
ac00eda
...
...
@@ -36,8 +36,7 @@ jobs:
fail-fast
:
false
matrix
:
os
:
[
windows-latest
]
# arch: [x64, Win32]
arch
:
[
x64
]
arch
:
[
x64
,
x86
]
steps
:
-
uses
:
actions/checkout@v4
...
...
@@ -55,7 +54,11 @@ jobs:
run
:
|
mkdir build
cd build
cmake -A ${{ matrix.arch }} -D CMAKE_BUILD_TYPE=Release -D BUILD_SHARED_LIBS=OFF -DCMAKE_INSTALL_PREFIX=./install ..
arch=${{ matrix.arch }}
if [[ $arch == "x86" ]]; then
arch=Win32
fi
cmake -A $arch -D CMAKE_BUILD_TYPE=Release -D BUILD_SHARED_LIBS=OFF -DCMAKE_INSTALL_PREFIX=./install ..
-
name
:
Build sherpa-onnx for windows
shell
:
bash
...
...
@@ -83,32 +86,40 @@ jobs:
run
:
|
SHERPA_ONNX_VERSION=v$(grep "SHERPA_ONNX_VERSION" ./CMakeLists.txt | cut -d " " -f 2 | cut -d '"' -f 2)
arch=${{ matrix.arch }}
if [[ $arch == "x86" ]]; then
src=mfc-examples/Release
ls -h $src
dst=mfc-examples/$arch/Release
mkdir -p $dst
cp $src/* $dst
fi
cd mfc-examples/$arch/Release
ls -lh
cp -v StreamingSpeechRecognition.exe sherpa-onnx-streaming-${SHERPA_ONNX_VERSION}.exe
cp -v NonStreamingSpeechRecognition.exe sherpa-onnx-non-streaming-${SHERPA_ONNX_VERSION}.exe
cp -v NonStreamingTextToSpeech.exe ../sherpa-onnx-non-streaming-tts-${SHERPA_ONNX_VERSION}.exe
cp -v StreamingSpeechRecognition.exe sherpa-onnx-streaming-asr-$arch-${SHERPA_ONNX_VERSION}.exe
cp -v NonStreamingSpeechRecognition.exe sherpa-onnx-non-streaming-asr-$arch-${SHERPA_ONNX_VERSION}.exe
cp -v NonStreamingTextToSpeech.exe ../sherpa-onnx-non-streaming-tts-$arch-${SHERPA_ONNX_VERSION}.exe
ls -lh
-
name
:
Upload artifact tts
uses
:
actions/upload-artifact@v3
with
:
name
:
non-streaming-tts-${{ matrix.arch }}
path
:
./mfc-examples/${{ matrix.arch }}/
Release/NonStreamingTextToSpeech
.exe
path
:
./mfc-examples/${{ matrix.arch }}/
sherpa-onnx-non-streaming-tts-*
.exe
-
name
:
Upload artifact
uses
:
actions/upload-artifact@v3
with
:
name
:
streaming-speech-recognition-${{ matrix.arch }}
path
:
./mfc-examples/${{ matrix.arch }}/Release/
StreamingSpeechRecognition
.exe
path
:
./mfc-examples/${{ matrix.arch }}/Release/
sherpa-onnx-streaming-asr-*
.exe
-
name
:
Upload artifact
uses
:
actions/upload-artifact@v3
with
:
name
:
non-streaming-speech-recognition-${{ matrix.arch }}
path
:
./mfc-examples/${{ matrix.arch }}/Release/
NonStreamingSpeechRecognition
.exe
path
:
./mfc-examples/${{ matrix.arch }}/Release/
sherpa-onnx-non-streaming-asr-*
.exe
-
name
:
Release pre-compiled binaries and libs for Windows ${{ matrix.arch }}
if
:
github.repository_owner == 'csukuangfj' || github.repository_owner == 'k2-fsa' && github.event_name == 'push' && contains(github.ref, 'refs/tags/')
...
...
请
注册
或
登录
后发表评论