This is the mail archive of the
mailing list for the Cygwin project.
Re: Objc and DLLs
- To: <Ronald dot Pijnacker at best dot ms dot philips dot com>, "Robert Munro" <rmunro at comnetix dot com>
- Subject: Re: Objc and DLLs
- From: "Steve Biskis" <mlx at san dot rr dot com>
- Date: Mon, 29 Jun 1998 12:36:16 -0700
- Cc: <gnu-win32 at cygnus dot com>
- Reply-To: <mlx at san dot rr dot com>
Sorry, I took so long - didn't notice your email in my mess .
You must 1st initialize the ObjC runtime before attempting to use it.
Add this line:
__main(); // ObjC/C++ runtime initialization ...
BEFORE any Objective-C usage .
> From: Ronald Pijnacker <Ronald.Pijnacker@best.ms.philips.com>
> To: Robert Munro <firstname.lastname@example.org>
> Cc: cygwin <email@example.com>
> Subject: Re: Objc and DLLs
> Date: Monday, June 08, 1998 12:41 AM
> > Hi all, I have been trying to create an objective C dll using cygwin
> > and egcs 1.0.2 and here's the problem. After many attempts, the
> > finally links (apparently okay) and I create a library for it. I try
> > compile a test prog against the library and it compiles just fine. I
> > a function, no problem. However when I get to the line :
> > thisObject = [[myObject alloc] init];
> > it blows up. I get a STATUS_ACCESS_VIOLATIOn exception and then it
> > Dunno what's going on here at all, so maybe you guys could help me out.
> > Running with GDB, I get this when it crashes:
> > --start debug
> > --end of debug
> > Thanks for any help you guys could give...
> I have been trying to do the same thing some time ago, also without
> luck. Just as you have, I have been able to create a .dll (with the
> corresponding .a file for linking). Running a simple test program did
> not crash in my case, but the classes that were defined in the .dll
> were not available, as I got the message:
> objc runtime: cannot find class X
> Have you also had this problem?
> Ronald Pijnacker
> For help on using this list (especially unsubscribing), send a message to
> "firstname.lastname@example.org" with one line of text: "help".
For help on using this list (especially unsubscribing), send a message to
"email@example.com" with one line of text: "help".