TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Relocatable linking

52 点作者 MaskRay超过 2 年前

2 条评论

vaughan超过 2 年前
I wish there was a GUI&#x2F;visualization for all this.<p>Everything is relatively simple to understand when visualized like it would be on a lecture slide. But reading about it in manpages and blog articles is overwhelming.
评论 #33735172 未加载
JonChesterfield超过 2 年前
I thought kernel modules were elf files created by relocatable links but that seems a strange omission from the examples list if so, may be misremembering.<p>ld -r elf -o out should be a no-op on well formed input. It means create a file that will be passed to another linker invocation later. So it&#x27;s a means of composing together N object files to get one file that you can use in place of those N. A little like a library.<p>I structured builds like that for a while. Source foo.c to foo.o, directory bar to bar.o containing whatever was in that directory relocatably-linked together, possibly internalising symbols as it goes.