Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/GStreamer/orc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNirbheek Chauhan <nirbheek@centricular.com>2022-01-28 10:07:12 +0300
committerNirbheek Chauhan <nirbheek@centricular.com>2022-01-28 10:22:22 +0300
commit61125caa52c53b62ccc889e672117eb47c67e13e (patch)
tree3f86914f9a0e053933810b29ab54d81ab614ee56
parent58939aa6d83c37a89a4349e5df935c8858896bcc (diff)
ci: Add ARM64 and ARM Windows UWP jobs
Cross and native files are modified versions of the files used in the gstreamer CI since we use the same Docker image. Part-of: <https://gitlab.freedesktop.org/gstreamer/orc/-/merge_requests/64>
-rw-r--r--.gitlab-ci.yml33
-rw-r--r--ci/vs2019-arm-uwp-cross-file.txt29
-rw-r--r--ci/vs2019-arm64-uwp-cross-file.txt29
-rw-r--r--ci/vs2019-x64-native-file.txt38
4 files changed, 122 insertions, 7 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 2a56679..5ff9470 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -37,22 +37,18 @@ debian sid:
# Make sure any failure in PowerShell scripts is fatal
ErrorActionPreference: 'Stop'
WarningPreference: 'Stop'
- # Uncomment the following key if need to pass custom args, as well with the
- # $env:MESON_ARGS line in the `script:` blocks
- # MESON_ARGS: >-
- # -Dfoo=enabled
- # -Dbar=disabled
+ MESON_ARGS: ' '
before_script:
# Make sure meson is up to date, so we don't need to rebuild the image with each release
- pip3 install -U meson ninja
script:
# For some reason, options are separated by newline instead of space, so we
# have to replace them first.
- #- $env:MESON_ARGS = $env:MESON_ARGS.replace("`n"," ")
+ - $env:MESON_ARGS = $env:MESON_ARGS.replace("`n"," ")
# Gitlab executes PowerShell in docker, but VsDevCmd.bat is a batch script.
# Environment variables substitutions is done by PowerShell before calling
# cmd.exe, that's why we use $env:FOO instead of %FOO%
- - cmd.exe /C "C:\BuildTools\Common7\Tools\VsDevCmd.bat -host_arch=amd64 -arch=$env:ARCH &&
+ - cmd.exe /C "C:\BuildTools\Common7\Tools\VsDevCmd.bat -host_arch=amd64 -arch=$env:ARCH -app_platform=$env:PLAT &&
meson setup build $env:MESON_ARGS &&
meson compile --verbose -C build &&
meson test -C build &&
@@ -62,11 +58,34 @@ vs2019 amd64:
extends: '.build windows'
variables:
ARCH: 'amd64'
+ PLAT: 'Desktop'
vs2019 x86:
extends: '.build windows'
variables:
ARCH: 'x86'
+ PLAT: 'Desktop'
+
+vs2019 arm64 UWP:
+ extends: '.build windows'
+ variables:
+ ARCH: 'arm64'
+ PLAT: 'UWP'
+ MESON_ARGS: >
+ --cross-file ci/vs2019-arm64-uwp-cross-file.txt
+ --native-file ci/vs2019-x64-native-file.txt
+
+vs2019 arm UWP:
+ extends: '.build windows'
+ # Known to not work, but maybe we'll want it later
+ when: 'manual'
+ allow_failure: true
+ variables:
+ ARCH: 'arm'
+ PLAT: 'UWP'
+ MESON_ARGS: >
+ --cross-file ci/vs2019-arm-uwp-cross-file.txt
+ --native-file ci/vs2019-x64-native-file.txt
msys2:
extends: '.build windows'
diff --git a/ci/vs2019-arm-uwp-cross-file.txt b/ci/vs2019-arm-uwp-cross-file.txt
new file mode 100644
index 0000000..1a9aaf3
--- /dev/null
+++ b/ci/vs2019-arm-uwp-cross-file.txt
@@ -0,0 +1,29 @@
+[constants]
+vs_path = 'C:\BuildTools'
+msvc_version = '14.29.30133'
+msvc_version_dir = vs_path / 'VC\Tools\MSVC' / msvc_version
+msvc_arm_bindir = msvc_version_dir / 'bin\Hostx64\arm'
+msvc_arm_libdir = msvc_version_dir / 'lib\arm'
+
+[host_machine]
+system = 'windows'
+cpu_family = 'arm'
+cpu = 'armv7'
+endian = 'little'
+
+[properties]
+needs_exe_wrapper = true
+
+[built-in options]
+c_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP']
+cpp_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP']
+c_link_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP', '-APPCONTAINER', 'WindowsApp.lib']
+cpp_link_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP', '-APPCONTAINER', 'WindowsApp.lib']
+
+[binaries]
+lib = msvc_arm_bindir / 'lib.exe'
+c = msvc_arm_bindir / 'cl.exe'
+c_ld = msvc_arm_bindir / 'link.exe'
+cpp = msvc_arm_bindir / 'cl.exe'
+cpp_ld = msvc_arm_bindir / 'link.exe'
+pkgconfig = 'false'
diff --git a/ci/vs2019-arm64-uwp-cross-file.txt b/ci/vs2019-arm64-uwp-cross-file.txt
new file mode 100644
index 0000000..ffa9764
--- /dev/null
+++ b/ci/vs2019-arm64-uwp-cross-file.txt
@@ -0,0 +1,29 @@
+[constants]
+vs_path = 'C:\BuildTools'
+msvc_version = '14.29.30133'
+msvc_version_dir = vs_path / 'VC\Tools\MSVC' / msvc_version
+msvc_arm64_bindir = msvc_version_dir / 'bin\Hostx64\arm64'
+msvc_arm64_libdir = msvc_version_dir / 'lib\arm64'
+
+[host_machine]
+system = 'windows'
+cpu_family = 'aarch64'
+cpu = 'aarch64'
+endian = 'little'
+
+[properties]
+needs_exe_wrapper = true
+
+[built-in options]
+c_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP']
+cpp_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP']
+c_link_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP', '-APPCONTAINER', 'WindowsApp.lib']
+cpp_link_args = ['-DWINAPI_FAMILY=WINAPI_FAMILY_APP', '-APPCONTAINER', 'WindowsApp.lib']
+
+[binaries]
+lib = msvc_arm64_bindir / 'lib.exe'
+c = msvc_arm64_bindir / 'cl.exe'
+c_ld = msvc_arm64_bindir / 'link.exe'
+cpp = msvc_arm64_bindir / 'cl.exe'
+cpp_ld = msvc_arm64_bindir / 'link.exe'
+pkgconfig = 'false'
diff --git a/ci/vs2019-x64-native-file.txt b/ci/vs2019-x64-native-file.txt
new file mode 100644
index 0000000..f4568d7
--- /dev/null
+++ b/ci/vs2019-x64-native-file.txt
@@ -0,0 +1,38 @@
+[constants]
+vs_path = 'C:\BuildTools'
+msvc_version = '14.29.30133'
+msvc_version_dir = vs_path / 'VC\Tools\MSVC' / msvc_version
+msvc_x64_bindir = msvc_version_dir / 'bin\Hostx64\x64'
+msvc_x64_libdir = msvc_version_dir / 'lib\x64'
+wk_path = 'C:\Program Files (x86)\Windows Kits'
+wk_version = '10.0.19041.0'
+wk_x64_libdir = wk_path / '10\lib' / wk_version / 'um\x64'
+wk_x64_crt_libdir = wk_path / '10\lib' / wk_version / 'ucrt\x64'
+# Forcibly link to x64 libs when using native linker, otherwise the LIB
+# variable in the env will cause link.exe to pick up libs from the cross
+# msvc libdir. A better fix might be to use a wrapper script that calls
+# link.exe inside the correct VS environment for x64.
+msvc_x64_libs = [msvc_x64_libdir / 'msvcrt.lib', msvc_x64_libdir / 'msvcrtd.lib', msvc_x64_libdir / 'vcruntime.lib', msvc_x64_libdir / 'oldnames.lib', wk_x64_crt_libdir / 'ucrt.lib']
+
+[host_machine]
+system = 'windows'
+cpu_family = 'x86_64'
+cpu = 'x86_64'
+endian = 'little'
+
+[properties]
+needs_exe_wrapper = true
+
+[built-in options]
+# Ensure that x64 libs are used for linking even when we're inside, say, an
+# arm64 VS environment
+c_link_args = ['/LIBPATH:' + wk_x64_libdir] + msvc_x64_libs
+cpp_link_args = ['/LIBPATH:' + wk_x64_libdir] + msvc_x64_libs
+
+[binaries]
+lib = msvc_x64_bindir / 'lib.exe'
+c = msvc_x64_bindir / 'cl.exe'
+c_ld = msvc_x64_bindir / 'link.exe'
+cpp = msvc_x64_bindir / 'cl.exe'
+cpp_ld = msvc_x64_bindir / 'link.exe'
+pkgconfig = 'false'