Skip to content

Commit 5837156

Browse files
committed
meson: add static linker var
If an AR var is not exported, meson will use static linker from the host
1 parent 2eca712 commit 5837156

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

foreign_cc/meson.bzl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ def _create_meson_script(configureParameters):
8181
script.append("##export_var## CC {}".format(_absolutize(ctx.workspace_name, tools.cc)))
8282
if " " not in tools.cxx:
8383
script.append("##export_var## CXX {}".format(_absolutize(ctx.workspace_name, tools.cxx)))
84+
if " " not in tools.cxx_linker_static:
85+
script.append("##export_var## AR {}".format(_absolutize(ctx.workspace_name, tools.cxx_linker_static)))
8486

8587
copts = flags.cc
8688
cxxopts = flags.cxx

0 commit comments

Comments
 (0)