summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorEric Engestrom <eric.engestrom@intel.com>2019-10-29 21:42:16 +0000
committerEric Engestrom <eric.engestrom@intel.com>2019-11-05 20:31:37 +0000
commit4d5cde1fffc4f1c61a58164a619466371948b704 (patch)
treeaeae10b202915a6a530ee929cae4c1ecf683f53e /meson.build
parent2f652e0b3691e94d6a81e37985741d35561b2312 (diff)
meson: add windows support to symbols checks
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com> Reviwed-by: Dylan Baker <dylan@pnwbakers>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build12
1 files changed, 9 insertions, 3 deletions
diff --git a/meson.build b/meson.build
index 020f725116f..796b628e5eb 100644
--- a/meson.build
+++ b/meson.build
@@ -1680,9 +1680,15 @@ endif
pkg = import('pkgconfig')
-prog_nm = find_program('nm', required : false)
-with_symbols_check = prog_nm.found() and with_tests
-symbols_check_args = ['--nm', prog_nm.path()]
+if host_machine.system() == 'windows'
+ prog_dumpbin = find_program('dumpbin', required : false)
+ with_symbols_check = prog_dumpbin.found() and with_tests
+ symbols_check_args = ['--dumpbin', prog_dumpbin.path()]
+else
+ prog_nm = find_program('nm', required : false)
+ with_symbols_check = prog_nm.found() and with_tests
+ symbols_check_args = ['--nm', prog_nm.path()]
+endif
# This quirk needs to be applied to sources with functions defined in assembly
# as GCC LTO drops them. See: https://bugs.freedesktop.org/show_bug.cgi?id=109391