diff --git a/.github/workflows/build_wheels.yaml b/.github/workflows/build_wheels.yaml index 714bd30..32a7f62 100644 --- a/.github/workflows/build_wheels.yaml +++ b/.github/workflows/build_wheels.yaml @@ -35,56 +35,7 @@ jobs: with: path: dist/*.tar.gz - build_wheels_windows: - name: "${{ matrix.os }} ${{ matrix.cibw_archs }} ${{ matrix.cibw_build }}" - runs-on: ${{ matrix.os }} - strategy: - fail-fast: false - matrix: - os: [windows-latest] - cibw_build: ["cp38-*", "cp39-*", "cp310-*", "cp311-*", "cp312-*"] - cibw_archs: ["AMD64", "x86", "ARM64"] - exclude: - - os: windows-latest - cibw_build: "cp38-*" - cibw_archs: "ARM64" - - steps: - - name: "Set environment variables (Windows)" - shell: pwsh - run: | - (Get-ItemProperty "HKLM:System\CurrentControlSet\Control\FileSystem").LongPathsEnabled - - - name: Check out repository - uses: actions/checkout@v3 - with: - fetch-depth: 0 - submodules: "recursive" - - - name: Install ZLIB - shell: pwsh - run: | - scripts/install_zlib.ps1 - - - name: Set up python 3.12 - uses: actions/setup-python@v4 - with: - python-version: "3.12" - - - name: Build wheels - uses: pypa/cibuildwheel@v2.16.5 - env: - CIBW_ARCHS: ${{ matrix.cibw_archs }} - CIBW_BUILD: ${{ matrix.cibw_build }} - CIBW_BEFORE_ALL: mkdir openexr\build && cd openexr\build && cmake .. -DCMAKE_INSTALL_PREFIX=..\..\openexr-install && make && make install - CIBW_ENVIRONMENT: LD_LIBRARY_PATH=${GITHUB_WORKSPACE}/openexr-install/lib64:${GITHUB_WORKSPACE}/openexr-install/lib - - - uses: actions/upload-artifact@v3 - with: - path: wheelhouse/*.whl - build_wheels_linux: - if: false # TODO: uncomment name: "${{ matrix.os }} ${{ matrix.cibw_archs }} ${{ matrix.cibw_build }}" runs-on: ${{ matrix.os }} strategy: @@ -125,7 +76,6 @@ jobs: path: wheelhouse/*.whl build_wheels_macos: - if: false # TODO: uncomment name: "${{ matrix.os }} ${{ matrix.cibw_archs }} ${{ matrix.cibw_build }}" runs-on: ${{ matrix.os }} strategy: @@ -236,7 +186,6 @@ jobs: needs: [ "build_sdist", - "build_wheels_windows", "build_wheels_linux", "build_wheels_macos", "build_wheels_macos_arm64", @@ -245,6 +194,14 @@ jobs: steps: - uses: actions/download-artifact@v3 + - name: Set up python 3.12 + uses: actions/setup-python@v4 + with: + python-version: "3.12" + + - name: Install Twine + run: pip install twine + - name: Authenticate to Google Cloud id: auth uses: "google-github-actions/auth@v1" @@ -253,9 +210,8 @@ jobs: - name: Upload to Artifact Registry run: | - # TODO: figure this out later with Rich gcloud config set artifacts/repository OpenEXR - # gcloud config set artifacts/location + gcloud config set artifacts/location us-west1 gcloud auth activate-service-account --key-file=$GOOGLE_GHA_CREDS_PATH gcloud artifacts print-settings python > ~/.pypirc python -m twine upload --repository OpenEXR artifact/* diff --git a/.gitignore b/.gitignore index f76b8f7..c5cee13 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ wheelhouse/ dist/ MANIFEST /*.whl +*.DS_Store diff --git a/scripts/install_zlib.ps1 b/scripts/install_zlib.ps1 deleted file mode 100644 index 687c6c9..0000000 --- a/scripts/install_zlib.ps1 +++ /dev/null @@ -1,41 +0,0 @@ -$homeDir = (pwd) - -$zlibArchive = "https://www.zlib.net/current/zlib.tar.gz" - -$zlibRoot = "C:\" -$zlibBuildPath = "${zlibRoot}\zlib-current" -$zlibInstallPath = "C:\_zlib" -$msbuild = "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Current\Bin\msbuild.exe" - -Write-Host "Retrieving ${zlibArchive}" -Invoke-WebRequest "${zlibArchive}" -OutFile "${zlibRoot}\zlib.tar.gz" -Write-Host "Expanding archive ${zlibRoot}\zlib.tar.gz" -tar -xzf "${zlibRoot}\zlib.tar.gz" -C "${zlibRoot}" - -cd $zlibBuildPath -mkdir _build -cd _build -cmake .. -G"Visual Studio 16 2019" -DCMAKE_INSTALL_PREFIX="${zlibInstallPath}" - -Write-Host "Building ${zlibBuildPath}\_build\INSTALL.vcxproj" -foregroundcolor green -& "${msbuild}" "${zlibBuildPath}\_build\INSTALL.vcxproj" /P:Configuration=Release - -cd $zlibInstallPath -Write-Host "ls ${zlibInstallPath}" -& ls - -Write-Host "ls bin" -& ls bin -Write-Host "ls include" -& ls include -Write-Host "ls lib" -& ls lib -Write-Host "ls share" -& ls share - -cd $homeDir - -Write-Host "##vso[task.prependpath]${zlibInstallPath}" -Write-Host "##vso[task.prependpath]${zlibInstallPath}\bin" -Write-Host "##vso[task.prependpath]${zlibInstallPath}\include" -Write-Host "##vso[task.prependpath]${zlibInstallPath}\lib"