Skip to content
New issue

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

links not found when add_deps("openmp") #5345

Closed
xq114 opened this issue Jul 14, 2024 · 10 comments
Closed

links not found when add_deps("openmp") #5345

xq114 opened this issue Jul 14, 2024 · 10 comments
Labels

Comments

@xq114
Copy link
Contributor

xq114 commented Jul 14, 2024

Xmake 版本

2.9.3

操作系统版本和架构

Fedora

描述问题

https://github.com/xmake-io/xmake-repo/actions/runs/9920625780/job/27407697804?pr=4611

error: @programdir/core/package/package.lua:2406: package(openmp): links not found!

openmp本来就没有link

期待的结果

正常安装package

工程配置

附加信息和错误日志

@xq114 xq114 added the bug label Jul 14, 2024
@waruqi
Copy link
Member

waruqi commented Jul 14, 2024

再试试

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


try again

@xq114
Copy link
Contributor Author

xq114 commented Jul 14, 2024

还是不行,应该是#ldflags > 0才对吧;还有就是https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L2021-L2029 这里没考虑 fetchinfo 为boolean的情况,直接判断fetchinfo.version会出问题,是不是参考https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L1739-L1749 处理下?

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


Still not working, it should be #ldflags > 0; and https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L2021-L2029 is not considered here If fetchinfo is boolean, directly determine if there will be a problem with fetchinfo.version. Please refer to https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L1739-L1749 for processing. Down?

@waruqi
Copy link
Member

waruqi commented Jul 15, 2024

还是不行,应该是#ldflags > 0才对吧;

好了,再试试

还有就是https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L2021-L2029 这里没考虑 fetchinfo 为boolean的情况,直接判断fetchinfo.version会出问题,是不是参考https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L1739-L1749 处理下?

返回 boolean 原本就是不对的,当初早期可能有几个不规范的,改下包就好了。。现在统一只能返回 table

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


Still not working, it should be #ldflags > 0;

Okay, try again

There is also https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L2021-L2029. The case where fetchinfo is boolean is not considered here. Directly judge fetchinfo.version. If there is a problem, can you refer to https://github.com/xmake-io/xmake/blob/dev/xmake/core/package/package.lua#L1739-L1749 to solve it?

Returning boolean is originally wrong. There may be a few irregularities in the early days, so just change the package. . Now unified can only return table

@xq114
Copy link
Contributor Author

xq114 commented Jul 15, 2024

还是不行

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


Or not

@waruqi
Copy link
Member

waruqi commented Jul 15, 2024

还是不行

我这里正常,links not found 的问题没了。。可能是没更新到 master

> checking for c links(omp)
> checking for c snippet(test)
  => install openmp latest .. ok

反而是 openmp 这个包自从加了 fortran 后,ldflags 没设置对,导致 macos 下 test 测试不过,多了 -fopenmp 的 ldflags。。我改了下。。

xmake-io/xmake-repo#4663

@waruqi
Copy link
Member

waruqi commented Jul 16, 2024

应该可以了 xmake-io/xmake-repo#4663

@waruqi waruqi closed this as completed Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants