使用 Cocotron CDT 与 SDL 链接

发布于 2024-10-10 06:14:34 字数 352 浏览 0 评论 0原文

我正在尝试使用 Cocotron 在 Xcode 中为 Linux 进行编译。 Foundation 的一切都运行良好,但我也尝试使用 SDL。我已经从 Linux (Ubuntu) 复制了库,但链接时遇到问题。

尽管也复制了 libpulse-simple (并将其放置在我认为可能有意义的每个目录中),我仍然无法删除此错误:

warning: libpulse-simple.so.0, needed by /Developer/Cocotron/1.0/Linux/i386/Frameworks//libSDL-1.2.so, not found (try using -rpath or -rpath-link)

I'm trying to use Cocotron to compile for Linux in Xcode. Everything's working great with Foundation, but I'm trying to also use SDL. I've copied the libraries over from Linux (Ubuntu) but I'm having trouble linking.

Despite copying libpulse-simple over as well (and placing it in every directory I thought would possibly make sense), I was still unable to remove this error:

warning: libpulse-simple.so.0, needed by /Developer/Cocotron/1.0/Linux/i386/Frameworks//libSDL-1.2.so, not found (try using -rpath or -rpath-link)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

荭秂 2024-10-17 06:14:34

问题已解决:为 SDL 的每个依赖项显式添加“其他链接器标志”。对于其他尝试这样做的人来说,那就是:

-lFLAC -lnsl -logg -lvorbis -lvorbisenc -ldbus -lsndfile -luuid -lwrap -lXau -lXdmcp -lXext -lXi -lxcb -lXtst -lX11-xcb -lxcb-atom -lSM -lrt -lpulsecommon -lSDL -lpulse -lpulse-simple -lX11 -lICE

Problem solved: explicitly add "Other Linker Flag"s for every dependency of SDL. For anyone else trying to do this, that's:

-lFLAC -lnsl -logg -lvorbis -lvorbisenc -ldbus -lsndfile -luuid -lwrap -lXau -lXdmcp -lXext -lXi -lxcb -lXtst -lX11-xcb -lxcb-atom -lSM -lrt -lpulsecommon -lSDL -lpulse -lpulse-simple -lX11 -lICE
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文