diff options
author | John W. Parent <45471568+johnwparent@users.noreply.github.com> | 2024-09-06 08:26:46 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-06 14:26:46 +0200 |
commit | 4042afaa99426d8ed35643e531b69a8012fbd3f2 (patch) | |
tree | 5ff5555897e77f6538a192ee623595b54bbccc90 /.github | |
parent | 7fdf1029b747555f1d3040075bfeaf322ee6837e (diff) | |
download | spack-4042afaa99426d8ed35643e531b69a8012fbd3f2.tar.gz spack-4042afaa99426d8ed35643e531b69a8012fbd3f2.tar.bz2 spack-4042afaa99426d8ed35643e531b69a8012fbd3f2.tar.xz spack-4042afaa99426d8ed35643e531b69a8012fbd3f2.zip |
Bootstrap GnuPG and `file` on Windows (#41810)
Spack can now bootstrap two new dependencies on Windows: GnuPG, and file.
These dependencies are modeled as a separate package, and they install a cross-compiled binary.
Details on how they binaries are built are in https://github.com/spack/windows-bootstrap-resources
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/bootstrap.yml | 41 |
1 files changed, 36 insertions, 5 deletions
diff --git a/.github/workflows/bootstrap.yml b/.github/workflows/bootstrap.yml index 8e220b12bf..613dc2ba50 100644 --- a/.github/workflows/bootstrap.yml +++ b/.github/workflows/bootstrap.yml @@ -112,10 +112,10 @@ jobs: runs-on: ${{ matrix.runner }} strategy: matrix: - runner: ['macos-13', 'macos-14', "ubuntu-latest"] + runner: ['macos-13', 'macos-14', "ubuntu-latest", "windows-latest"] steps: - name: Setup macOS - if: ${{ matrix.runner != 'ubuntu-latest' }} + if: ${{ matrix.runner != 'ubuntu-latest' && matrix.runner != 'windows-latest'}} run: | brew install tree # Remove GnuPG since we want to bootstrap it @@ -124,6 +124,11 @@ jobs: if: ${{ matrix.runner == 'ubuntu-latest' }} run: | sudo rm -rf $(which gpg) $(which gpg2) $(which patchelf) + - name: Setup Windows + if: ${{ matrix.runner == 'windows-latest' }} + run: | + Remove-Item -Path (Get-Command gpg).Path + Remove-Item -Path (Get-Command file).Path - name: Checkout uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 with: @@ -137,11 +142,20 @@ jobs: 3.11 3.12 - name: Set bootstrap sources + env: + SETUP_SCRIPT_EXT: ${{ matrix.runner == 'windows-latest' && 'ps1' || 'sh' }} + SETUP_SCRIPT_SOURCE: ${{ matrix.runner == 'windows-latest' && './' || 'source ' }} run: | - source share/spack/setup-env.sh + ${{ env.SETUP_SCRIPT_SOURCE }}share/spack/setup-env.${{ env.SETUP_SCRIPT_EXT }} spack bootstrap disable github-actions-v0.4 + - name: Disable from source bootstrap + if: ${{ matrix.runner != 'windows-latest' }} + run: | + source share/spack/setup-env.sh spack bootstrap disable spack-install - name: Bootstrap clingo + # No binary clingo on Windows yet + if: ${{ matrix.runner != 'windows-latest' }} run: | set -e for ver in '3.8' '3.9' '3.10' '3.11' '3.12' ; do @@ -164,7 +178,24 @@ jobs: fi done - name: Bootstrap GnuPG + env: + SETUP_SCRIPT_EXT: ${{ matrix.runner == 'windows-latest' && 'ps1' || 'sh' }} + SETUP_SCRIPT_SOURCE: ${{ matrix.runner == 'windows-latest' && './' || 'source ' }} + USER_SCOPE_PARENT_DIR: ${{ matrix.runner == 'windows-latest' && '$env:userprofile' || '$HOME' }} + VALIDATE_LAST_EXIT: ${{ matrix.runner == 'windows-latest' && './share/spack/qa/validate_last_exit.ps1' || '' }} run: | - source share/spack/setup-env.sh + ${{ env.SETUP_SCRIPT_SOURCE }}share/spack/setup-env.${{ env.SETUP_SCRIPT_EXT }} spack -d gpg list - tree ~/.spack/bootstrap/store/ + ${{ env.VALIDATE_LAST_EXIT }} + tree ${{ env.USER_SCOPE_PARENT_DIR }}/.spack/bootstrap/store/ + - name: Bootstrap File + env: + SETUP_SCRIPT_EXT: ${{ matrix.runner == 'windows-latest' && 'ps1' || 'sh' }} + SETUP_SCRIPT_SOURCE: ${{ matrix.runner == 'windows-latest' && './' || 'source ' }} + USER_SCOPE_PARENT_DIR: ${{ matrix.runner == 'windows-latest' && '$env:userprofile' || '$HOME' }} + VALIDATE_LAST_EXIT: ${{ matrix.runner == 'windows-latest' && './share/spack/qa/validate_last_exit.ps1' || '' }} + run: | + ${{ env.SETUP_SCRIPT_SOURCE }}share/spack/setup-env.${{ env.SETUP_SCRIPT_EXT }} + spack -d python share/spack/qa/bootstrap-file.py + ${{ env.VALIDATE_LAST_EXIT }} + tree ${{ env.USER_SCOPE_PARENT_DIR }}/.spack/bootstrap/store/ |