Subject: Re: dlopen a.exe
From: "Brian D. Carlstrom" <[email-masked]>
To: [email-masked]
Cc: [email-masked], [email-masked]
Date: Sun, 6 Aug 2000 22:58:01 -0700

Chris Faylor writes:
 > Regardless, you won't be able to retrieve anything with dlsym() unless
 > either the function/variable has been defined with the __declspec(dllexport)
 > attribute or you've included it in a linker .def file.

Aha! 

So I have a .def file...under B20. 

Under 1.1 (?) OSTYPE changed from cygwin32 to cygwin, so my Makefile
wasn't creating the .def file.

I use config.guess but it didn't catch this, because it uses:

    i*:CYGWIN*:*)
	echo i386-pc-cygwin32
	exit 0 ;;

I'm happy to get things updated especially because I removed the one
other "OSTYPE" cygwin32 hack I had, it was fixed with a cleanup of I/O
to apparently let "cat" be "cat" and not mess around with adding
carriage returns.

Jon Cook was probably trying to do the same thing I was, not really open
a.exe, but the current executable. I was trying to do it with a.exe as
well, because configure builds a.exe files. I do this in configure to
see if I need to prepend symbol names with an underscore, as well as to
see if the library automatically tries to do this.

Jon, if you still care and didn't figure it out, I can send you a
pointer to my magic to use the dlltool etc to make dlopen work with a
NULL first argument, which I stole from the tcl port.

Thanks again Chris. My bad.

-bri

--
Want to unsubscribe from this list?
Send a message to [email-masked]