bug-gnustep
[Top][All Lists]
Advanced

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

gnustep-base-1.7.3 on Windows


From: Carl Eugen Hoyos
Subject: gnustep-base-1.7.3 on Windows
Date: Sat, 20 Sep 2003 17:10:08 +0200 (CEST)

I tested the gnustep base library 1.7.3 on Windows (XPProSP1), using
MinGW32 (MSYS-1.0.9 & MinGW-3.1.0-1) and cygwin (1.5.4), where I think it
wasn't possible to produce executables before ;-)

To compile the base library on cygwin (gcc-3.3.1 with threads=posix), I
had to add -DBUILD_libgnustep_base_DLL=1 to the compiler options in
subdirectory Additions.

I compiled the base library on cygwin and mingw32 with libffi and ffcall.
Both don't work perfectly, but the first problem is that
libgnustep-base.def doesn't know about libffi: configure should care if
it's libffi or ffcall!

The second problem with libgnustep-base.def is that for cygwin,
NSConcreteWindowsTask has to be changed into NSConcreteUnixTask.

On MingW, (after I deleted original objc Headers and Library!) I had to
insert #undefs for UINT32 and UINT64 between #include <ffi.h> and #include
<Foundation/NSMethodSignature.h> when compiling the library with libffi.

gdomap didn't compile on mingw and needed some changes: I had to delete
the definition of getopt (182ff) and the call for getuid in line 4658.

I never used gstcpport-*, but now, they don't compile (neither on cygwin
nor MinGW), so I had to delete them from the Makefile.

To run nsbundle successfully , I had to copy LoadMe.bundle into my home
directory, because it failed on cygwin and MinGW (after searching in
my home directory):
* ERROR: Can't find LoadMe bundle

On cygwin, awake shows an error which also occurs with the following
tests: basic, call, containers, nsarchiver, nscharacterset, nsdata,
nsdate, nsfilemanager, nsnotification, nsprocessinfo, nsscanner, nstask,
nstimer, nstimezone, string, thread, values.

$ obj/awake.exe
Decoded SubFoo label's should be 100 more than Encoded.

Test awakeAfterUsingCoder substitution of objects that will
   satisfy backward references
In [Foo encodeWithCoder:]
In [SubFoo encodeWithCoder:]
In [Foo encodeWithCoder:]
In [SubFoo encodeWithCoder:]
Encoded:  SubFoo label = 3, super label = 0
Decoded:  SubFoo label = 103, super label = 0

Test awakeAfterUsingCoder substitution of objects that
   will satisfy self-referential forward references
In [Foo encodeWithCoder:]
In [SubFoo encodeWithCoder:]
In [Foo encodeWithCoder:]
In [SubFoo encodeWithCoder:]
Encoded:  SubFoo label = 3, super label = 4
Decoded:  SubFoo label = 103, super label = 4

GNUSTEP Error:
A call to NSProcessInfo +initializeWithArguments:... must be made
as the first ObjC statment in main. This function is used to
establish the argv and environment variables.
: Uncaught exception NSInternalInconsistencyException, reason:
GNUSTEP Error:
A call to NSProcessInfo +initializeWithArguments:... must be made
as the first ObjC statment in main. This function is used to
establish the argv and environment variables.

nsinvocation doesn't work with libffi:
cygwin:
$ obj/nsinvocation.exe
Starting
Calling proxy
Testing NS_MESSAGE ... ERROR ... expecting 6 and got 2293412
Testing NS_INVOCATION ... ERROR ... expecting 8 and got 2293412
Segmentation fault (core dumped)

MinGW:
$ shared_obj/nsinvocation.exe
Starting
Calling proxy
Testing NS_MESSAGE ... ERROR ... expecting 6 and got 2293572
Testing NS_INVOCATION ... ERROR ... expecting 8 and got 2293572
Expect: 99, invoke: 99 forward: 99
Expect: 12345, invoke: 12345 forward: 12345
Expect: 123456, invoke: 123456 forward: 123456
Expect: 123456, invoke: 123456 forward: 123456
Expect: 123.456, invoke: 123,456 forward: 123,456
Expect: 123.456, invoke: 123,456 forward: 123,456
Expect: 3dd918, invoke: 3dd918 forward: 9c1820
Expect: 'string', invoke: 'string' forward: 'string'
Expect: {11,22}, invoke: {0,0}


On MinGW, nstask works partly and nsdata has the following output (which
might be intended?):
$ shared_obj/nsdata
2003-09-20 14:44:09.827 nsdata.exe[2580] No local time zone specified.
2003-09-20 14:44:09.827 nsdata.exe[2580] Using time zone with absolute
offset 0.
2003-09-20 14:44:09.817 nsdata.exe[2580] [NSMutableData
-dataWithSmdID:length:] no shared memory support
Mapped 14003 bytes
Copied 14003 bytes
Copied 14003 bytes
Read 14003 bytes
Copied 14003 bytes
Copied 14003 bytes
Shared data of 14003 bytes
Copied 14003 bytes
Copied 14003 bytes
Mutable shared data of 14003 bytes
Copied 14003 bytes
Copied 14003 bytes
Extended by 11 bytes to 14014 bytes
Unable to make mutable data with old ID
data with shmID gives data length 0
Encoded data into archive
Decoded data from archive - length 0
Set capacity of shared memory item to 0
NSMutableData Test
------------------------------------------------------------
1) String: (Test string for mutable data and archiver classes.)
2) String: (Test string for mutable data and archiver)
NSData Test
-------------------------------------------------------------------
1) String: (Test string for mutable data and archiver classes.)
    B) Buffer: ( classes.)
    E) Buffer: ( classes.)
2) String: (Test string for mutable data and archiver classes.)
nsdata.m 71 : Exception NSRangeException - Range location + length too
great
nsdata.m 113 : Exception NSRangeException - Range location + length too
great
nsdata.m 128 : Exception NSRangeException - Range location + length too
great
nsdata.m 167 : Exception NSRangeException - Range location + length too
great
nsdata.m 238 : Exception NSRangeException - Range location + length too
great
nsdata.m 275 : Exception NSRangeException - in getBytes:range:, range {
42, 10 } extends beyond size (51)
nsdata.m 293 : Exception NSRangeException - Range location + length too
great
nsdata.m 315 : Exception NSRangeException - Range location + length too
great
nsdata.m 353 : Exception NSRangeException - in subdataWithRange:, range {
42, 10 } extends beyond size (51)
nsdata.m 372 : Exception NSRangeException - Range location + length too
great

And finally, this is an example for an output of nsconnection_client (on
cygwin, server on MinGW, both using libffi), the "l" value of the struct
received by the server was 2291432 :-(
...
Small Struct:
  sending ptr to c got 3b
Struct:
2003-09-20 14:58:46.513 nsconnection_client[2880] No local time zone
specified.
2003-09-20 14:58:46.513 nsconnection_client[2880] Using time zone with
absolute
offset 0.
2003-09-20 14:58:46.510 nsconnection_client[2880] File GSFFIInvocation.m:
468. I
n GSFFIInvocationCallback Changed type signature
'{_foo=cdi*L}40@0:4{_foo=cdi*L}
8' to '{_foo=cdi*L}48@4:8{_foo=cdi*L}16' for 'sendStruct:'
  sending c='Z',d=1234.57,i=99,s=cow,l=9876543 got
c='A',d=123.456,i=1,s=horse,l
=987654
  sending ptr to  c='A',d=123.456,i=1,s=horse,l=987654 got
c='A',d=123.456,i=1,s
=horse,l=987654
Object:
  sending <NSObject: 1004cf30> got <NSObject: 1004cf30>
  sending ptr to <NSObject: 1004cf30> got <NSObject: 1004cf30>
Many Arguments:
Done

Greetings from Vienna, Carl Eugen




reply via email to

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