mirror of
				https://gitlab.gnome.org/GNOME/glib.git
				synced 2025-11-04 01:58:54 +01:00 
			
		
		
		
	CI: Add CI job for VS2019 ARM64 builds
We need to write a Meson cross-compilation file on the fly here, hence the additions in test-msvc.bat to set up the paths. Like the 32-bit VS2019 CI job this is only run manually or weekly.
This commit is contained in:
		@@ -690,6 +690,42 @@ vs2019-x86:
 | 
			
		||||
      - _build/gthread/libgthread-2.0-0.dll
 | 
			
		||||
      - _build/gobject/libgobject-2.0-0.dll
 | 
			
		||||
 | 
			
		||||
vs2019-arm64:
 | 
			
		||||
  extends: .only-schedules-or-manual
 | 
			
		||||
  stage: build
 | 
			
		||||
  tags:
 | 
			
		||||
    - win32-ps
 | 
			
		||||
  needs: []
 | 
			
		||||
  variables:
 | 
			
		||||
    GIT_SUBMODULE_STRATEGY: recursive
 | 
			
		||||
    GIT_SUBMODULE_DEPTH: 1
 | 
			
		||||
    PYTHONUTF8: "1"
 | 
			
		||||
  script:
 | 
			
		||||
    # FIXME: These should use --wrap-mode=nodownload but the Windows CI machines
 | 
			
		||||
    # aren’t currently set up for that.
 | 
			
		||||
    # FIXME: Use --meson-fatal-warnings once we've enabled c_std=gnu99,c99
 | 
			
		||||
    # for the runner's Meson version.
 | 
			
		||||
    - .gitlab-ci/test-msvc.bat --buildtype debug
 | 
			
		||||
                               --wrap-mode=default
 | 
			
		||||
                               --python.platlibdir=C:\Python37\site-packages
 | 
			
		||||
                               --python.purelibdir=C:\Python37\site-packages
 | 
			
		||||
                               --plat=x64_arm64
 | 
			
		||||
  artifacts:
 | 
			
		||||
    reports:
 | 
			
		||||
      junit:
 | 
			
		||||
        - _build/meson-logs/testlog.junit.xml
 | 
			
		||||
        - _build/meson-logs/testlog-*.junit.xml
 | 
			
		||||
    name: "glib-${env:CI_JOB_NAME}-${env:CI_COMMIT_REF_NAME}"
 | 
			
		||||
    when: always
 | 
			
		||||
    expire_in: 1 week
 | 
			
		||||
    paths:
 | 
			
		||||
      - _build/meson-logs
 | 
			
		||||
      - _build/glib/libglib-2.0-0.dll
 | 
			
		||||
      - _build/gio/libgio-2.0-0.dll
 | 
			
		||||
      - _build/gmodule/libgmodule-2.0-0.dll
 | 
			
		||||
      - _build/gthread/libgthread-2.0-0.dll
 | 
			
		||||
      - _build/gobject/libgobject-2.0-0.dll
 | 
			
		||||
 | 
			
		||||
freebsd-13-x86_64:
 | 
			
		||||
  extends: .only-schedules-or-manual
 | 
			
		||||
  stage: build
 | 
			
		||||
 
 | 
			
		||||
@@ -16,6 +16,30 @@ if "!plat!" == "" set plat=x64
 | 
			
		||||
:: specified build architecture
 | 
			
		||||
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Auxiliary\Build\vcvarsall.bat" !plat!
 | 
			
		||||
 | 
			
		||||
:: Setup and write a cross-compilation file for ARM64 builds
 | 
			
		||||
if not "!plat!" == "x64_arm64" goto :continue_build
 | 
			
		||||
set cross_file=vs2019-arm64.txt
 | 
			
		||||
echo [host_machine]>!cross_file!
 | 
			
		||||
echo system = 'windows'>>!cross_file!
 | 
			
		||||
echo cpu_family = 'aarch64'>>!cross_file!
 | 
			
		||||
echo cpu = 'arm64'>>!cross_file!
 | 
			
		||||
echo endian = 'little'>>!cross_file!
 | 
			
		||||
echo.>>!cross_file!
 | 
			
		||||
echo [binaries]>>!cross_file!
 | 
			
		||||
echo c = 'cl'>>!cross_file!
 | 
			
		||||
echo cpp = 'cl'>>!cross_file!
 | 
			
		||||
echo c_ld = 'link'>>!cross_file!
 | 
			
		||||
echo cpp_ld = 'link'>>!cross_file!
 | 
			
		||||
echo ar = 'lib'>>!cross_file!
 | 
			
		||||
echo windres = 'rc'>>!cross_file!
 | 
			
		||||
 | 
			
		||||
echo.>>!cross_file!
 | 
			
		||||
echo [properties]>>!cross_file!
 | 
			
		||||
echo skip_sanity_check = true>>!cross_file!
 | 
			
		||||
 | 
			
		||||
set args=%args% --cross-file=!cross_file!
 | 
			
		||||
 | 
			
		||||
:continue_build
 | 
			
		||||
pip3 install --upgrade --user meson==1.4.2 || goto :error
 | 
			
		||||
meson setup %args% _build || goto :error
 | 
			
		||||
meson compile -C _build || goto :error
 | 
			
		||||
@@ -30,6 +54,7 @@ if not "!plat!" == "x64_x86" meson test -v -C _build --timeout-multiplier %MESON
 | 
			
		||||
meson test -v -C _build --timeout-multiplier %MESON_TEST_TIMEOUT_MULTIPLIER% --setup=unstable_tests --suite=failing --suite=flaky
 | 
			
		||||
 | 
			
		||||
:: FIXME: can we get code coverage support?
 | 
			
		||||
if not "!cross_file!" == "" if exist !cross_file! del /f/q !cross_file!
 | 
			
		||||
 | 
			
		||||
goto :EOF
 | 
			
		||||
:error
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user