Skip to content
Snippets Groups Projects
Commit ecf0aab0 authored by Cyril Moineau's avatar Cyril Moineau
Browse files

Remove use of Docker for Windows pipelines.

parent 0a879a14
No related branches found
No related tags found
No related merge requests found
...@@ -3,19 +3,19 @@ include: ...@@ -3,19 +3,19 @@ include:
release:pip:windows: release:pip:windows:
extends: .release:pip:template extends: .release:pip:template
image: mcr.microsoft.com/powershell:latest # image: mcr.microsoft.com/powershell:latest
tags: tags:
- windows - windows
# temporary rules until https://gitlab.eclipse.org/eclipse/aidge/aidge/-/issues/136 is closed # temporary rules until https://gitlab.eclipse.org/eclipse/aidge/aidge/-/issues/136 is closed
rules : rules :
- when : never - when : never
# - if: $CI_COMMIT_BRANCH == "main" # Only run on the main branch # - if: $CI_COMMIT_BRANCH == "main" # Only run on the main branch
# - if: $CI_COMMIT_TAG # Or if a tag is pushed # - if: $CI_COMMIT_TAG # Or if a tag is pushed
# - if: $CI_COMMIT_BRANCH == "dev" # Allow manual runs on the dev branch # - if: $CI_COMMIT_BRANCH == "dev" # Allow manual runs on the dev branch
# when: manual # when: manual
needs: needs:
- build:windows_python - build:windows_python
parallel: parallel:
...@@ -36,18 +36,18 @@ release:pip:windows: ...@@ -36,18 +36,18 @@ release:pip:windows:
# # Install dependencies # # Install dependencies
# - choco install cmake.install --installargs '"ADD_CMAKE_TO_PATH=System"' -Y # - choco install cmake.install --installargs '"ADD_CMAKE_TO_PATH=System"' -Y
# - choco install git -Y # - choco install git -Y
# - choco install python --version=$python_version -Y # - choco install python --version=$python_version -Y
# # Update PATH # # Update PATH
# - $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User") # - $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User")
# - python -m pip install cibuildwheel==2.17.0 # - python -m pip install cibuildwheel==2.17.0
# # Download repositories # # Download repositories
# - $DEPENDENCY_JOB="build:windows_python" # - $DEPENDENCY_JOB="build:windows_python"
# - !reference [.windows:download:repositories, before_script] # - !reference [.windows:download:repositories, before_script]
before_script: before_script:
# Install Chocolatey # Install Chocolatey
- Set-ExecutionPolicy Bypass -Scope Process -Force - Set-ExecutionPolicy Bypass -Scope Process -Force
- iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1')) - iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
# Install dependencies # Install dependencies
- choco install visualstudio2022buildtools -y - choco install visualstudio2022buildtools -y
- choco install cmake.install --installargs '"ADD_CMAKE_TO_PATH=System"' -Y - choco install cmake.install --installargs '"ADD_CMAKE_TO_PATH=System"' -Y
...@@ -56,33 +56,33 @@ release:pip:windows: ...@@ -56,33 +56,33 @@ release:pip:windows:
# Install NuGet provider # Install NuGet provider
- Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force - Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force
# Set up Visual Studio environment # Set up Visual Studio environment
- Install-Module VSSetup -Scope CurrentUser -Force -ErrorAction SilentlyContinue - Install-Module VSSetup -Scope CurrentUser -Force -ErrorAction SilentlyContinue
- Import-Module VSSetup - Import-Module VSSetup
- $vsInstance = Get-VSSetupInstance | Select-VSSetupInstance - $vsInstance = Get-VSSetupInstance | Select-VSSetupInstance
# Explicit Visual Studio setup # Explicit Visual Studio setup
- $vsPath = "C:\Program Files\Microsoft Visual Studio\2022\BuildTools" - $vsPath = "C:\Program Files\Microsoft Visual Studio\2022\BuildTools"
- $env:VSINSTALLDIR = $vsPath - $env:VSINSTALLDIR = $vsPath
- $env:VCINSTALLDIR = "${vsPath}\VC" - $env:VCINSTALLDIR = "${vsPath}\VC"
# Set CMake generator explicitly # Set CMake generator explicitly
- $env:CMAKE_GENERATOR = "Visual Studio 17 2022" - $env:CMAKE_GENERATOR = "Visual Studio 17 2022"
- $env:CMAKE_PREFIX_PATH = $vsPath - $env:CMAKE_PREFIX_PATH = $vsPath
- $env:WindowsSDKDir = "C:\Program Files (x86)\Windows Kits\10" - $env:WindowsSDKDir = "C:\Program Files (x86)\Windows Kits\10"
- $env:Path = "${vsPath}\Common7\IDE;${vsPath}\Common7\Tools;${env:Path}" - $env:Path = "${vsPath}\Common7\IDE;${vsPath}\Common7\Tools;${env:Path}"
- $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User") - $env:Path = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User")
# Install cibuildwheel # Install cibuildwheel
- py -m pip install cibuildwheel==2.22.0 - py -m pip install cibuildwheel==2.22.0
# Download repositories # Download repositories
- $DEPENDENCY_JOB="build:windows_python" - $DEPENDENCY_JOB="build:windows_python"
- !reference [.windows:download:repositories, before_script] - !reference [.windows:download:repositories, before_script]
script: script:
- $env:CMAKE_GENERATOR = "Visual Studio 17 2022" - $env:CMAKE_GENERATOR = "Visual Studio 17 2022"
- python -m cibuildwheel --output-dir wheelhouse --platform windows - python -m cibuildwheel --output-dir wheelhouse --platform windows
...@@ -90,7 +90,7 @@ release:pip:windows: ...@@ -90,7 +90,7 @@ release:pip:windows:
# deploy:pip:windows: # deploy:pip:windows:
# allow_failure: true # temporary rules until https://gitlab.eclipse.org/eclipse/aidge/aidge/-/issues/136 is closed # allow_failure: true # temporary rules until https://gitlab.eclipse.org/eclipse/aidge/aidge/-/issues/136 is closed
# extends: # extends:
# - .deploy:pip:windows:template # - .deploy:pip:windows:template
# rules: # rules:
# - if: $CI_COMMIT_TAG # Deploy only for tagged commits # - if: $CI_COMMIT_TAG # Deploy only for tagged commits
...@@ -6,12 +6,12 @@ include: ...@@ -6,12 +6,12 @@ include:
build:windows_cpp: build:windows_cpp:
stage: build stage: build
needs: [] needs: []
extends: .build:variable:aidge_install extends: .build:variable:aidge_install
rules: rules:
- allow_failure: false - allow_failure: false
tags: tags:
- windows - windows
image: buildtools #image: buildtools
before_script: before_script:
# Install Chocolatey # Install Chocolatey
...@@ -32,11 +32,11 @@ build:windows_cpp: ...@@ -32,11 +32,11 @@ build:windows_cpp:
Write-Host "Build directory: $env:BUILD_DIR" Write-Host "Build directory: $env:BUILD_DIR"
$SOURCE_PATH = $PWD $SOURCE_PATH = $PWD
$BUILD_PATH = Join-Path $SOURCE_PATH $env:BUILD_DIR $BUILD_PATH = Join-Path $SOURCE_PATH $env:BUILD_DIR
# Create build directory # Create build directory
New-Item -ItemType Directory -Force -Path $BUILD_PATH New-Item -ItemType Directory -Force -Path $BUILD_PATH
Set-Location $BUILD_PATH Set-Location $BUILD_PATH
# Configure with CMake # Configure with CMake
cmake -DCMAKE_BUILD_TYPE=Release ` cmake -DCMAKE_BUILD_TYPE=Release `
-DTESTS=ON ` -DTESTS=ON `
...@@ -63,8 +63,8 @@ test:windows_cpp: ...@@ -63,8 +63,8 @@ test:windows_cpp:
- allow_failure: false - allow_failure: false
tags: tags:
- windows - windows
image: buildtools # image: buildtools
extends: .build:variable:aidge_install extends: .build:variable:aidge_install
before_script: before_script:
# Install Chocolatey # Install Chocolatey
- Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1')) - Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
......
...@@ -11,7 +11,7 @@ build:windows_python: ...@@ -11,7 +11,7 @@ build:windows_python:
needs: [] needs: []
tags: tags:
- windows - windows
image: buildtools # image: buildtools
before_script: before_script:
# Install Chocolatey # Install Chocolatey
...@@ -31,7 +31,7 @@ build:windows_python: ...@@ -31,7 +31,7 @@ build:windows_python:
- virtualenv venv - virtualenv venv
- venv\Scripts\Activate.ps1 - venv\Scripts\Activate.ps1
- python -m pip install . -v - python -m pip install . -v
artifacts: artifacts:
expire_in: 3 days expire_in: 3 days
paths: paths:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment