forked from weianweigan/manifold-csharp
-
Notifications
You must be signed in to change notification settings - Fork 0
72 lines (62 loc) · 2.63 KB
/
nuget_bas.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: nuget_bas
on:
push:
tags:
- "*"
workflow_dispatch:
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: jwlawson/actions-setup-cmake@v2
- uses: ilammy/msvc-dev-cmd@v1
# Install vcpkg so assimp and tbb can be installed
- name: Install vcpkg
shell: powershell
run: |
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg; .\bootstrap-vcpkg.bat
$path = (Get-Location).Path
$env:VCPKG_ROOT = "$path\vcpkg"
$env:PATH = "$env:VCPKG_ROOT;$env:PATH"
vcpkg install assimp
vcpkg install tbb
vcpkg install clipper2
# Build release
- name: Build
shell: powershell
run: |
$path = (Get-Location).Path
cmake . -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=OFF -DMANIFOLD_DEBUG=ON -DMANIFOLD_PAR=TBB -DCMAKE_PREFIX_PATH="$path/vcpkg/installed/x64-windows/share" -A x64 -B build
cd build
cmake --build . --target ALL_BUILD --config Release
- name: Copy to bindary
shell: powershell
run: |
robocopy build\bin\Release bindings\csharp\ManifoldNET\runtimes\win-x64\binary\Release /NFL /NDL /R:0 /W:0; exit 0
- name: Copy tbb12 binary to Release_MeshExport
shell: powershell
run: |
dir bindings\csharp\ManifoldNET\runtimes\win-x64\binary\Release
robocopy vcpkg\installed\x64-windows\bin bindings\csharp\ManifoldNET\runtimes\win-x64\binary\Release /NFL /NDL /R:0 /W:0; exit 0
# Build release with mesh export option.
- name: Build with mesh export on
shell: powershell
run: |
Remove-Item -Path "build\bin\Release" -Force -Recurse
$path = (Get-Location).Path
cmake . -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=OFF -DMANIFOLD_DEBUG=ON -DMANIFOLD_PAR=TBB -DMANIFOLD_EXPORT=ON -DCMAKE_PREFIX_PATH="$path/vcpkg/installed/x64-windows/share" -A x64 -B build
cd build
cmake --build . --target ALL_BUILD --config Release
- name: Copy to bindary
shell: powershell
run: |
robocopy build\bin\Release bindings\csharp\ManifoldNET\runtimes\win-x64\binary\Release_MeshExport /NFL /NDL /R:0 /W:0; exit 0
- name: Copy assimp binary to Release_MeshExport
shell: powershell
run: |
dir bindings\csharp\ManifoldNET\runtimes\win-x64\binary\Release_MeshExport
robocopy vcpkg\installed\x64-windows\bin bindings\csharp\ManifoldNET\runtimes\win-x64\binary\Release_MeshExport /NFL /NDL /R:0 /W:0; exit 0