Skip to content

Commit

Permalink
[pypi] wheel path fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
fradav committed Jun 11, 2024
1 parent 2de2c9f commit d1996d5
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 11 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,11 @@ jobs:
shortos: linux
cmakeargs: "-DTEST:BOOL=FALSE -DUSE_MKL:BOOL=TRUE -DMAKE_STATIC_EXE:BOOL=TRUE -DLAPACK_ROOT:STRING=/opt/intel/oneapi/mkl/latest/lib '-DLAPACK_LIBRARIES:STRING=-Wl,--start-group /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_intel_lp64.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_tbb_thread.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_core.a -Wl,--end-group;pthread;m;dl' '-DBLAS_LIBRARIES:STRING=-Wl,--start-group /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_intel_lp64.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_tbb_thread.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_core.a -Wl,--end-group;pthread;m;dl' -DCMAKE_BUILD_TYPE:STRING=Release -G Ninja"
- os: macos-latest
shortos: macos
cmakeargs: -DTEST:BOOL=FALSE -DCMAKE_OSX_ARCHITECTURES:STRING=arm64 -DUSE_MKL:BOOL=FALSE -DCMAKE_BUILD_TYPE:STRING=Release -G Ninja
shortos: macos-x64
cmakeargs: -DTEST:BOOL=FALSE -DCMAKE_OSX_ARCHITECTURES:STRING=x86_64 -DVCPKG_TARGET_TRIPLET:STRING=x64-osx -DUSE_MKL:BOOL=FALSE -DCMAKE_BUILD_TYPE:STRING=Release -G Ninja
- os: macos-latest
shortos: macos-arm64
cmakeargs: -DTEST:BOOL=FALSE -DCMAKE_OSX_ARCHITECTURES:STRING=arm64 -DVCPKG_TARGET_TRIPLET:STRING=arm64-osx -DUSE_MKL:BOOL=FALSE -DCMAKE_BUILD_TYPE:STRING=Release -G Ninja
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -79,7 +82,7 @@ jobs:
uses: actions/cache@v2
with:
path: /Users/runner/.local/share/pmm
key: macos-vcpkg5-${{ env.PMM_VERSION }}-${{ env.VCPKG_REVISION }}
key: macos-vcpkg5-${{ matrix.shortos }}-${{ env.PMM_VERSION }}-${{ env.VCPKG_REVISION }}
if: matrix.os == 'macos-latest'
- name: restore/cache vcpkg/windows
uses: actions/cache@v2
Expand Down Expand Up @@ -187,7 +190,7 @@ jobs:
asset_content_type: application/octet-stream
if: matrix.os == 'windows-latest'
- name: Build wheels
uses: pypa/cibuildwheel@v2.18.1
uses: pypa/cibuildwheel@v2.19.0
- uses: actions/upload-artifact@v2
with:
path: ./wheelhouse/*.whl
Expand Down
5 changes: 0 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,6 @@ if(MSVC AND MAKE_STATIC_EXE)
set(VCPKG_TARGET_TRIPLET "x64-windows-static")
endif()

if(APPLE)
set(VCPKG_TARGET_TRIPLET "arm64-osx")
set(VCPKG_OSX_ARCHITECTURES "arm64")
endif()

if(USE_MKL)
set(TBBPKG tbb)
endif()
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ build-verbosity = 3

[tool.cibuildwheel.linux]
before-all = "bash presetup.sh"
environment-pass = [ "VCPKG_REVISION" ]
environment-pass = ["VCPKG_REVISION"]
before-build = "rm -f {project}/build/CMakeCache.txt"

[tool.cibuildwheel.macos]
Expand Down
6 changes: 5 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from cmaketools import setup
import sys
import platform
from os import path

this_directory = path.abspath(path.dirname(__file__))
Expand All @@ -14,7 +15,10 @@
elif sys.platform == "linux":
configure_opts = ["-DPython_EXECUTABLE="+sys.executable,"-DPYABCRANGER=TRUE","-DUSE_MKL:BOOL=TRUE","-DMAKE_STATIC_EXE:BOOL=TRUE","-DLAPACK_ROOT:STRING=/opt/intel/oneapi/mkl/latest/lib","-DLAPACK_LIBRARIES:STRING=-Wl,--start-group /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_intel_lp64.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_tbb_thread.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_core.a -Wl,--end-group;pthread;m;dl","-DBLAS_LIBRARIES:STRING=-Wl,--start-group /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_intel_lp64.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_tbb_thread.a /opt/intel/oneapi/mkl/latest/lib/intel64/libmkl_core.a -Wl,--end-group;pthread;m;dl"]
elif sys.platform == "darwin":
configure_opts = ["-DPython_EXECUTABLE="+sys.executable,"-DCMAKE_OSX_ARCHITECTURES:STRING=arm64","-DPYABCRANGER=TRUE","-DUSE_MKL:BOOL=FALSE","-DCMAKE_BUILD_TYPE:STRING=Release"]
if platform.processor == "arm":
configure_opts = ["-DPython_EXECUTABLE="+sys.executable,"-DVCPKG_TRIPLET:STRING=arm64-osx","-DCMAKE_OSX_ARCHITECTURES:STRING=arm64","-DPYABCRANGER=TRUE","-DUSE_MKL:BOOL=FALSE","-DCMAKE_BUILD_TYPE:STRING=Release"]
else:
configure_opts = ["-DPython_EXECUTABLE="+sys.executable,"-DVCPKG_TRIPLET:STRING=x64-osx","-DCMAKE_OSX_ARCHITECTURES:STRING=x64","-DPYABCRANGER=TRUE","-DUSE_MKL:BOOL=FALSE","-DCMAKE_BUILD_TYPE:STRING=Release"]
elif sys.platform == "win32":
configure_opts = ["-DPython_FIND_REGISTRY=NEVER","-DPYABCRANGER=TRUE","-DUSE_MKL:BOOL=FALSE","-DMAKE_STATIC_EXE:BOOL=TRUE","-DVCPKG_TARGET_TRIPLET:STRING=x64-windows-static"]
else:
Expand Down

0 comments on commit d1996d5

Please sign in to comment.