public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* N00b question regarding Cygwin and delay loading
@ 2016-06-20  8:20 Bill Zissimopoulos
  0 siblings, 0 replies; only message in thread
From: Bill Zissimopoulos @ 2016-06-20  8:20 UTC (permalink / raw)
  To: cygwin

TLDR: I am trying to use delay loading with Cygwin. Is it supported?

I have found information that I can do something along the following lines:

	gendef NATIVE.dll
	dlltool --input-def NATIVE.def --output-delaylib NATIVE.dll.a
	gcc -shared -o cygNAME.dll -Wl,--out-implib=libNAME.a NAME.c NATIVE.dll.a


However the messages that I get back say that I am missing the symbol
__delayLoadHelper2. Which actually makes sense. But where is Cygwin’s
delayimp.lib? Is there even one? Or am I supposed to somehow use this with
MSVC’s delayimp.lib? Or perhaps this is just a MinGW feature and not
supported on Cygwin?

Thank for any help. Full (failing) make output below:
<<
billziss@windows:~/Projects/winfsp/src/cygwin [libfuse]$ make
gendef "/cygdrive/c/Program Files (x86)/WinFsp/bin/winfsp-x64.dll"
 * [/cygdrive/c/Program Files (x86)/WinFsp/bin/winfsp-x64.dll] Found PE+
image
dlltool --input-def winfsp-x64.def --output-delaylib winfsp-x64.dll.a
gcc -shared -o cygfuse.dll -Wl,--out-implib=libfuse.a -I../../inc/fuse
cygfuse.c winfsp-x64.dll.a
winfsp-x64.dll.a(dwjdh.o):fake:(.text+0x15): undefined reference to
`__delayLoadHelper2'
winfsp-x64.dll.a(dwjdh.o):fake:(.text+0x15): relocation truncated to fit:
R_X86_64_PC32 against undefined symbol `__delayLoadHelper2'
collect2: error: ld returned 1 exit status
make: *** [Makefile:7: cygfuse.dll] Error 1

>>

Bill


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2016-06-20  0:29 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-20  8:20 N00b question regarding Cygwin and delay loading Bill Zissimopoulos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).