aboutsummaryrefslogtreecommitdiffstats
path: root/extras/mini-os/arch/x86/Makefile
blob: 1073e36267e5de00aff7872ac85f340f0a7625a9 (plain)
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
#
# x86 architecture specific makefiles.
# It's is used for x86_32, x86_32y and x86_64
#

XEN_ROOT = $(CURDIR)/../../../..
include $(XEN_ROOT)/Config.mk
include ../../Config.mk

# include arch.mk has to be before mini-os.mk!

include arch.mk
include ../../minios.mk

# Sources here are all *.c *.S without $(XEN_TARGET_ARCH).S
# This is handled in $(HEAD_ARCH_OBJ)
ARCH_SRCS := $(wildcard *.c)

# The objects built from the sources.
ARCH_OBJS := $(patsubst %.c,$(OBJ_DIR)/%.o,$(ARCH_SRCS))

all: $(OBJ_DIR)/$(ARCH_LIB)

# $(HEAD_ARCH_OBJ) is only build here, needed on linking
# in ../../Makefile.
$(OBJ_DIR)/$(ARCH_LIB): $(ARCH_OBJS) $(OBJ_DIR)/$(HEAD_ARCH_OBJ)
	$(AR) rv $(OBJ_DIR)/$(ARCH_LIB) $(ARCH_OBJS)

clean:
	rm -f $(OBJ_DIR)/$(ARCH_LIB) $(ARCH_OBJS) $(OBJ_DIR)/$(HEAD_ARCH_OBJ)