From f972cb6dc4b6e5a5ff25db80f41eb39d0dbb2f2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20Michaj=C5=82ow?= Date: Wed, 26 Mar 2025 00:36:37 +0100 Subject: [PATCH] meson: disable stack protector for mpv.com This is a bare runner for mpv.exe. There is no need for a stack protector here and when it is forced to be added by -fno-stack-protector it complains about missing symbols, because we don't link any standard libs here. Fixes: undefined symbol: __stack_chk_fail undefined symbol: __stack_chk_guard We could define those, but mpv.com wrapper doesn't need it. --- meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 7572769e0e..3eb752ee41 100644 --- a/meson.build +++ b/meson.build @@ -1820,7 +1820,7 @@ if get_option('cplayer') if win32 and get_option('win32-subsystem') != 'console' wrapper_sources= 'osdep/win32-console-wrapper.c' - executable('mpv', wrapper_sources, c_args: ['-municode', '-fno-asynchronous-unwind-tables'], + executable('mpv', wrapper_sources, c_args: ['-municode', '-fno-asynchronous-unwind-tables', '-fno-stack-protector'], link_args: ['-municode', '-nostartfiles', '-nodefaultlibs'], override_options: ['b_sanitize=none'], name_suffix: 'com', install: true)