Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 10 additions & 7 deletions src/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -148,13 +148,16 @@ if not m4rie.found()
# For some reason, m4rie is not found via pkg-config on some systems (eg Conda)
m4rie = cc.find_library('m4rie', required: not is_windows, disabler: true)
endif
# Cannot be found via pkg-config
mtx = cc.find_library(
'mtx',
required: get_option('meataxe'),
disabler: true,
has_headers: ['meataxe.h'],
)
mtx = dependency('mtx', required: false)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The dependency name is wrong here, it should be 'libmtx'

if not mtx.found()
# fallback for older versions without pkg-config
mtx = cc.find_library(
'mtx',
required: get_option('meataxe'),
disabler: true,
has_headers: ['meataxe.h'],
)
endif
png = dependency(['libpng', 'png', 'png16'], version: '>=1.2')
zlib = dependency('zlib', version: '>=1.2.11')
ec = dependency(
Expand Down
22 changes: 15 additions & 7 deletions src/sage/graphs/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,22 @@ if cc.has_header('mcqd.h', required: get_option('mcqd'))
# mcqd is a header-only library
mcqd = declare_dependency()
endif
cliquer = cc.find_library('cliquer', required: not is_windows, disabler: true)

# Cannot be found via pkg-config
planarity = cc.find_library(
'planarity',
required: not is_windows,
disabler: true,
)
cliquer = dependency('libcliquer', required: false, disabler: true)
if not cliquer.found()
# fallback for older versions without pkg-config
cliquer = cc.find_library('cliquer', required: not is_windows, disabler: true)
endif

planarity = dependency('libplanarity', required: false, disabler: true)
if not planarity.found()
# fallback for older versions without pkg-config
planarity = cc.find_library(
'planarity',
required: not is_windows,
disabler: true,
)
endif

py.install_sources(
'__init__.py',
Expand Down
30 changes: 19 additions & 11 deletions src/sage/libs/meson.build
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
sirocco = cc.find_library(
'sirocco',
required: get_option('sirocco'),
disabler: true,
)
sirocco = dependency('libsirocco', required: false, disabler: true)
if not sirocco.found()
# fallback for older versions without pkg-config
sirocco = cc.find_library(
'sirocco',
required: get_option('sirocco'),
disabler: true,
)
endif
# cannot be found via pkg-config
ecl = cc.find_library('ecl', required: false, disabler: true)
if not ecl.found() and not is_windows
Expand Down Expand Up @@ -81,12 +85,16 @@ gc = dependency(
required: not is_windows,
disabler: true,
)
homfly = cc.find_library(
'homfly',
has_headers: ['homfly.h'],
required: false,
disabler: true,
)
homfly = dependency('libhomfly', required: false, disabler: true)
if not homfly.found()
# fallback for older versions without pkg-config
homfly = cc.find_library(
'homfly',
has_headers: ['homfly.h'],
required: false,
disabler: true,
)
endif

py.install_sources(
'__init__.py',
Expand Down
15 changes: 9 additions & 6 deletions src/sage/libs/symmetrica/meson.build
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Cannot be found by pkg-config
symmetrica = cc.find_library(
'symmetrica',
required: not is_windows,
disabler: true,
)
symmetrica = dependency('symmetrica', required: false, disabler: true)
if not symmetrica.found()
# fallback for older versions without pkg-config
symmetrica = cc.find_library(
'symmetrica',
required: not is_windows,
disabler: true,
)
endif

py.install_sources('__init__.py', 'all.py', subdir: 'sage/libs/symmetrica')

Expand Down
6 changes: 5 additions & 1 deletion src/sage/rings/polynomial/pbori/meson.build
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
brial = cc.find_library('brial', required: get_option('brial'), disabler: true)
brial = dependency('brial', required: false, disabler: true)
if not brial.found()
# fallback for older versions without pkg-config
brial = cc.find_library('brial', required: get_option('brial'), disabler: true)
endif
# Cannot be found via pkg-config
brial_groebner = cc.find_library(
'brial_groebner',
Expand Down
Loading