Mail Archives: cygwin/1999/11/04/21:35:50
I'm still having problems getting DLL's to work correctly.
The problem I'm seeing is that I have a library, which
does a putenv before forking a new child. The child
process then tries to read this environment variable
to enable a TCP/IP based interprocess communication
protocol between the parent process and the child
process. However, when I compile the library as a DLL,
the child process doesn't get environment variable. Here's
some debug output from my test program.
30179: entering kipc_initialize()
30179: in kipc_enable, enable set to 1
30179: KhorosIpcTransport = 'tcpip=HOBBS:1024'
30180: entering kipc_initialize()
30180: KhorosIpcTransport = '(NULL)'
The parent process is 30179 and the child is 30180. As you can
see, the parent correctly has KhorosIpcTransport set in it's
environment (the value between the 's was from a getenv call),
but the child is NULL.
So, I'm guessing the problem is in the way I build my DLL's,
but I don't even know where to start looking for the problem.
I have a perl script that invokes ld and dlltools a number
of times, as described in several of the online cygwin dll
compile examples. I've tried using dllwrap with rules very
similar to the X11 dll rules, but it always fails to link,
complaining about a undefined reference to WinMain AT 16.
I'll be happy to send my createdll perl script to anyone that may
have an idea what I'm doing wrong.
Thanks in advance for any help.
Steve
--
-----------------------------------------------------------
Steven Jorgensen steve AT khoral DOT com steve AT haunt DOT com
------------------------------+----------------------------
Khoral Research Inc. | PHONE: (505) 837-6500
6200 Uptown Blvd, Suite 200 | FAX: (505) 881-3842
Albuquerque, NM 87110 | URL: http://www.khoral.com/
-----------------------------------------------------------
--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
- Raw text -