@@ -279,103 +279,3 @@ jobs:
279279 fi
280280
281281 build/pythonbuild validate-distribution ${EXTRA_ARGS} dist/*.tar.zst
282-
283- build-1 :
284- needs :
285- - generate-matrix
286- - crate-build
287- - image
288- # Permissions used for actions/attest-build-provenance
289- permissions :
290- id-token : write
291- attestations : write
292- runs-on : ${{ matrix.runner }}
293- strategy :
294- matrix : ${{ fromJson(needs.generate-matrix.outputs.python-build-matrix-1) }}
295- fail-fast : false
296- name : ${{ matrix.target_triple }} / ${{ matrix.python }} / ${{ matrix.build_options }}
297- steps :
298- - uses : actions/checkout@v4
299- with :
300- fetch-depth : 0
301-
302- - name : Install Python
303- uses : actions/setup-python@v5
304- with :
305- python-version : ' 3.11'
306-
307- - name : Download pythonbuild
308- uses : actions/download-artifact@v4
309- with :
310- name : ${{ matrix.crate_artifact_name }}
311- path : build
312-
313- - name : Download images
314- uses : actions/download-artifact@v4
315- with :
316- pattern : image-*
317- path : build
318- merge-multiple : true
319-
320- - name : Cache downloads
321- uses : actions/cache@v4
322- with :
323- path : build/downloads
324- key : ${{ matrix.target_triple }}-${{ hashFiles('pythonbuild/downloads.py')}}
325- restore-keys : |
326- ${{ matrix.target_triple }}-${{ hashFiles('pythonbuild/downloads.py')}}
327- ${{ matrix.target_triple }}-
328-
329- - name : Load Docker Images
330- run : |
331- for f in build/image-*.tar.zst; do
332- echo "decompressing $f"
333- zstd -d --rm ${f}
334- done
335-
336- for f in build/image-*.tar; do
337- echo "loading $f"
338- docker load --input $f
339- done
340-
341- - name : Build
342- if : ${{ ! matrix.dry-run }}
343- run : |
344- # Do empty target so all generated files are touched.
345- ./build-linux.py --make-target empty
346-
347- # Touch mtimes of all images so they are newer than autogenerated files above.
348- touch build/image-*
349-
350- ./build-linux.py --target-triple ${{ matrix.target_triple }} --python cpython-${{ matrix.python }} --options ${{ matrix.build_options }}
351-
352- - name : Generate attestations
353- uses : actions/attest-build-provenance@v2
354- if : ${{ github.ref == 'refs/heads/main' }}
355- with :
356- subject-path : dist/*
357-
358- - name : Upload Distribution
359- if : ${{ ! matrix.dry-run }}
360- uses : actions/upload-artifact@v4
361- with :
362- name : cpython-${{ matrix.python }}-${{ matrix.target_triple }}-${{ matrix.build_options }}
363- path : dist/*
364-
365- - name : Validate Distribution
366- if : ${{ ! matrix.dry-run }}
367- run : |
368- chmod +x build/pythonbuild
369-
370- if [ "${{ matrix.run }}" == "true" ]; then
371- if [ "${{ matrix.libc }}" == "musl" ]; then
372- sudo apt install musl-dev
373-
374- # GitHub's setup-python action sets `LD_LIBRARY_PATH` which overrides `RPATH`
375- # as used in the musl builds.
376- unset LD_LIBRARY_PATH
377- fi
378- EXTRA_ARGS="--run"
379- fi
380-
381- build/pythonbuild validate-distribution ${EXTRA_ARGS} dist/*.tar.zst
0 commit comments