delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/11/04/21:35:50

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT sourceware DOT cygnus DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
From: Steve Jorgensen <steve AT khoral DOT com>
Message-Id: <199911050133.SAA27595@benson>
Subject: DLL's and environ again
To: cygwin AT sourceware DOT cygnus DOT com
Date: Thu, 4 Nov 1999 18:33:52 -0700 (MST)
X-Mailer: ELM [version 2.4 PL25]

	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 -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019