| Subject: | Re: building a library with an external dependancy |
|---|---|
| From: | Paul Pluzhnikov <ppluzhnikov-nsp@xxxxxxxxxxx> |
| Date: | Sun, 16 Oct 2005 15:08:20 -0700 |
| Newsgroups: | gnu.gcc.help |
"Martijn" <subscription-remove-101@xxxxxxxxxxxxxxxxxxx> writes: > gcc ...-lcomctl32 -lhtmlhelp -llxdatastruct -llxwinctrl > -llxwinlib -lshlwapi -lversion -o a.exe > liblxwinctrl.a(lx_filectrl.o)(.text+0x1b):lx_filectrl.c: > undefined reference to `InitCommonControlsEx@4'' You've got the library order backwards. The libraries that use a symbol must preceed the library that *defines* it on the link line. Gory details here: http://webpages.charter.net/ppluzhnikov/linker.html Generally, you should list all system libraries *after* all of "user" (i.e. your own) libraries. Cheers, -- In order to understand recursion you must first understand recursion. Remove /-nsp/ for email. |
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: building a library with an external dependancy, Martijn |
|---|---|
| Next by Date: | Re: building a library with an external dependancy, Martijn |
| Previous by Thread: | Re: building a library with an external dependancy, Martijn |
| Next by Thread: | Re: building a library with an external dependancy, Martijn |
| Indexes: | [Date] [Thread] [Top] [All Lists] |