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]

Re: newbie dll question




On Fri, 16 May 1997, Bret A. Schuhmacher wrote:

> Hi,
> 
> I've been using gnu-win32 since back in the v16 days, but never
> seriously until now.  I downloaded v18 recently and attempted to make
> a relocatable dll following all the instructions I could find (thanks
> to the people who forged the path :-)).  All the files below were
> taken from the instructions at
> http://www.cygnus.com/misc/gnu-win32/building-reloc-dlls.txt.
> 
>
[snip] 

To solve the problem of undefined references in your dll, you need to
include the import library that containes GetModuleHandleA@4.  In this
case you need to include libkernel32.a since GetModuleHandle is in
kernel32.dll

Change you link command to...

#link DLL
ld --base-file tclvc.base --dll -o tcl76.dll \
regexp.o tclAppInit.o tclAsync.o tclBasic.o tclCkalloc.o \
tclClock.o tclCmdAH.o tclCmdIL.o tclCmdMZ.o tclDate.o tclEnv.o \
tclEvent.o tclExpr.o tclFCmd.o tclFHandle.o tclFileName.o tclGet.o \
tclHash.o tclHistory.o tclIO.o tclIOCmd.o tclIOSock.o tclIOUtil.o \
tclInterp.o tclLink.o tclLoad.o tclLoadNone.o tclMain.o  \
tclNotify.o tclParse.o tclPkg.o tclPosixStr.o tclPreserve.o tclProc.o \
tclUnixChan.o tclUnixFCmd.o tclUnixFile.o tclUnixInit.o tclUnixNotfy.o \
tclUnixPipe.o tclUnixSock.o tclUnixTime.o tclUtil.o tclVar.o panic.o  \
init.o fixup.o  $LIBPATH/libcygwin.a -e _dll_entry@12 \
$LIBPATH/libkernel32.a
	|
	|
	Here is the addition that will solve your problem.



Eric Britten






-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".


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