From: Josh Henrie <jhenrie2@gmail.com>
To: pthreads-win32@sourceware.org
Subject: Unresolved external symbol __imp_pthread_mutex_unlock
Date: Thu, 08 Nov 2018 21:54:00 -0000 [thread overview]
Message-ID: <CAFZNUX+yqS_hs64EP1WNpGY6S53BWD_HgE3rCMCUMLJO37PHQA@mail.gmail.com> (raw)
I have compiled pthreads-win32 as a static library using VS 2008 with the
following preprocessor definitions:
_DEBUG
_WIN32_WCE=0x600
UNDER_CE
WINCE
DEBUG
_LIB
ARM
_ARM_
_UNICODE
UNICODE
HAVE_CONFIG_H
NEED_PROCESS_AFFINITY_MASK
NEED_ERRNO
__PTW32_RC_MSC
__PTW32_ARCHARM
__PTW32_STATIC_LIB
However, when I try to link it with my project I get the following linker
errors:
error LNK2001: unresolved external symbol __imp_pthread_mutex_unlock
error LNK2001: unresolved external symbol __imp_pthread_mutex_lock
error LNK2001: unresolved external symbol __imp_pthread_self
error LNK2001: unresolved external symbol __imp_pthread_cond_signal
error LNK2001: unresolved external symbol __imp_pthread_join
error LNK2001: unresolved external symbol __imp_pthread_create
error LNK2001: unresolved external symbol __imp_pthread_equal
error LNK2019: unresolved external symbol __imp_pthread_cond_timedwait
error LNK2019: unresolved external symbol __imp_pthread_cond_broadcast
When I use `dumpbin /symbols` on the static library I see the following
symbols:
4BE 00005CC0 SECT8 notype () External | pthread_mutex_unlock
44D 000050B4 SECT8 notype () External | pthread_mutex_lock
399 00004428 SECT8 notype () External | pthread_self
2E6 0000359C SECT8 notype () External | pthread_cond_signal
83D 0000A110 SECT8 notype () External | pthread_join
332 00003D50 SECT8 notype () External | pthread_create
377 0000423C SECT8 notype () External | pthread_equal
32B 00003D00 SECT8 notype () External | pthread_cond_timedwait
302 000038C0 SECT8 notype () External | pthread_cond_broadcast
Why is the linker trying to resolve the functions with the prefix `__imp_`?
What do I need to do to resolve the symbols?
next reply other threads:[~2018-11-08 21:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-08 21:54 Josh Henrie [this message]
2018-11-08 22:15 ` Josh Henrie
2018-11-09 8:20 ` John Emmas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAFZNUX+yqS_hs64EP1WNpGY6S53BWD_HgE3rCMCUMLJO37PHQA@mail.gmail.com \
--to=jhenrie2@gmail.com \
--cc=pthreads-win32@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).