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
14 changes: 7 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -183,10 +183,13 @@ jobs:
include:
- platform: x86
setenv: amd64_x86
python: 32
- platform: x64
setenv: amd64
python: 64
- platform: arm64
setenv: amd64_arm64
python: arm64
env:
VER_SUFFIX: .VS${{ matrix.toolset }}
CXXFLAGS: '/D_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR' # https://github.com/actions/runner-images/issues/10004
Expand All @@ -199,26 +202,23 @@ jobs:
path: ${{ github.workspace }}/vcpkg_cache
key: vcpkg-${{ matrix.toolset }}-${{ matrix.platform }}-${{ hashFiles('vcpkg.json', 'vcpkg-ports/**') }}
- name: Install dependencies
run: winget install --silent --accept-source-agreements --accept-package-agreements swig doxygen
run: winget install --silent --accept-source-agreements --accept-package-agreements swig doxygen 9NQ7512CXL7T
- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
- uses: actions/setup-python@v5
if: matrix.platform != 'arm64'
with:
python-version: 3.12
architecture: ${{ matrix.platform }}
- name: Build
env:
VCPKG_BINARY_SOURCES: clear;files,${{ github.workspace }}/vcpkg_cache,readwrite
run: |
& "$env:LOCALAPPDATA\Microsoft\WindowsApps\py.exe" install --target=.\python\${{ matrix.platform }} 3.12-${{ matrix.python }}
$swig = (Get-Item "$env:LOCALAPPDATA\Microsoft\WinGet\Links\swig.exe").Target
& "C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\VC\\Auxiliary\\Build\\vcvarsall.bat" ${{ matrix.setenv }} "&&" pwsh build.ps1 `
-vcpkg "C:/vcpkg/vcpkg.exe" `
-swig $swig `
-doxygen "C:/Program files/doxygen/bin/doxygen.exe" `
-boost
-boost `
-python ${{ github.workspace }}/python
- name: Archive artifacts
uses: actions/upload-artifact@v5
with:
Expand Down
9 changes: 6 additions & 3 deletions build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ param(
[string]$swig = $null,
[string]$doxygen = $null,
[switch]$boost = $false,
[string]$sign = $null
[string]$sign = $null,
[string]$python = $null
)

Try {
Expand All @@ -43,14 +44,16 @@ if($doxygen) {
$cmakeext += "-DDOXYGEN_EXECUTABLE=$doxygen"
}
if($platform -eq "arm64" -and $env:VSCMD_ARG_HOST_ARCH -ne "arm64") {
$cmakeext += "-DCMAKE_DISABLE_FIND_PACKAGE_Python3=yes"
$wixext += "-d", "disablePython=1"
$boost = $false
}
if($boost) {
$cmakeext += "-DVCPKG_MANIFEST_FEATURES=tests"
$target += "check"
}
if($python) {
$cmakeext += "-DPython3_ROOT_DIR=$python/$platform"
$wixext += "-d", "python=1"
}

foreach($type in @("Debug", "RelWithDebInfo")) {
$buildpath = $platform+$type
Expand Down
4 changes: 2 additions & 2 deletions libdigidocpp.wxs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
<File Name="digidoc_csharp.dll" />
<File Name="digidoc_java.dll" />
<File Source="$(var.libdigidocpp)\share\digidocpp\digidocpp.jar" />
<?ifndef var.disablePython ?>
<?ifdef var.python ?>
<File Name="_digidoc_python.pyd" />
<File Name="digidoc.py" />
<?endif?>
Expand All @@ -88,7 +88,7 @@
<?ifdef var.swig ?>
<File Name="digidoc_csharpd.dll" />
<File Name="digidoc_javad.dll" />
<?ifndef var.disablePython ?>
<?ifdef var.python ?>
<File Name="_digidoc_pythond.pyd" />
<?endif?>
<?endif?>
Expand Down