aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/compilers
diff options
context:
space:
mode:
authorLaurin-Luis Lehning <65224843+e820@users.noreply.github.com>2020-12-14 13:54:51 +0100
committerDylan Baker <dylan@pnwbakers.com>2020-12-14 11:23:53 -0800
commit4053babf9cc240051df20576d1eed4f904eaa71e (patch)
tree7dc75f710d4da69bd3cc651dfa5831e91bf92868 /mesonbuild/compilers
parent76b577af117477803d32101a031028179244476a (diff)
downloadmeson-4053babf9cc240051df20576d1eed4f904eaa71e.zip
meson-4053babf9cc240051df20576d1eed4f904eaa71e.tar.gz
meson-4053babf9cc240051df20576d1eed4f904eaa71e.tar.bz2
Slight consistency changes to get_gui_app_args
Diffstat (limited to 'mesonbuild/compilers')
-rw-r--r--mesonbuild/compilers/compilers.py3
-rw-r--r--mesonbuild/compilers/mixins/visualstudio.py8
2 files changed, 2 insertions, 9 deletions
diff --git a/mesonbuild/compilers/compilers.py b/mesonbuild/compilers/compilers.py
index b1452b2..e83514d 100644
--- a/mesonbuild/compilers/compilers.py
+++ b/mesonbuild/compilers/compilers.py
@@ -871,7 +871,8 @@ class Compiler(metaclass=abc.ABCMeta):
return []
def get_gui_app_args(self, value: bool) -> T.List[str]:
- return []
+ # Only used on Windows
+ return self.linker.get_gui_app_args(value)
def get_win_subsystem_args(self, env: 'Environment', value: str) -> T.List[str]:
# By default the dynamic linker is going to return an empty
diff --git a/mesonbuild/compilers/mixins/visualstudio.py b/mesonbuild/compilers/mixins/visualstudio.py
index 6e9a4d7..c38d59a 100644
--- a/mesonbuild/compilers/mixins/visualstudio.py
+++ b/mesonbuild/compilers/mixins/visualstudio.py
@@ -197,14 +197,6 @@ class VisualStudioLikeCompiler(Compiler, metaclass=abc.ABCMeta):
def linker_to_compiler_args(self, args: T.List[str]) -> T.List[str]:
return ['/link'] + args
- def get_gui_app_args(self, value: bool) -> T.List[str]:
- # the default is for the linker to guess the subsystem based on presence
- # of main or WinMain symbols, so always be explicit
- if value:
- return ['/SUBSYSTEM:WINDOWS']
- else:
- return ['/SUBSYSTEM:CONSOLE']
-
def get_pic_args(self) -> T.List[str]:
return [] # PIC is handled by the loader on Windows