Date: Wed, 28 Nov 2007 09:01:41 -0500 (EST) From: Andrew Gallatin <gallatin@cs.duke.edu> To: freebsd-amd64@freebsd.org Subject: Wine? Message-ID: <18253.29916.822508.369692@grasshopper.cs.duke.edu>
index | next in thread | raw e-mail
[-- Attachment #1 --]
A search through the archives says that wine will only work in 32-bit
mode. Of course, I only went searching for this *after* I slogged
through trying to add FreeBSD support to signal_x86_64.c
(diff attached in case anybody wants it). Then the build started
dying in the rpc code because it was being compiled 64-bit.
If it is truly the case that wine must be built 32-bit, then is it
possible to setup a 32-bit FreeBSD in a chroot someplace, and
build/install the relavant ports there?
Also, on a somewhat related note, is Linux emulation (of 32-bit ELF)
on par with i386 these days?
Thanks,
Drew
[-- Attachment #2 --]
--- work/wine-0.9.48/dlls/ntdll/signal_x86_64.c.bak 2007-10-26 13:21:15.000000000 -0400
+++ work/wine-0.9.48/dlls/ntdll/signal_x86_64.c 2007-11-27 14:32:53.136023287 -0500
@@ -92,6 +92,43 @@
#define FAULT_ADDRESS (__siginfo->si_addr)
#endif /* linux */
+#if defined(__FreeBSD__)
+#include <sys/signal.h>
+
+typedef struct sigcontext SIGCONTEXT;
+
+# define HANDLER_DEF(name) void name( int __signal, struct __siginfo *__siginfo, SIGCONTEXT *__context )
+# define HANDLER_CONTEXT (__context)
+
+#define RAX_sig(context) ((context)->sc_rax)
+#define RBX_sig(context) ((context)->sc_rbx)
+#define RCX_sig(context) ((context)->sc_rcx)
+#define RDX_sig(context) ((context)->sc_rdx)
+#define RSI_sig(context) ((context)->sc_rsi)
+#define RDI_sig(context) ((context)->sc_rdi)
+#define RBP_sig(context) ((context)->sc_rbp)
+#define R8_sig(context) ((context)->sc_r8)
+#define R9_sig(context) ((context)->sc_r9)
+#define R10_sig(context) ((context)->sc_r10)
+#define R11_sig(context) ((context)->sc_r11)
+#define R12_sig(context) ((context)->sc_r12)
+#define R13_sig(context) ((context)->sc_r13)
+#define R14_sig(context) ((context)->sc_r14)
+#define R15_sig(context) ((context)->sc_r15)
+#define CS_sig(context) (*((WORD *)&(context)->sc_cs + 0))
+#define GS_sig(context) (*((WORD *)&(context)->sc_cs + 1))
+#define FS_sig(context) (*((WORD *)&(context)->sc_cs + 2))
+#define RSP_sig(context) ((context)->sc_rsp)
+#define RIP_sig(context) ((context)->sc_rip)
+#define EFL_sig(context) ((context)->sc_flags)
+#define TRAP_sig(context) ((context)->sc_trapno)
+#define ERROR_sig(context) ((context)->sc_err)
+
+#define FPU_sig(context) ((XMM_SAVE_AREA32 *)((context)->sc_fpstate))
+
+#define FAULT_CODE (__siginfo->si_code)
+#define FAULT_ADDRESS (__siginfo->si_addr)
+#endif /* FreeBSD */
enum i386_trap_code
{
home |
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?18253.29916.822508.369692>
