-
Notifications
You must be signed in to change notification settings - Fork 265
/
Makefile.header
executable file
·50 lines (39 loc) · 959 Bytes
/
Makefile.header
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
OS := $(shell uname)
# Qemu
QEMU = qemu-system-i386
# Bochs
BOCHS = bochs
# VM configuration
VM_CFG = tools/vm.cfg
# Tool for Image building
BUILD = tools/build.sh
# Tool for specify root device
SETROOTDEV = tools/setrootdev.sh
# Specify the Rootfs Image file
HDA_IMG = hdc-0.11.img
FLP_IMG = rootimage-0.11
RAM_IMG = rootram.img
# Tool for call graph generation
CG = tools/callgraph
ifeq ($(OS), Linux)
AS = as --32
LD = ld
LDFLAGS = -m elf_i386
CC = gcc
CFLAGS = -g -m32 -fno-builtin -fno-stack-protector -fomit-frame-pointer -fstrength-reduce #-Wall
CPP = cpp -nostdinc
AR = ar
STRIP = strip
OBJCOPY = objcopy
endif
ifeq ($(OS), Darwin)
AS = i386-elf-as --32
LD = i386-elf-ld
LDFLAGS = -m elf_i386
CC = i386-elf-gcc
CFLAGS = -gdwarf-2 -g3 -m32 -fno-builtin -fno-stack-protector -fomit-frame-pointer -fstrength-reduce #-Wall
CPP = i386-elf-cpp -nostdinc
AR =i386-elf-ar
STRIP = i386-elf-strip
OBJCOPY = i386-elf-objcopy
endif