We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
xmake v2.8.5
Linux 720ce3a659a2 5.15.90.1-microsoft-standard-WSL2 #1 SMP Fri Jan 27 02:56:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
假设系统库中存在 k 库,而 add_packages("foo") 中 foo 也提供了 libk.a,当前 xmake 在链接 add_packages 引入的静态库时用的是 -L${target:pkgs("foo"):installdir("lib")} -lk 选项,从而导致我们在使用系统库 k 符号缺失。
希望可以提供一个 feature 让用户控制是使用 -l 使用 add_packages 引入的静态库,还是直接在链接时直接引用整个 libk.a 的绝对地址避免重名。
为了不影响之前的逻辑,默认使用 -l。
target("my_binary", function() set_kind("binary") .... add_syslinks("k") add_packages("foo") -- 提供 libk.a 静态库 end)
丢失系统库 k 符号。
The text was updated successfully, but these errors were encountered:
Bot detected the issue body's language is not English, translate it automatically.
Title: add_packages When using a static library, symbols are lost due to duplicate library names.
Sorry, something went wrong.
#3889
试下这个。#5066 (comment)
Try this. #5066 (comment)
No branches or pull requests
Xmake 版本
xmake v2.8.5
操作系统版本和架构
Linux 720ce3a659a2 5.15.90.1-microsoft-standard-WSL2 #1 SMP Fri Jan 27 02:56:13 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
描述问题
假设系统库中存在 k 库,而 add_packages("foo") 中 foo 也提供了 libk.a,当前 xmake 在链接 add_packages 引入的静态库时用的是 -L${target:pkgs("foo"):installdir("lib")} -lk 选项,从而导致我们在使用系统库 k 符号缺失。
期待的结果
希望可以提供一个 feature 让用户控制是使用 -l 使用 add_packages 引入的静态库,还是直接在链接时直接引用整个 libk.a 的绝对地址避免重名。
为了不影响之前的逻辑,默认使用 -l。
工程配置
附加信息和错误日志
丢失系统库 k 符号。
The text was updated successfully, but these errors were encountered: