Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Feb 1998 17:56:23 -0500 (EST)
From:      Alfred Perlstein <perlsta@sunyit.edu>
To:        Donn Miller <dmm125@bellatlantic.net>
Cc:        hackers@FreeBSD.ORG
Subject:   Re: latest wine && seg-faults on freebsd
Message-ID:  <Pine.HPP.3.96.980204173215.5073A-100000@demeter.sunyit.edu>
In-Reply-To: <Pine.NEB.3.96.980204142536.12743A-100000@myname.my.domain>

next in thread | previous in thread | raw e-mail | index | archive | help
i've been working on the freebsd port to wine "unofficially"

well the problem lies in the fact that freebsd doesn't support the clone()
system call directly, i'm working on finding a suitable replacement,
someone on the list already gave me a lot of useful information towards
accomplishing this.

the original port includes patches for two things:
fixes that translate what wine expects the procfs to look like,
AND which is very irritating it basically comments out all support for
threads...

if you look in the file "sysdep.c" (i forget which dir, as i'm not at my
jerkstation right now) you will see a LOT of code that gets removed by the
CPP preprocessor because FreeBSD doesn't support clone(), my thoughts are
that clone is a nasty, yucky thing, it's cool but i don't think it exists
anywhere else but on linux.  i'm trying to get some sort of emulation
going.

what is going on is that the thread that is NOT being created is being
referenced by that segment of asm code what it translates to is:
move the longword pointed to by the extra-segment 'fs' into a variable.

the ugly fix ugly is to basically just comment out the body of the
function and make it return 0 all the time, I will be working on this for
a while trying to fix wine for freebsd

anyway if you follow the above advice and comment/undefine the code, it
gets farther, but then crashes in weird spot that i've yet to figure out,
but i only got it to that point last night at 4am ;)

you might have to upgrade to -current for the patches i plan to work on,
as -current includes better support for a clone-like call.

-Alfred

please, please, please, if you think you have the ability, fire up xxgdb
and help me debug this, i'm a good programmer, but i'm not terribly
familiar with the FreeBSD internals


On Wed, 4 Feb 1998, Donn Miller wrote:

> I just compiled the latest wine (wine980201) and it compiled great, except
> that I got seg-faults and dropped core every time I tried to run it.  So
> then I compiled with the -g flag and debugged it.  Here is the output of
> gdb:
> 
> Reading symbols from /usr/libexec/ld.so...done.
> Reading symbols from /usr/X11R6/lib/libXpm.so.4.10...done.
> Reading symbols from /usr/X11R6/lib/libSM.so.6.0...done.
> Reading symbols from /usr/X11R6/lib/libICE.so.6.3...done.
> Reading symbols from /usr/X11R6/lib/libXext.so.6.3...done.
> Reading symbols from /usr/X11R6/lib/libX11.so.6.1...done.
> Reading symbols from /usr/lib/libm.so.2.0...done.
> Reading symbols from /usr/lib/libc.so.3.0...done.
> #0  0x1be651 in NtCurrentTeb () at sysdeps.c:140
> 140         __asm__( ".byte 0x64\n\tmovl (%1),%0"
> (gdb) 
> 
> I compiled this ``straight out of the box'' instead of using FreeBSD's
> port collection and was interested in hearing from the person doing the
> latest ports to FreeBSD on what he/she did to correct this.  I guessing
> that it has something to do with threading (not X-windows threads but
> libc).
> 
> 	Donn
> 
> 




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.HPP.3.96.980204173215.5073A-100000>