get HOS building again on Ubuntu 17.04 with GCC 6

This commit is contained in:
josh committed 2017-07-26 13:41:23 -04:00
1 parent 0aaf5db5ad
commit 509009d134
10 files changed
+178 -198

No files matched your search

+6 -5
View File
@@ -8,15 +8,16 @@ NASM=nasm
NASM_FLAGS=-f aout
# C/C++ Information:
CPPFLAGS=-fleading-underscore -fno-builtin -nostdlib -nostartfiles -nodefaultlibs -I. -Wall
CPPFLAGS=-ffreestanding -fno-builtin -nostdlib -nostartfiles -nodefaultlibs -I. -Wall -m32 -fno-pic
# -S -masm=intel
CC=gcc
CXX=g++
CXXFLAGS=-fno-rtti -fno-exceptions -D_HOS_CPP_
CXXFLAGS=-fno-rtti -fno-exceptions -D_HOS_CPP_ -std=gnu++98
# Linker Information:
LD=ld
LDFLAGS=-nodefaultlibs -nostdlib --no-demangle -T link.ld
LD=gcc
LDFLAGS=-ffreestanding -fno-builtin -nostartfiles -nodefaultlibs -nostdlib -Wl,--no-demangle -T link.ld -m32
LIBS=-static-libgcc
# Files
OBJS=boot.o lang/lang_a.o \
@@ -43,7 +44,7 @@ CXXSRC=lang/string.cpp lang/new.cpp char/misc_char.cpp char/vconsole.cpp \
.PHONY: all depend clean html
all: $(OBJS)
$(LD) $(LDFLAGS) -Map kernel.map $(OBJS) -o kernel.bin
$(LD) $(LDFLAGS) -Wl,-Map -Wl,kernel.map $(OBJS) -o kernel.bin $(LIBS)
@echo ' Kernel built: ' `ls -sk kernel.bin | cut -d' ' -f1`kb
depend: