From f9eb14d914deeba470ec0a0353e96bc671c72f3c Mon Sep 17 00:00:00 2001 From: Ekopalypse <47723516+Ekopalypse@users.noreply.github.com> Date: Sat, 11 Sep 2021 03:48:02 +0200 Subject: [PATCH] builder: remove fPic argument from windows builds (#11467) --- vlib/v/builder/cc.v | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/vlib/v/builder/cc.v b/vlib/v/builder/cc.v index d71b72a465..912d12732b 100644 --- a/vlib/v/builder/cc.v +++ b/vlib/v/builder/cc.v @@ -307,7 +307,9 @@ fn (mut v Builder) setup_ccompiler_options(ccompiler string) { } if v.pref.is_shared { ccoptions.linker_flags << '-shared' - ccoptions.args << '-fPIC' // -Wl,-z,defs' + $if !windows { + ccoptions.args << '-fPIC' // -Wl,-z,defs' + } } if v.pref.is_bare { ccoptions.args << '-fno-stack-protector'