2015-08-14 09:58:16 +00:00
|
|
|
#Config
|
|
|
|
Artifact=kernel
|
|
|
|
TempDir=obj
|
2015-10-07 22:29:11 +00:00
|
|
|
SourceDir=asm src csl
|
2015-10-07 11:45:07 +00:00
|
|
|
AdditionalObjects=obj/main.o
|
|
|
|
ExternalObjects=conductance/|*.o
|
2015-08-14 09:58:16 +00:00
|
|
|
|
2015-08-14 11:27:04 +00:00
|
|
|
LexUseCpp
|
|
|
|
YaccUseCpp
|
|
|
|
|
2015-08-14 09:58:16 +00:00
|
|
|
# Tools
|
|
|
|
AS=gcc
|
|
|
|
CC=gcc
|
|
|
|
CXX=g++
|
|
|
|
LD=g++
|
|
|
|
LEX=flex
|
|
|
|
YACC=bison
|
2015-10-06 15:49:36 +00:00
|
|
|
#TEMPLE=mono /home/felix/projects/temple/bin/Debug/temple.exe
|
2015-08-14 09:58:16 +00:00
|
|
|
|
|
|
|
# Flags
|
2015-10-07 11:16:15 +00:00
|
|
|
FLAGS=-m32 -DCIRCUIT_OS -Dnullptr=0 -D__cdecl="__attribute__((cdecl))" -mno-sse -mno-sse2 -mno-mmx -I/home/felix/projects/Electronics/Electronics/Conductance -I/home/felix/projects/Electronics/Electronics/Tools
|
2015-08-14 21:53:51 +00:00
|
|
|
ASFLAGS=-masm=intel
|
2015-08-14 09:58:16 +00:00
|
|
|
CCFLAGS=-g -std=c11 -Dnullptr=0 -Wall -g -fno-stack-protector -ffreestanding -Iinclude
|
|
|
|
CXXFLAGS=-g -std=c++11 -Wall -g -fno-stack-protector -fno-use-cxa-atexit -nostdlib -fno-builtin -fno-rtti -fno-exceptions -fno-leading-underscore -Wall -Wextra -ffreestanding -Wno-unused-function -Iinclude
|
2015-10-07 01:43:23 +00:00
|
|
|
LDFLAGS=-g -m32 -nostdlib -fno-builtin -Tkernel.ld
|
2015-08-14 09:58:16 +00:00
|
|
|
|
2015-08-14 11:34:14 +00:00
|
|
|
--
|
2015-10-07 01:43:23 +00:00
|
|
|
|
2015-10-09 23:41:38 +00:00
|
|
|
obj/main.o: scripts/main.cu
|
|
|
|
/home/felix/projects/Electronics/build-Electronics-Desktop-Debug/bin/copper \
|
|
|
|
scripts/main.cu > \
|
|
|
|
scripts/main.cu.spark
|
2015-10-09 16:37:57 +00:00
|
|
|
/home/felix/projects/Electronics/build-Electronics-Desktop-Debug/bin/spark \
|
2015-10-09 23:41:38 +00:00
|
|
|
scripts/main.cu.spark \
|
2015-10-07 11:45:07 +00:00
|
|
|
obj/main.ca
|
2015-08-14 13:38:01 +00:00
|
|
|
objcopy -B i386 -I binary -O elf32-i386 \
|
2015-10-07 11:45:07 +00:00
|
|
|
obj/main.ca obj/main.o
|
2015-08-14 13:38:01 +00:00
|
|
|
objcopy \
|
2015-10-07 11:45:07 +00:00
|
|
|
--redefine-sym _binary_obj_main_ca_start=mainscript_start \
|
|
|
|
--redefine-sym _binary_obj_main_ca_end=mainscript_end \
|
|
|
|
--redefine-sym _binary_obj_main_ca_size=mainscript_size \
|
2015-08-14 13:38:01 +00:00
|
|
|
obj/main.o
|
|
|
|
|
2015-08-14 11:34:14 +00:00
|
|
|
.PHONY: run
|
|
|
|
run:
|
2015-08-17 13:38:19 +00:00
|
|
|
qemu-system-i386 -serial stdio -kernel kernel
|
2015-08-17 18:04:14 +00:00
|
|
|
|
|
|
|
.PHONY: debug
|
|
|
|
debug:
|
|
|
|
qemu-system-i386 -s -S -serial stdio -kernel kernel
|