Commit 3a2c7ecf authored by Robert Kaiser's avatar Robert Kaiser
Browse files

final (?) fix for "not enough room for program headers" issue

parent 644a3d6d
...@@ -7,7 +7,7 @@ QEMU_OPTIONS += -machine q35 # More recent hardware. ...@@ -7,7 +7,7 @@ QEMU_OPTIONS += -machine q35 # More recent hardware.
# Support for TSC Deadline. But no log anymore.. # Support for TSC Deadline. But no log anymore..
#QEMU_OPTIONS += -cpu max -machine pc,kernel_irqchip=on,accel=kvm #QEMU_OPTIONS += -cpu max -machine pc,kernel_irqchip=on,accel=kvm
LD_FLAGS= -nostdlib -ffreestanding -Wl,-N LD_FLAGS= -nostdlib -ffreestanding
CFLAGS = -ffreestanding $(OPT_FLAGS) -Wall -Wextra -std=gnu11 -fno-pic -foptimize-sibling-calls # -mregparm=3 CFLAGS = -ffreestanding $(OPT_FLAGS) -Wall -Wextra -std=gnu11 -fno-pic -foptimize-sibling-calls # -mregparm=3
CFLAGS += -fno-asynchronous-unwind-tables # Disable generation of eh_frames. CFLAGS += -fno-asynchronous-unwind-tables # Disable generation of eh_frames.
CFLAGS += -fno-stack-protector CFLAGS += -fno-stack-protector
......
...@@ -2,6 +2,11 @@ ...@@ -2,6 +2,11 @@
designated as the entry point. */ designated as the entry point. */
ENTRY(_start) ENTRY(_start)
PHDRS
{
text PT_LOAD ;
}
/* Tell where the various sections of the object files will be put in the final /* Tell where the various sections of the object files will be put in the final
kernel image. */ kernel image. */
SECTIONS SECTIONS
...@@ -21,7 +26,7 @@ SECTIONS ...@@ -21,7 +26,7 @@ SECTIONS
*(.data) *(.data)
*(COMMON) *(COMMON)
*(.bss) *(.bss)
} } : text
/* Allows the other sections to pass through. */ /* Allows the other sections to pass through. */
.interp : { *(.interp) } .interp : { *(.interp) }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment