help-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ffcall/libffi for NetBSD/SPARC (was: Re: Objective-C programming)


From: Riccardo Mottola
Subject: Re: ffcall/libffi for NetBSD/SPARC (was: Re: Objective-C programming)
Date: Sun, 4 Dec 2005 11:23:03 +0100

Hey all..

I have some news on this matter here. First I make a sum up:

- platform is netbsd2 on sparc, both 32 and 64 bit. Perosnaly I am
working on 32bit.
- gnustep base has poblems due to ffcall (which happened to fail
regression tests on that platform)

david and I found out that there was a problem witht he configure
detection about passing small structs in registers or not. I manually
changed all generated header files and I could build a working, static
ffcall which passed its own regression tests. David then kindly tried
hard to integrate this in configure: since no good known test exists
for this kind of feature, a confgure option (whith possibly known good
default for the supproted platforms) was thought as a best option.
Unfortunately the configure is strange requiring some strange
dependencies to be built so he gave up on the task.

Quite some time later, I tried to build a shared library of ffcall,
since that is what is needed for GNUstep and I manually applied the
same hacks (that is setting manually in every generated file the flag
about small structs to the correct value) and built a shared library.
The regression tests pass for some libraries, but then mintests
segfaults for libcallback. I was again set back.
Then I had the idea to just to try to install this supposedly only
half-working ffcall and try to build gnustep on it. TO my pleasure I
found that almost everything is working ! Some problems in starting
gdnc,but probably they are unrelated. I can run TalkSoup which uses
distributed objects, I can run gworkspace, project center and most of
the apps ! Of course only further usage might prove stability, but the
leap between "nothing" and having all gui apps on my screen is big :)

thus I think that for sure that "fix" needs to be integrated in
ffcall... My proposal is a configure option with known defaults for
known OS/CPU combinations. So however has the knowledge to hack around
in autoconf...

have a nice weekend,
   Riccardo

> Hello Folks,
>
> Riccardo and I have attempted to track down NetBSD/SPARC's ffcall issues
> (I'm not sure anymore whether our issues are limited to the 64 bit
> versions).  AFAIR there is no support in gcc's libffi for NetBSD/SPARC
> and ffcall's configure script relies on code using undefined behavior to
> determine aspects such as whether small structs are returned via
> registers.  When I tried to distill this I even found differing results
> dependent on optimization levels.
>
> I wanted to add an explicit configure flag but it seems that changing
> configure scripts for ffcall is a non trivial task involving special
> directory layout and cross compilers.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]