Skip to content

Commit 30c3b37

Browse files
authored
Refactor publish2.yml for improved build environment setup
Refactor CIBW_ENVIRONMENT and CIBW_BEFORE_BUILD for better readability and add additional pip install commands.
1 parent fbc21f6 commit 30c3b37

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

.github/workflows/publish2.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,12 +167,20 @@ jobs:
167167
continue-on-error: true
168168
uses: pypa/cibuildwheel@v2.23.0
169169
env:
170-
CIBW_ENVIRONMENT: "OMNIPKG_SKIP_C_EXT=0"
171170
CIBW_BEFORE_BUILD: "pip install 'packaging>=23.0'"
171+
CIBW_ENVIRONMENT: >
172+
OMNIPKG_SKIP_C_EXT=0
173+
PIP_EXTRA_INDEX_URL=""
174+
CIBW_BEFORE_BUILD: >
175+
pip install --upgrade pip 'packaging>=23.0' 'wheel>=0.43.0' &&
176+
python -c "import locale; locale.getencoding = lambda: 'UTF-8'" 2>/dev/null || true
177+
pip install --upgrade 'packaging>=23.0' pip &&
178+
pip install --upgrade 'packaging>=23.0' --target /tmp/pip-build-env-*/overlay/ 2>/dev/null || true
172179
CIBW_BUILD: "${{ matrix.py_tag }}-*"
173180
CIBW_ARCHS: "${{ matrix.cibw_archs }}"
174181
CIBW_SKIP: "pp*"
175182
CIBW_ENABLE: "${{ steps.cibw_flags.outputs.enable }}"
183+
CIBW_BUILD_FRONTEND: "pip; args: --no-build-isolation"
176184
CIBW_TEST_COMMAND: "omnipkg --version"
177185
# Skip test on i686/x86 — cryptography dep has no prebuilt i386 wheels
178186
# and building from source requires Rust which isn't in the test venv

0 commit comments

Comments
 (0)