]> rtime.felk.cvut.cz Git - jailhouse.git/blob - inmates/lib/x86/Makefile
inmates: Add support for command line parameters
[jailhouse.git] / inmates / lib / x86 / Makefile
1 #
2 # Jailhouse, a Linux-based partitioning hypervisor
3 #
4 # Copyright (c) Siemens AG, 2015, 2016
5 #
6 # Authors:
7 #  Jan Kiszka <jan.kiszka@siemens.com>
8 #
9 # This work is licensed under the terms of the GNU GPL, version 2.  See
10 # the COPYING file in the top-level directory.
11 #
12
13 always := lib.a lib32.a
14
15 TARGETS := header.o hypercall.o ioapic.o printk.o smp.o
16 TARGETS += ../pci.o ../string.o ../cmdline.o
17 TARGETS_64_ONLY := int.o mem.o pci.o timing.o
18
19 ccflags-y := -ffunction-sections
20
21 lib-y := $(TARGETS) $(TARGETS_64_ONLY)
22
23 lib32-y := $(addprefix $(obj)/,$(TARGETS:.o=-32.o))
24
25 quiet_cmd_link_archive32 = AR      $@
26 cmd_link_archive32 = rm -f $@; $(AR) rcs$(KBUILD_ARFLAGS) $@ $(lib32-y)
27
28 $(obj)/lib32.a: $(lib32-y)
29         $(call if_changed,link_archive32)
30
31 AFLAGS_header-32.o := -m32
32 targets += header-32.o
33
34 $(obj)/%-32.o: c_flags += -m32
35 $(obj)/%-32.o: $(src)/%.c
36         $(call if_changed_rule,cc_o_c)