修正gpu打包脚本中12x下载路径问题 #76 #58
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: cpu_release | |
on: | |
push: | |
tags: | |
- "v*.*.*" | |
env: | |
libtorch_version: 2.6.0 | |
jobs: | |
release_linux_glibc232: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: make | |
working-directory: ./lib | |
run: | | |
wget -q -O libtorch.zip https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-${{ env.libtorch_version }}%2Bcpu.zip | |
unzip -qq libtorch.zip | |
cmake -DCMAKE_PREFIX_PATH=./libtorch -DCMAKE_BUILD_TYPE=Release . | |
make -j | |
mv libgotorch.so libgotorch_cpu.glibc232.so | |
- name: upload | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: ./lib/libgotorch_cpu.glibc232.so | |
allowUpdates: true | |
generateReleaseNotes: true | |
token: ${{ secrets.MY_GITHUB_TOKEN }} | |
omitBody: true | |
release_linux_glibc231: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: make | |
working-directory: ./lib | |
run: | | |
wget -q -O libtorch.zip https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-${{ env.libtorch_version }}%2Bcpu.zip | |
unzip -qq libtorch.zip | |
cmake -DCMAKE_PREFIX_PATH=./libtorch -DCMAKE_BUILD_TYPE=Release . | |
make -j | |
mv libgotorch.so libgotorch_cpu.glibc231.so | |
- name: upload | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: ./lib/libgotorch_cpu.glibc231.so | |
allowUpdates: true | |
generateReleaseNotes: true | |
token: ${{ secrets.MY_GITHUB_TOKEN }} | |
omitBody: true | |
# release_macos_x86_64: | |
# runs-on: macos-11 | |
# steps: | |
# - uses: actions/checkout@v4 | |
# - name: make | |
# working-directory: ./lib | |
# run: | | |
# wget -q -O libtorch.zip https://download.pytorch.org/libtorch/cpu/libtorch-macos-x86_64-${{ env.libtorch_version }}.zip | |
# unzip -qq libtorch.zip | |
# cmake -DCMAKE_PREFIX_PATH=./libtorch -DCMAKE_BUILD_TYPE=Release . | |
# make -j | |
# mv libgotorch.dylib libgotorch_cpu_x86_64.dylib | |
# - name: upload | |
# uses: ncipollo/release-action@v1 | |
# with: | |
# artifacts: ./lib/libgotorch_cpu_x86_64.dylib | |
# allowUpdates: true | |
# generateReleaseNotes: true | |
# token: ${{ secrets.MY_GITHUB_TOKEN }} | |
# omitBody: true | |
release_macos_arm64: | |
runs-on: macos-14 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: make | |
working-directory: ./lib | |
run: | | |
wget -q -O libtorch.zip https://download.pytorch.org/libtorch/cpu/libtorch-macos-arm64-${{ env.libtorch_version }}.zip | |
unzip -qq libtorch.zip | |
cmake -DCMAKE_PREFIX_PATH=./libtorch -DCMAKE_BUILD_TYPE=Release . | |
make -j | |
mv libgotorch.dylib libgotorch_cpu_arm64.dylib | |
- name: upload | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: ./lib/libgotorch_cpu_arm64.dylib | |
allowUpdates: true | |
generateReleaseNotes: true | |
token: ${{ secrets.MY_GITHUB_TOKEN }} | |
omitBody: true | |
release_windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: microsoft/setup-msbuild@v2 | |
- name: make | |
working-directory: ./lib | |
run: | | |
curl -o libtorch.zip https://download.pytorch.org/libtorch/cpu/libtorch-win-shared-with-deps-${{ env.libtorch_version }}%2Bcpu.zip | |
unzip -qq libtorch.zip | |
cmake -DCMAKE_PREFIX_PATH=${{ github.workspace }}\lib\libtorch . | |
msbuild gotorch.sln -p:Configuration=Release | |
mv Release\gotorch.dll Release\gotorch_cpu.dll | |
- name: upload | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: ./lib/Release/gotorch_cpu.dll | |
allowUpdates: true | |
generateReleaseNotes: true | |
token: ${{ secrets.MY_GITHUB_TOKEN }} | |
omitBody: true |