build: use -fPIC only for x64 binaries

This commit is contained in:
jeefo 2023-04-25 00:06:24 +03:00
commit 4fb46bd6ec
No known key found for this signature in database
GPG key ID: 927BCA0779BEA8ED

View file

@ -163,6 +163,9 @@ if cxx == 'clang' or cxx == 'gcc'
ldflags += '-Wl,/MACHINE:X86'
cxxflags += '-Wl,/MACHINE:X86'
endif
else
cxxflags += '-fPIC'
ldflags += '-fPIC'
endif
# link needed libraries