Basic Hello World as seen many times before on x86_64 Linux: My current ld linker script: Invoked with: I’m currently getting a segfault. Inspecting the output of readelf -a I can see that my_section does not have executable permissions. I believe this is causing the segfault. If I replace it with .text : { *(.my_section*) } > rom it still
Tag: linker-scripts
Implement a similar module_init as Linux kernel, but meet some trouble in ld script
I like the linux kernel module_init function very much, I would like to implement the same function for my user space applications. I try to modify the linker script to do this: 1, copy a x86-64 standard ld script 2, add my customized section 3, put the init function pointer into moudle_init section 4, compile the app with a customized