Page MenuHomeFreeBSD

Apply the module ldscript correctly on a shared ko
Needs ReviewPublic

Authored by andrew on Jan 17 2022, 5:14 PM.
Tags
None
Referenced Files
F81945811: D33919.id101546.diff
Tue, Apr 23, 2:16 PM
Unknown Object (File)
Sat, Apr 6, 8:30 PM
Unknown Object (File)
Thu, Mar 28, 7:12 PM
Unknown Object (File)
Jan 9 2024, 8:45 PM
Unknown Object (File)
Dec 20 2023, 5:07 AM
Unknown Object (File)
Aug 29 2023, 1:57 AM
Unknown Object (File)
Jul 7 2023, 6:46 PM
Unknown Object (File)
Feb 15 2023, 5:47 PM
Subscribers
None

Details

Reviewers
kib
markj
imp
Summary

For kernel modules built as a shared object we link all the object
files together, then run ld again with the final link flags.

Previously we would apply the linker script to the former ld command
however the second linker command may undo these changes as it is
lacking access to the script. Fix this by moving the linker script to
the latter ld command when building a shared kernel object.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 43955
Build 40843: arc lint + arc unit

Event Timeline

andrew created this revision.
sys/conf/kmod.mk
244

Why this variable is needed?

sys/conf/ldscript.kmod.i386
31

Could you please explain the reason for this addition? Perhaps this should be done in the comment.