Skip to content

Commit e8e0af9

Browse files
committed
Fix build on Windows
* drop dependency search for OpenMP (unnecessary) and drop libomp-dev from standard clang builds * use CMake to find MKL
1 parent 9bb4065 commit e8e0af9

2 files changed

Lines changed: 10 additions & 29 deletions

File tree

.github/workflows/build-with-standard-clang.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ jobs:
3333
run: |
3434
sudo apt-get update
3535
sudo apt-get install -y clang
36-
sudo apt-get install -y libomp-dev
3736
3837
- name: Setup Python
3938
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0

meson.build

Lines changed: 10 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -72,34 +72,16 @@ else
7272
error('Unsupported system.')
7373
endif
7474

75-
# dependencies
76-
omp_dep = dependency('openmp', required: true)
77-
78-
# manually waterfall the meson deps: pkg-config to cmake to find_library
79-
mkl_dep = dependency('mkl-dynamic-lp64-iomp', required: false)
80-
81-
if not mkl_dep.found()
82-
mkl_dep = dependency('MKL', method: 'cmake',
83-
modules: ['MKL::MKL'],
84-
cmake_args: [
85-
'-DMKL_ARCH=intel64',
86-
'-DMKL_LINK=dynamic',
87-
'-DMKL_THREADING=intel_thread',
88-
'-DMKL_INTERFACE=lp64'
89-
],
90-
required: false
91-
)
92-
endif
93-
94-
if not mkl_dep.found()
95-
# use static: false to emulate -DMKL_LINK=dynamic
96-
# static: false docs are wrong, this will only consider shared libs
97-
# see: https://github.com/mesonbuild/meson/issues/14163
98-
mkl_core = cc.find_library('mkl_core', required: true, static: false)
99-
mkl_intel_lp64 = cc.find_library('mkl_intel_lp64', required: true, static: false)
100-
mkl_intel_thread = cc.find_library('mkl_intel_thread', required: true, static: false)
101-
mkl_dep = declare_dependency(dependencies: [mkl_core, mkl_intel_lp64, mkl_intel_thread])
102-
endif
75+
mkl_dep = dependency('MKL', method: 'cmake',
76+
modules: ['MKL::MKL'],
77+
cmake_args: [
78+
'-DMKL_ARCH=intel64',
79+
'-DMKL_LINK=dynamic',
80+
'-DMKL_THREADING=intel_thread',
81+
'-DMKL_INTERFACE=lp64'
82+
],
83+
required: false
84+
)
10385

10486
# generate loops, similar to numpy
10587
src_file_cli = find_program('_vendored/process_src_template.py')

0 commit comments

Comments
 (0)