Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
/naevPublic

Commit296df9d

Browse files
meson.build: Use dependency with fallbacks for libdl detection
1 parent590500e commit296df9d

File tree

1 file changed

+10
-13
lines changed

1 file changed

+10
-13
lines changed

‎meson.build‎

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -219,20 +219,17 @@ int main (void) { return 0; }''')
219219

220220
naev_deps+= blas
221221

222-
### Soft deps (required: false)
223-
224-
# libdl can be used for debugging stack traces. On non-Windows platforms, GLAD relies on dlopen().
225-
glad_requires_libdl=not cc.has_header('windows.h')
226-
if glad_requires_libdlor debug
227-
# TODO maybe use dependency('dl') instead of find_library. Requires meson 0.62, however.
228-
# ref: https://mesonbuild.com/Dependencies.html#dl-libdl
229-
libdl= cc.find_library('dl',required:false )
230-
if libdl.found()
231-
naev_deps+= libdl
232-
elifhost_machine.system()=='windows'
233-
naev_deps+=subproject('dlfcn-win32').get_variable('dl_dep')
234-
endif
222+
# libdl can be used for debugging stack traces.
223+
ifhost_machine.system()=='windows'
224+
# On non-Windows platforms, GLAD relies on dlopen().
225+
# Windows doesn't have dlopen, but we can use dlfcn-win32 instead.
226+
libdl=dependency('dl',fallback: ['dlfcn-win32','dl_dep'],required:true)
227+
else
228+
libdl=dependency('dl',required:true)
235229
endif
230+
naev_deps+= libdl
231+
232+
### Soft deps (required: false)
236233

237234
ifget_option('debug')
238235
libbacktrace= cc.find_library('backtrace',has_headers:'backtrace.h',required:false)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp