Fix noconsole.exe

The linker flag "-mwindows" has no effect on my current MinGW.

Instead, passing "-Wl,--subsystem,windows" works.

Fixes <https://github.com/Genymobile/scrcpy/issues/691>
This commit is contained in:
Romain Vimont 2019-11-19 12:22:11 +01:00
parent 7aed5d5b60
commit 18f2e33a8b

View file

@ -123,10 +123,8 @@ configure_file(configuration: conf, output: 'config.h')
src_dir = include_directories('src')
if get_option('windows_noconsole')
c_args = [ '-mwindows' ]
link_args = [ '-mwindows' ]
link_args = [ '-Wl,--subsystem,windows' ]
else
c_args = []
link_args = []
endif
@ -134,7 +132,7 @@ executable('scrcpy', src,
dependencies: dependencies,
include_directories: src_dir,
install: true,
c_args: c_args,
c_args: [],
link_args: link_args)
install_man('scrcpy.1')