All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Fix 64-bit foreign header check
@ 2007-08-15 14:20 john.levon
  2007-08-15 14:24 ` Keir Fraser
  0 siblings, 1 reply; 10+ messages in thread
From: john.levon @ 2007-08-15 14:20 UTC (permalink / raw)
  To: xen-devel

# HG changeset patch
# User john.levon@sun.com
# Date 1187187471 25200
# Node ID ce1e8719a4d8c2d9051e60e14213550ba0eb3809
# Parent  3177ef0cc3ecc27051af5b3cbba72b3e42a26b68
Fix 64-bit foreign header check

If a 64-bit build is chosen, we need to compile the checker program with -m64.
Use CFLAGS instead of HOSTCFLAGS (this check doesn't work under a
cross-compile anyway).

Signed-off-by: John Levon <john.levon@sun.com>

diff --git a/xen/include/public/foreign/Makefile b/xen/include/public/foreign/Makefile
--- a/xen/include/public/foreign/Makefile
+++ b/xen/include/public/foreign/Makefile
@@ -18,7 +18,7 @@ check-headers: checker
 	./checker > $(XEN_TARGET_ARCH).size
 	diff -u reference.size $(XEN_TARGET_ARCH).size
 checker: checker.c $(headers)
-	$(HOSTCC) $(HOSTCFLAGS) -o $@ $<
+	$(CC) $(CFLAGS) -o $@ $<
 else
 check-headers:
 	@echo "cross build: skipping check"

^ permalink raw reply	[flat|nested] 10+ messages in thread
* [PATCH] Fix 64-bit foreign header check
@ 2007-08-16 13:23 john.levon
  0 siblings, 0 replies; 10+ messages in thread
From: john.levon @ 2007-08-16 13:23 UTC (permalink / raw)
  To: xen-devel

# HG changeset patch
# User john.levon@sun.com
# Date 1187270597 25200
# Node ID f78511fe84879f080875738ddf29081ee30ef0b1
# Parent  e3c3b44f29ad067c8a25e58c0e35265fe64eaa38
Fix 64-bit foreign header check

If a 64-bit build is chosen, we need to compile the checker program with -m64.
Since the Xen build doesn't support multilib GCC on Linux, hack it in for
Solaris for altering HOSTCFLAGS appropriately.

Signed-off-by: John Levon <john.levon@sun.com>

diff --git a/config/SunOS.mk b/config/SunOS.mk
--- a/config/SunOS.mk
+++ b/config/SunOS.mk
@@ -35,6 +35,12 @@ endif
 
 CFLAGS += -Wa,--divide -D_POSIX_C_SOURCE=200112L -D__EXTENSIONS__
 
+# We don't support cross-compiling, as we need to force the host compiler into
+# 64-bit mode as necessary: the foreign header check uses HOSTCFLAGS.
+HOSTCFLAGS_x86_32 = -m32
+HOSTCFLAGS_x86_64 = -m64
+HOSTCFLAGS += $(HOSTCFLAGS_$(XEN_TARGET_ARCH))
+
 CTFCONVERT = $(SOLARIS_BUILD_TOOLS)/onbld/bin/i386/ctfconvert
 CTFMERGE = $(SOLARIS_BUILD_TOOLS)/onbld/bin/i386/ctfmerge
 POST_PROCESS_O= $(CTFCONVERT) -i -L XEN_FULLVERSION $@

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2007-08-16 13:23 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-15 14:20 [PATCH] Fix 64-bit foreign header check john.levon
2007-08-15 14:24 ` Keir Fraser
2007-08-15 14:37   ` John Levon
2007-08-15 14:59     ` Keir Fraser
2007-08-15 15:27       ` John Levon
2007-08-15 16:04         ` Keir Fraser
2007-08-15 16:08           ` John Levon
2007-08-16  7:15             ` Keir Fraser
2007-08-15 16:09           ` John Levon
  -- strict thread matches above, loose matches on Subject: below --
2007-08-16 13:23 john.levon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.