diff --git a/.azure-pipelines/azure-pipelines-win.yml b/.azure-pipelines/azure-pipelines-win.yml index f533bda..822de31 100755 --- a/.azure-pipelines/azure-pipelines-win.yml +++ b/.azure-pipelines/azure-pipelines-win.yml @@ -17,6 +17,15 @@ jobs: resize_partitions: false store_build_artifacts: false tools_install_dir: D:\Miniforge + win_arm64_: + CONFIG: win_arm64_ + UPLOAD_PACKAGES: 'True' + build_workspace_dir: C:\\bld\\ + free_disk_space: skip + pagefile_size: 0 + resize_partitions: false + store_build_artifacts: false + tools_install_dir: C:\Miniforge timeoutInMinutes: 360 variables: UPLOAD_TEMP: D:\\tmp diff --git a/.ci_support/win_arm64_.yaml b/.ci_support/win_arm64_.yaml new file mode 100644 index 0000000..4f9e56b --- /dev/null +++ b/.ci_support/win_arm64_.yaml @@ -0,0 +1,12 @@ +c_compiler: +- vs2022 +c_stdlib: +- vs +channel_sources: +- conda-forge +channel_targets: +- conda-forge main +cxx_compiler: +- vs2022 +target_platform: +- win-arm64 diff --git a/README.md b/README.md index 58bc8cf..d5a05cf 100644 --- a/README.md +++ b/README.md @@ -179,5 +179,6 @@ In order to produce a uniquely identifiable distribution: Feedstock Maintainers ===================== +* [@JohanMabille](https://github.com/JohanMabille/) * [@tschoonj](https://github.com/tschoonj/) diff --git a/conda-forge.yml b/conda-forge.yml index bde99a9..c69bf20 100644 --- a/conda-forge.yml +++ b/conda-forge.yml @@ -2,6 +2,7 @@ build_platform: linux_aarch64: linux_64 linux_ppc64le: linux_64 osx_arm64: osx_64 + win_arm64: win_64 conda_build: pkg_format: '2' conda_build_tool: rattler-build diff --git a/recipe/build.bat b/recipe/build.bat index fe9d305..583855c 100644 --- a/recipe/build.bat +++ b/recipe/build.bat @@ -8,13 +8,26 @@ set "PKG_CONFIG_PATH=%LIBRARY_LIB%\pkgconfig;%LIBRARY_PREFIX%\share\pkgconfig" :: get mixed path (forward slash) form of prefix so host prefix replacement works set "LIBRARY_PREFIX_M=%LIBRARY_PREFIX:\=/%" -set "MESON_ARGS=--wrap-mode=nofallback --buildtype=release --prefix=%LIBRARY_PREFIX_M% --backend=ninja -Dbuiltin=true" +:: Preserve MESON_ARGS from the compiler activation. For win-arm64 cross builds +:: that includes --cross-file (needs_exe_wrapper), without which meson treats the +:: build as native and fails the sanity check with WinError 216 on the x64 host. +if "%MESON_ARGS%"=="" ( + set "MESON_ARGS=--buildtype=release --prefix=%LIBRARY_PREFIX_M% --libdir=lib" +) +:: win-arm64: no ICU (builtin PSL only). Same runtime=no as the static build. if "%PKG_NAME%"=="libpsl-static" ( - %BUILD_PREFIX%\Scripts\meson.exe setup builddir %MESON_ARGS% -Druntime=no --default-library=static + set "PSL_RUNTIME=no" + set "PSL_LIBRARY=static" +) else if "%target_platform%"=="win-arm64" ( + set "PSL_RUNTIME=no" + set "PSL_LIBRARY=shared" ) else ( - %BUILD_PREFIX%\Scripts\meson.exe setup builddir %MESON_ARGS% -Druntime=libicu --default-library=shared + set "PSL_RUNTIME=libicu" + set "PSL_LIBRARY=shared" ) + +%BUILD_PREFIX%\Scripts\meson.exe setup builddir %MESON_ARGS% --wrap-mode=nofallback --backend=ninja -Dbuiltin=true -Druntime=%PSL_RUNTIME% --default-library=%PSL_LIBRARY% if errorlevel 1 exit 1 ninja -v -C builddir -j %CPU_COUNT% diff --git a/recipe/recipe.yaml b/recipe/recipe.yaml index 02a5c42..903ebe6 100644 --- a/recipe/recipe.yaml +++ b/recipe/recipe.yaml @@ -1,6 +1,6 @@ context: version: "0.22.0" - build_number: 2 + build_number: 3 recipe: name: libpsl-packages @@ -44,7 +44,9 @@ outputs: - pkg-config - meson host: - - icu + - if: not (win and arm64) + then: + - icu tests: - script: - if: unix