Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有某些库,例如具有全局状态的 gflags。我处于主要可执行文件和动态加载的插件(.so)都使用gflags的情况。在这两种情况下,bazel 都会静态链接 gflags。我需要改变这一点,我必须以某种方式告诉 bazel 仅动态链接 gflags。我想我可以设置linkstatic=False主可执行文件和插件(.so)。但在那之后,所有其他库也将动态链接到它们。
linkstatic=False
所以我的问题是:我怎样才能告诉 bazel只动态链接 gflags?