From 97019b34c729c9973988be94cb73eff2f5452bc9 Mon Sep 17 00:00:00 2001 From: lpossner Date: Tue, 16 Jul 2024 23:10:42 +0200 Subject: [PATCH] [MOD] - updated osx runner to osx-14 --- .github/workflows/main.yml | 2 +- setup.py | 88 ++++++++++++++++++++++---------------- 2 files changed, 52 insertions(+), 38 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 0d89e8b..64b254b 100755 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -99,7 +99,7 @@ jobs: TWINE_PASSWORD: ${{ secrets.twine_api_key }} TWINE_USERNAME: __token__ macos: - runs-on: macos-11 + runs-on: macos-14 strategy: matrix: python-version: ["3.9", "3.10", "3.11", "3.12"] diff --git a/setup.py b/setup.py index f10637a..e0325da 100755 --- a/setup.py +++ b/setup.py @@ -25,43 +25,57 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see -openmp_compile_args = ['-fopenmp'] -openmp_link_args = ['-lgomp'] -pygpc_extensions_src_file_path = [os.path.join('pckg', 'pygpc_extensions', - 'src', 'pygpc_extensions.cpp')] -pygpc_extensions_include_path = [os.path.join('pckg', 'pygpc_extensions', - 'include'), np.get_include()] +openmp_compile_args = ["-fopenmp"] +openmp_link_args = ["-lgomp"] +pygpc_extensions_src_file_path = [ + os.path.join("pckg", "pygpc_extensions", "src", "pygpc_extensions.cpp") +] +pygpc_extensions_include_path = [ + os.path.join("pckg", "pygpc_extensions", "include"), + np.get_include(), +] -if sys.platform == 'darwin': - extensions = [] -else: - extensions = [Extension('pygpc.pygpc_extensions', - sources=pygpc_extensions_src_file_path, - include_dirs=pygpc_extensions_include_path, - extra_compile_args=openmp_compile_args, - extra_link_args=openmp_link_args)] +# if sys.platform == 'darwin': +# extensions = [] +# else: +# extensions = [Extension('pygpc.pygpc_extensions', +# sources=pygpc_extensions_src_file_path, +# include_dirs=pygpc_extensions_include_path, +# extra_compile_args=openmp_compile_args, +# extra_link_args=openmp_link_args)] -setup(name='pygpc', - version='0.3.9', - description='A sensitivity and uncertainty analysis toolbox for Python', - author='Konstantin Weise', - author_email='kweise@cbs.mpg.de', - license='GPL3', - packages=find_packages(exclude=['tests', - 'tests.*', - 'templates', - 'templates.*']), - install_requires=['scipy', - 'numpy', - 'scikit-learn', - 'h5py', - 'tqdm', - 'pandas', - ], - ext_modules=extensions, - package_data={'pygpc': ['*.so', '*.dll', '*.dylib']}, - project_urls={ +extensions = [ + Extension( + "pygpc.pygpc_extensions", + sources=pygpc_extensions_src_file_path, + include_dirs=pygpc_extensions_include_path, + extra_compile_args=openmp_compile_args, + extra_link_args=openmp_link_args, + ) +] + +setup( + name="pygpc", + version="0.3.9", + description="A sensitivity and uncertainty analysis toolbox for Python", + author="Konstantin Weise", + author_email="kweise@cbs.mpg.de", + license="GPL3", + packages=find_packages(exclude=["tests", "tests.*", "templates", "templates.*"]), + install_requires=[ + "scipy", + "numpy", + "scikit-learn", + "h5py", + "tqdm", + "pandas", + ], + ext_modules=extensions, + package_data={"pygpc": ["*.so", "*.dll", "*.dylib"]}, + project_urls={ "Documentation": "https://pygpc.readthedocs.io/en/latest/", - "Source Code": "https://github.com/pygpc-polynomial-chaos/pygpc"}, - zip_safe=False, - include_package_data=True) \ No newline at end of file + "Source Code": "https://github.com/pygpc-polynomial-chaos/pygpc", + }, + zip_safe=False, + include_package_data=True, +)