Skip to content

Commit

Permalink
Add --nx-module-name to linker flags
Browse files Browse the repository at this point in the history
  • Loading branch information
fincs committed Mar 29, 2019
1 parent 5647167 commit 1096d7e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions nx/switch.ld
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ SECTIONS
/* =========== RODATA section =========== */
. = ALIGN(0x1000);

.nx-module-name : { KEEP (*(.nx-module-name)) } :rodata

.rodata :
{
*(.rodata .rodata.* .gnu.linkonce.r.*)
Expand Down
2 changes: 1 addition & 1 deletion nx/switch.specs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
%rename link old_link

*link:
%(old_link) -T %:getenv(DEVKITPRO /libnx/switch.ld) -pie --gc-sections -z text -z nodynamic-undefined-weak --build-id=sha1
%(old_link) -T %:getenv(DEVKITPRO /libnx/switch.ld) -pie --gc-sections -z text -z nodynamic-undefined-weak --build-id=sha1 --nx-module-name

*startfile:
crti%O%s crtbegin%O%s
Expand Down

0 comments on commit 1096d7e

Please sign in to comment.