Main: fix kernel examples

This commit is contained in:
Alex Kotov 2022-02-02 07:46:21 +05:00
parent 15ea973a16
commit 1f1675ec2d
Signed by: kotovalexarian
GPG Key ID: 553C0EBBEB5D5F08
3 changed files with 38 additions and 32 deletions

View File

@ -5,6 +5,7 @@ CCPREFIX = ../../vendor/cross/root/bin/i386-elf-
AS = $(CCPREFIX)as AS = $(CCPREFIX)as
CC = $(CCPREFIX)gcc CC = $(CCPREFIX)gcc
LIBKERNAUX_SRC = ../..
LIBKERNAUX_BUILD = ../../build/dev-cross-i386 LIBKERNAUX_BUILD = ../../build/dev-cross-i386
LIBKERNAUX_DEST = ../../dest/dev-cross-i386 LIBKERNAUX_DEST = ../../dest/dev-cross-i386
@ -23,15 +24,16 @@ GRUBCFG = $(ROOTFS)/boot/grub/grub.cfg
KERNEL = $(ROOTFS)/boot/kernel KERNEL = $(ROOTFS)/boot/kernel
CFLAGS = \ CFLAGS = \
-std=c99 \ -std=c99 \
-pedantic \ -pedantic \
-Wall \ -Wall \
-Wextra \ -Wextra \
-Werror \ -Werror \
-ffreestanding \ -ffreestanding \
-fno-builtin \ -fno-builtin \
-fno-stack-protector \ -fno-stack-protector \
-I../../include -I$(LIBKERNAUX_SRC)/include \
-I$(LIBKERNAUX_BUILD)/include
OBJS = main.c.o multiboot2.c.o start.S.o OBJS = main.c.o multiboot2.c.o start.S.o

View File

@ -5,6 +5,7 @@ CCPREFIX = ../../vendor/cross/root/bin/i386-elf-
AS = $(CCPREFIX)as AS = $(CCPREFIX)as
CC = $(CCPREFIX)gcc CC = $(CCPREFIX)gcc
LIBKERNAUX_SRC = ../..
LIBKERNAUX_BUILD = ../../build/dev-cross-i386 LIBKERNAUX_BUILD = ../../build/dev-cross-i386
LIBKERNAUX_DEST = ../../dest/dev-cross-i386 LIBKERNAUX_DEST = ../../dest/dev-cross-i386
@ -38,15 +39,16 @@ FULL_LIMINE_ELTORITO = $(ROOTFS)/$(REL_LIMINE_ELTORITO)
FULL_LIMINE_SYS = $(ROOTFS)/$(REL_LIMINE_SYS) FULL_LIMINE_SYS = $(ROOTFS)/$(REL_LIMINE_SYS)
CFLAGS = \ CFLAGS = \
-std=c99 \ -std=c99 \
-pedantic \ -pedantic \
-Wall \ -Wall \
-Wextra \ -Wextra \
-Werror \ -Werror \
-ffreestanding \ -ffreestanding \
-fno-builtin \ -fno-builtin \
-fno-stack-protector \ -fno-stack-protector \
-I../../include -I$(LIBKERNAUX_SRC)/include \
-I$(LIBKERNAUX_BUILD)/include
OBJS = main.c.o multiboot2.c.o start.S.o OBJS = main.c.o multiboot2.c.o start.S.o

View File

@ -5,6 +5,7 @@ CCPREFIX = ../../vendor/cross/root/bin/x86_64-elf-
AS = $(CCPREFIX)as AS = $(CCPREFIX)as
CC = $(CCPREFIX)gcc CC = $(CCPREFIX)gcc
LIBKERNAUX_SRC = ../..
LIBKERNAUX_BUILD = ../../build/dev-cross-x86_64 LIBKERNAUX_BUILD = ../../build/dev-cross-x86_64
LIBKERNAUX_DEST = ../../dest/dev-cross-x86_64 LIBKERNAUX_DEST = ../../dest/dev-cross-x86_64
@ -37,21 +38,22 @@ FULL_LIMINE_ELTORITO = $(ROOTFS)/$(REL_LIMINE_ELTORITO)
FULL_LIMINE_SYS = $(ROOTFS)/$(REL_LIMINE_SYS) FULL_LIMINE_SYS = $(ROOTFS)/$(REL_LIMINE_SYS)
CFLAGS = \ CFLAGS = \
-std=c99 \ -std=c99 \
-Wall \ -Wall \
-Wextra \ -Wextra \
-Werror \ -Werror \
-ffreestanding \ -ffreestanding \
-fno-builtin \ -fno-builtin \
-fno-stack-protector \ -fno-stack-protector \
-fno-pic \ -fno-pic \
-I../../include \ -I$(LIBKERNAUX_SRC)/include \
-mabi=sysv \ -I$(LIBKERNAUX_BUILD)/include \
-mcmodel=kernel \ -mabi=sysv \
-mno-80387 \ -mcmodel=kernel \
-mno-red-zone \ -mno-80387 \
-mno-red-zone \
-MMD -MMD
# -pedantic \ # -pedantic \
OBJS = main.c.o stivale2.c.o OBJS = main.c.o stivale2.c.o