Fix publishing linux pre-built artifacts (#1919)
This commit is contained in:
96
.github/workflows/linux.yaml
vendored
96
.github/workflows/linux.yaml
vendored
@@ -142,11 +142,66 @@ jobs:
|
|||||||
ls -lh build/bin/sherpa-onnx
|
ls -lh build/bin/sherpa-onnx
|
||||||
readelf -d build/bin/sherpa-onnx
|
readelf -d build/bin/sherpa-onnx
|
||||||
|
|
||||||
|
rm -fv build/install/include/cargs.h
|
||||||
|
rm -fv build/install/lib/cargs.h
|
||||||
|
rm -fv build/install/lib/libcargs.so
|
||||||
|
rm -rfv build/install/lib/pkgconfig
|
||||||
|
|
||||||
- uses: actions/upload-artifact@v4
|
- uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: release-${{ matrix.build_type }}-with-shared-lib-${{ matrix.shared_lib }}-with-tts-${{ matrix.with_tts }}
|
name: release-${{ matrix.build_type }}-with-shared-lib-${{ matrix.shared_lib }}-with-tts-${{ matrix.with_tts }}
|
||||||
path: install/*
|
path: install/*
|
||||||
|
|
||||||
|
- name: Copy files
|
||||||
|
shell: bash
|
||||||
|
if: matrix.build_type == 'Release'
|
||||||
|
run: |
|
||||||
|
du -h -d1 .
|
||||||
|
SHERPA_ONNX_VERSION=v$(grep "SHERPA_ONNX_VERSION" ./CMakeLists.txt | cut -d " " -f 2 | cut -d '"' -f 2)
|
||||||
|
|
||||||
|
if [[ ${{ matrix.shared_lib }} == 'ON' ]]; then
|
||||||
|
suffix=shared
|
||||||
|
else
|
||||||
|
suffix=static
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ ${{ matrix.with_tts }} == ON ]]; then
|
||||||
|
dst=sherpa-onnx-${SHERPA_ONNX_VERSION}-linux-x64-$suffix
|
||||||
|
else
|
||||||
|
dst=sherpa-onnx-${SHERPA_ONNX_VERSION}-linux-x64-$suffix-no-tts
|
||||||
|
fi
|
||||||
|
mkdir $dst
|
||||||
|
|
||||||
|
cp -a build/install/bin $dst/
|
||||||
|
if [[ ${{ matrix.shared_lib }} == ON ]]; then
|
||||||
|
cp -av build/install/lib $dst/
|
||||||
|
fi
|
||||||
|
cp -a build/install/include $dst/
|
||||||
|
|
||||||
|
tree $dst
|
||||||
|
|
||||||
|
tar cjvf ${dst}.tar.bz2 $dst
|
||||||
|
du -h -d1 .
|
||||||
|
|
||||||
|
- name: Release pre-compiled binaries and libs for linux x64
|
||||||
|
if: github.repository_owner == 'csukuangfj' && github.event_name == 'push' && contains(github.ref, 'refs/tags/') && matrix.build_type == 'Release'
|
||||||
|
uses: svenstaro/upload-release-action@v2
|
||||||
|
with:
|
||||||
|
file_glob: true
|
||||||
|
overwrite: true
|
||||||
|
file: sherpa-onnx-*.tar.bz2
|
||||||
|
# repo_name: k2-fsa/sherpa-onnx
|
||||||
|
# repo_token: ${{ secrets.UPLOAD_GH_SHERPA_ONNX_TOKEN }}
|
||||||
|
# tag: v1.10.45
|
||||||
|
|
||||||
|
- name: Release pre-compiled binaries and libs for linux x64
|
||||||
|
if: github.repository_owner == 'k2-fsa' && github.event_name == 'push' && contains(github.ref, 'refs/tags/') && matrix.build_type == 'Release'
|
||||||
|
uses: svenstaro/upload-release-action@v2
|
||||||
|
with:
|
||||||
|
file_glob: true
|
||||||
|
overwrite: true
|
||||||
|
file: sherpa-onnx-*.tar.bz2
|
||||||
|
|
||||||
- name: Test offline TTS
|
- name: Test offline TTS
|
||||||
if: matrix.with_tts == 'ON'
|
if: matrix.with_tts == 'ON'
|
||||||
shell: bash
|
shell: bash
|
||||||
@@ -324,8 +379,6 @@ jobs:
|
|||||||
.github/scripts/test-offline-whisper.sh
|
.github/scripts/test-offline-whisper.sh
|
||||||
du -h -d1 .
|
du -h -d1 .
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
- name: Test online paraformer
|
- name: Test online paraformer
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
@@ -335,42 +388,3 @@ jobs:
|
|||||||
|
|
||||||
.github/scripts/test-online-paraformer.sh
|
.github/scripts/test-online-paraformer.sh
|
||||||
du -h -d1 .
|
du -h -d1 .
|
||||||
|
|
||||||
- name: Copy files
|
|
||||||
shell: bash
|
|
||||||
if: matrix.build_type == 'Release'
|
|
||||||
run: |
|
|
||||||
du -h -d1 .
|
|
||||||
SHERPA_ONNX_VERSION=v$(grep "SHERPA_ONNX_VERSION" ./CMakeLists.txt | cut -d " " -f 2 | cut -d '"' -f 2)
|
|
||||||
|
|
||||||
if [[ ${{ matrix.shared_lib }} == 'ON' ]]; then
|
|
||||||
suffix=shared
|
|
||||||
else
|
|
||||||
suffix=static
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ ${{ matrix.with_tts }} ]]; then
|
|
||||||
dst=sherpa-onnx-${SHERPA_ONNX_VERSION}-linux-x64-$suffix
|
|
||||||
else
|
|
||||||
dst=sherpa-onnx-${SHERPA_ONNX_VERSION}-linux-x64-$suffix-no-tts
|
|
||||||
fi
|
|
||||||
mkdir $dst
|
|
||||||
|
|
||||||
cp -a build/install/bin $dst/
|
|
||||||
cp -a build/install/lib $dst/
|
|
||||||
cp -a build/install/include $dst/
|
|
||||||
|
|
||||||
tree $dst
|
|
||||||
|
|
||||||
tar cjvf ${dst}.tar.bz2 $dst
|
|
||||||
du -h -d1 .
|
|
||||||
|
|
||||||
- name: Release pre-compiled binaries and libs for linux x64
|
|
||||||
if: (github.repository_owner == 'csukuangfj' || github.repository_owner == 'k2-fsa') && github.event_name == 'push' && contains(github.ref, 'refs/tags/') && matrix.build_type == 'Release'
|
|
||||||
uses: svenstaro/upload-release-action@v2
|
|
||||||
with:
|
|
||||||
file_glob: true
|
|
||||||
overwrite: true
|
|
||||||
file: sherpa-onnx-*.tar.bz2
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
4
.github/workflows/test-build-wheel.yaml
vendored
4
.github/workflows/test-build-wheel.yaml
vendored
@@ -137,8 +137,8 @@ jobs:
|
|||||||
export PATH=/c/hostedtoolcache/windows/Python/3.9.13/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.9.13/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.10.11/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.10.11/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.11.9/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.11.9/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.12.8/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.12.9/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.13.1/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.13.2/x64/bin:$PATH
|
||||||
|
|
||||||
which sherpa-onnx
|
which sherpa-onnx
|
||||||
sherpa-onnx --help
|
sherpa-onnx --help
|
||||||
|
|||||||
4
.github/workflows/test-pip-install.yaml
vendored
4
.github/workflows/test-pip-install.yaml
vendored
@@ -110,8 +110,8 @@ jobs:
|
|||||||
export PATH=/c/hostedtoolcache/windows/Python/3.9.13/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.9.13/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.10.11/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.10.11/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.11.9/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.11.9/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.12.8/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.12.9/x64/bin:$PATH
|
||||||
export PATH=/c/hostedtoolcache/windows/Python/3.13.1/x64/bin:$PATH
|
export PATH=/c/hostedtoolcache/windows/Python/3.13.2/x64/bin:$PATH
|
||||||
|
|
||||||
sherpa-onnx --help
|
sherpa-onnx --help
|
||||||
sherpa-onnx-keyword-spotter --help
|
sherpa-onnx-keyword-spotter --help
|
||||||
|
|||||||
6
.github/workflows/windows-x64.yaml
vendored
6
.github/workflows/windows-x64.yaml
vendored
@@ -158,9 +158,9 @@ jobs:
|
|||||||
file_glob: true
|
file_glob: true
|
||||||
overwrite: true
|
overwrite: true
|
||||||
file: sherpa-onnx-*-win-x64*.tar.bz2
|
file: sherpa-onnx-*-win-x64*.tar.bz2
|
||||||
repo_name: k2-fsa/sherpa-onnx
|
# repo_name: k2-fsa/sherpa-onnx
|
||||||
repo_token: ${{ secrets.UPLOAD_GH_SHERPA_ONNX_TOKEN }}
|
# repo_token: ${{ secrets.UPLOAD_GH_SHERPA_ONNX_TOKEN }}
|
||||||
tag: v1.10.45
|
# tag: v1.10.45
|
||||||
|
|
||||||
- name: Release pre-compiled binaries and libs for Windows x64
|
- name: Release pre-compiled binaries and libs for Windows x64
|
||||||
if: github.repository_owner == 'k2-fsa'&& github.event_name == 'push' && contains(github.ref, 'refs/tags/')
|
if: github.repository_owner == 'k2-fsa'&& github.event_name == 'push' && contains(github.ref, 'refs/tags/')
|
||||||
|
|||||||
Reference in New Issue
Block a user