From d8eaa406e7b2f614d09553373b48aa9b74f5eac2 Mon Sep 17 00:00:00 2001 From: Greg Bowne Date: Mon, 2 Sep 2024 01:36:45 -0700 Subject: [PATCH] fixed build script by adding compiler flags -fno-pie and -fno-pic --- build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) mode change 100644 => 100755 build.sh diff --git a/build.sh b/build.sh old mode 100644 new mode 100755 index 1dff83e..ebf26a7 --- a/build.sh +++ b/build.sh @@ -22,7 +22,7 @@ nasm -f elf32 boot.asm -o boot.o # Compile and link the kernel echo "Compiling and linking kernel..." -gcc -m32 -ffreestanding -nostdlib kernel.c boot.o -o kernel.bin -T linker.ld +gcc -m32 -ffreestanding -nostdlib -fno-pic -fno-pie kernel.c boot.o -o kernel.bin -T linker.ld # Check if compilation was successful if [ -f kernel.bin ]; then