Skip to content

Commit

Permalink
Try passing env variable directly without setting it
Browse files Browse the repository at this point in the history
  • Loading branch information
juliannguyen4 committed Feb 20, 2024
1 parent b79d8fe commit 7ab793a
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions .github/workflows/build-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -172,16 +172,12 @@ jobs:

- name: Build without optimizations
if: ${{ inputs.build-for-debugging }}
run: echo "CIBW_ENVIRONMENT_PASS_LINUX_VARS=UNOPTIMIZED=1" >> $GITHUB_ENV

- name: Build with optimizations (e.g for production)
if: ${{ !inputs.build-for-debugging }}
run: echo "CIBW_ENVIRONMENT_PASS_LINUX_VARS=''" >> $GITHUB_ENV
run: echo "UNOPTIMIZED=1" >> $GITHUB_ENV

- name: Build wheel
uses: pypa/cibuildwheel@v2.15.0
env:
CIBW_ENVIRONMENT_PASS_LINUX: ${{ env.CIBW_ENVIRONMENT_PASS_LINUX_VARS }}
CIBW_ENVIRONMENT_PASS_LINUX: ${{ inputs.build-for-debugging && 'UNOPTIMIZED' || '' }}
CIBW_BUILD: ${{ matrix.python }}-manylinux_${{ matrix.platform }}
CIBW_BUILD_FRONTEND: build
CIBW_BEFORE_ALL_LINUX: >
Expand Down

0 comments on commit 7ab793a

Please sign in to comment.