Skip to content
Snippets Groups Projects
Commit 1e08dc8c authored by Grégoire Kubler's avatar Grégoire Kubler
Browse files

feat : created.ps1 script to run before cibuildwheel when on windows

parent 6abb7f18
No related branches found
No related tags found
2 merge requests!212Version 0.3.0,!116feat/release_pip
Pipeline #45145 canceled
param(
[String[]]$DEPS= @()
)
if ($deps.Length -eq 0) {
Write-Host "- No dependencies provided for current repository"
New-Item -ItemType Directory -Force -Path ".\build" | Out-Null
Remove-Item -Path ".\build\*" -Recurse -Force
} else {
foreach ($repo in $DEPS) {
$repoPath = Get-ChildItem -Path "/host/home/" -Directory -Filter $repo -Recurse |
Where-Object { $_.FullName -notmatch 'install' -and
$_.FullName -notmatch '.git' -and
$_.FullName -notmatch 'miniconda' -and
$_.FullName -notmatch 'conda' -and
$_.FullName -notmatch '.local' -and
$_.FullName -notmatch 'lib' -and
$_.FullName -notmatch "\\$repo\\$repo" } |
Select-Object -First 1 -ExpandProperty FullName
if (-not [string]::IsNullOrEmpty($repoPath)) {
Set-Location $repoPath
New-Item -Path ".\build" -ItemType Directory -Force | Out-Null
Get-ChildItem -Path ".\build" -File | Remove-Item -Force
pip install . -Verbose
}
}
}
......@@ -10,6 +10,7 @@ else
-not -path '*install*' \
-not -path '*.git*' \
-not -path '*miniconda*' \
-not -path '*conda*' \
-not -path '*.local*' \
-not -path "*lib*" \
-not -path "*/$repo/$repo" \
......
......@@ -19,10 +19,13 @@ build-backend = "setuptools.build_meta"
# CIBUILDWHEEL
[tool.cibuildwheel]
build-frontend = "build"
before-build = ["bash .gitlab/ci/cibuildwheel_build_deps_before_build_wheel.sh ${AIDGE_DEPENDENCIES}"]
[tool.cibuildwheel.environment]
# aidge_core do not rely on any aidge dependency, hence this string is empty
AIDGE_DEPENDENCIES = "" # format => "dep_1 dep_2 ... dep_n"
[tool.cibuildwheel.linux]
before-build = ["bash .gitlab/ci/cibuildwheel_build_deps_before_build_wheel.sh ${AIDGE_DEPENDENCIES}"]
[tool.cibuildwheel.windows]
before-build = ["./.gitlab/ci/cibuildwheel_build_deps_before_build_wheel.ps1 --deps ${AIDGE_DEPENDENCIES}"]
#####################################################
# SETUPTOOLS
......
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