diff --git a/Makefile b/Makefile index 3b4a0b2..a048eba 100644 --- a/Makefile +++ b/Makefile @@ -41,7 +41,7 @@ LDFLAGS=-melf_x86_64 COPTIM=-O2 CWARNS=-Wall -Wextra -Wno-unused-parameter -Wno-implicit-fallthrough -Werror=implicit-function-declaration -Werror=return-type CINCLUDES=-Iinclude -CFLAGS1=-nostdlib -ffreestanding -mcmodel=large -std=gnu11 -fdump-rtl-expand +CFLAGS1=-nostdlib -ffreestanding -mcmodel=large -std=gnu11 -fstack-protector-all -fdump-rtl-expand CFLAGS2= -c -mno-red-zone -mno-mmx -mno-sse -mno-sse2 CFLAGS= $(CFLAGS1) $(CFLAGS2) CFLAGS_MATHS= $(CFLAGS1) -c -mno-red-zone -mno-mmx -mno-sse2 @@ -55,10 +55,10 @@ CFLAGS += -g endif KCC=$(CCNAME) $(COPTIM) $(CWARNS) $(CFLAGS) $(CINCLUDES) \ - -D_OSK_SOURCE -D_KALEID_KERNEL -fstack-protector-all + -D_OSK_SOURCE -D_KALEID_KERNEL KCC_MATHS=$(CCNAME) $(COPTIM) $(CWARNS) $(CFLAGS_MATHS) $(CINCLUDES) \ - -D_OSK_SOURCE -D_KALEID_KERNEL -fstack-protector-all + -D_OSK_SOURCE -D_KALEID_KERNEL # Folders MBRDIR=boot/grub @@ -259,11 +259,12 @@ copy_kernel: @echo ${CL2}[$@] ${CL}Success.${CL3} @rmdir $(BINDIR)/disk -egypt: +egypt: CFLAGS := -DNDEBUG $(filter-out -fstack-protector-all,$(CFLAGS)) +egypt: dust $(LibCObj) $(KernObj) @find -name '*.expand' -o -name '*.expand' | xargs cat > rtl_exp.out @egypt < rtl_exp.out | dot -Tps -o osk-graph.ps @rm -f rtl_exp.out - @evince osk-graph.ps + @evince osk-graph.ps & dust: -@$(MBRDIR)/umount.sh $(BINDIR)/disk || /bin/true diff --git a/ProjectTree b/ProjectTree index 1bc1ee9..0f87887 100644 --- a/ProjectTree +++ b/ProjectTree @@ -302,7 +302,8 @@ ├── ChangeLog ├── COPYING ├── Makefile +├── osk-graph.ps ├── ProjectTree └── README.md -43 directories, 237 files +43 directories, 238 files diff --git a/include/ke/cpuid.h b/include/ke/cpuid.h index f10e53d..aa49f38 100644 --- a/include/ke/cpuid.h +++ b/include/ke/cpuid.h @@ -115,7 +115,7 @@ static inline int CpuCpuidString(int code, uint where[4]) void KeGetCpuInfos(void); double KeGetCpuSpeed(void); -extern void KeActivateSSE(void); +void KeActivateSSE(void); // -------------------------------------------------------------------------- // diff --git a/include/kernel.h b/include/kernel.h index 9392824..41a3431 100644 --- a/include/kernel.h +++ b/include/kernel.h @@ -186,7 +186,7 @@ extern CpuCore_t _KeCPUTable[NCPUS]; error_t KernLog(const char *, ...); -#ifndef _NO_DEBUG +#ifndef NDEBUG void DebugLog(const char *, ...); #else #define DebugLog(fmt, ...) ((void)0) diff --git a/kaleid/kernel/ke/log.c b/kaleid/kernel/ke/log.c index b160a47..0765e1f 100644 --- a/kaleid/kernel/ke/log.c +++ b/kaleid/kernel/ke/log.c @@ -40,7 +40,7 @@ error_t KernLog(const char *fmt, ...) return rc; } -#ifndef _NO_DEBUG +#ifndef NDEBUG // // Prints formatted string on debug output //