This is the mail archive of the cygwin@sources.redhat.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]

Help - Building DLLs


Recently I purchased the Cygwin v1.0 software to compile Linux C source
files in the Windows NT environment. But something went wrong. So I decided
to face the problem by steps.

First I created 2 simple source C files named "myprog.c" and "mydll.c"
(these files are attached to the e-mail). Then I executed the subsequent
commands in the shell:

gcc -c myprog.c

gcc -c mydll.c

ld --dll -o mydll.dll mydll.o -e _mydll_init@12 -d -cref -shared --base-file
mydll.base

dlltool --base-file=mydll.base --output-def mydll.def --output-exp
mydll.exp --dllname mydll.dll

ld --dll -o mydll.dll mydll.o -e _mydll_init@12 -d -cref -shared --base-file
mydll.base mydll.exp

dlltool --base-file=mydll.base --def mydll.def --output-exp
mydll.exp --dllname mydll.dll

ld --dll -o mydll.dll mydll.o -e _mydll_init@12 -d -cref -shared mydll.exp

dlltool --def mydll.def --dllname mydll.dll --output-lib mydll.a

gcc -o myprog myprog.o mydll.a

At the end of this process this error message is displayed:

myprog.o(.text+0x26):myprog.c: undefined reference to 'do_nothing'
collect2: ld returned 1 exit status

What do you suggest I do to resolve the problem?

The software is very important as it will and can aid me in developing my
research. BUT it does not work and I need to know what I am doing wrong or
why the software is not working. Please respond to my email, my questions.

Please answer directly using my email.

Thanks for your attention.

Best Regards.

Giuliano Garuti
Software Developer
Sunrise Telecom Protel Division Srl
Via Jacopo Peri, 41/C
41100 Modena ITALY
Phone: +39059403711
Fax: +39059403715
Video Conference: +39059403700
email: giuliano.garuti@sunriseprotel.com
Web: www.sunriseprotel.com

myprog.c

mydll.c

DLL test.zip

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

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