Subject: Re: newbie dll question
From: [email-masked] (Eric Britten)

21 May 1997 00:50:10 -0700
Approved: [email-masked]
Distribution: cygnus
Message-ID: <[email-masked]>
Reply-To: Eric Britten <[email-masked]>
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Original-To: "Bret A. Schuhmacher" <[email-masked]>
Original-cc: [email-masked]
In-Reply-To: <[email-masked]>
Original-Sender: [email-masked]

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
"[email-masked]" with one line of text: "help".