This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Cygwin built DLL invoked from MSC app doesn't seem to be all there.


It's seems that only some bits of the cygwin API work inside a dll
invoked from a none cygwin applications.

Given the following....
---- server_body.c ----
#include <stdio.h>

int __declspec (dllexport)
Server_Init(void *interp)
{
  sleep(20);
  fprintf(stderr, "Hi there\n");
  return 1;
}

Built like...

  gcc -c -g   -o server_body.o server_body.c
  dllwrap --output-def server.def --add-stdcall-alias \
    -Wl,-e,__cygwin_noncygwin_dll_entry@12 --implib libserver.a \
    --driver-name gcc -o server.dll server_body.o 

If loaded from an off-the-shelf scriptics tclsh80 (8.05 I think) with
`load server.dll server' the sleep(20) doesn't.

The fprintf works, sleep() and other stuff doesn't. I think select()'s
screwed too... code which uses it did work when invoked from a cygwin
application so I haven't bothered messing with it much..

Invoking, it in a very simplier manner, from inside a commercial lump of
junk yields the same results.

Anyone got any thoughts? I getting really close to having to use
micromush tools and yucky ugly stuff like that..

byebye,
  jon.

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]