On 21.05.19 16:34, Ralf Ramsauer wrote:
The 32-bit header is called header-32.S, so let's name the 64-bit header
header-64.S.
With this, we can also simplify and tune the Makefile a bit. This makes
life easier, if we later add further 32/64-bit specific targets.
Signed-off-by: Ralf Ramsauer <[email protected]>
---
inmates/lib/x86/Makefile | 14 +++++++-------
inmates/lib/x86/{header.S => header-64.S} | 0
2 files changed, 7 insertions(+), 7 deletions(-)
rename inmates/lib/x86/{header.S => header-64.S} (100%)
diff --git a/inmates/lib/x86/Makefile b/inmates/lib/x86/Makefile
index 97a37341..bae59025 100644
--- a/inmates/lib/x86/Makefile
+++ b/inmates/lib/x86/Makefile
@@ -40,24 +40,24 @@ include $(INMATES_LIB)/Makefile.lib
always := lib.a lib32.a
-TARGETS := header.o ioapic.o printk.o setup.o smp.o uart.o
+TARGETS := ioapic.o printk.o setup.o smp.o uart.o
TARGETS += ../alloc.o ../pci.o ../string.o ../cmdline.o ../setup.o
TARGETS += ../uart-8250.o ../printk.o
-TARGETS_64_ONLY := int.o mem.o pci.o timing.o
+TARGETS_32_ONLY := header-32.o
+TARGETS_64_ONLY := int.o mem.o pci.o timing.o header-64.o
lib-y := $(TARGETS) $(TARGETS_64_ONLY)
-
-lib32-y := $(addprefix $(obj)/,$(TARGETS:.o=-32.o))
+lib32-y := $(TARGETS:.o=-32.o) $(TARGETS_32_ONLY)
quiet_cmd_link_archive32 = AR $@
-cmd_link_archive32 = rm -f $@; $(AR) rcs$(KBUILD_ARFLAGS) $@ $(lib32-y)
+cmd_link_archive32 = rm -f $@; $(AR) rcs$(KBUILD_ARFLAGS) $@ $^
-$(obj)/lib32.a: $(lib32-y)
+$(obj)/lib32.a: $(addprefix $(obj)/,$(lib32-y))
$(call if_changed,link_archive32)
-AFLAGS_header-32.o := -m32
targets += header-32.o
+$(obj)/%-32.o: a_flags += -m32
$(obj)/%-32.o: c_flags += -m32
$(obj)/%-32.o: $(src)/%.c
$(call if_changed_rule,cc_o_c)
diff --git a/inmates/lib/x86/header.S b/inmates/lib/x86/header-64.S
similarity index 100%
rename from inmates/lib/x86/header.S
rename to inmates/lib/x86/header-64.S
Not based on next.
Jan
--
You received this message because you are subscribed to the Google Groups
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jailhouse-dev/6cce0fe1-3b50-3cb1-7eec-a64c6b564d79%40web.de.
For more options, visit https://groups.google.com/d/optout.