This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libgomp/39939] MinGW 4.3.0 fails to link sample programme.
- From: "julian1844 at yahoo dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 30 Apr 2009 04:42:54 -0000
- Subject: [Bug libgomp/39939] MinGW 4.3.0 fails to link sample programme.
- References: <bug-39939-17641@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #5 from julian1844 at yahoo dot com 2009-04-30 04:42 -------
Let us forget everything about libpthread. MinGW fails to link the sample
programme at the command
gcc -fopemnp test.c -gomp -o test.exe
The error messages I get are:
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(parallel.o):(.text+0xe):
undefin
ed reference to `_imp__pthread_getspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(parallel.o):(.text+0x46):
undefi
ned reference to `_imp__pthread_getspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(parallel.o):(.text+0x5e):
undefi
ned reference to `_imp__pthread_getspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(parallel.o):(.text+0x9e):
undefi
ned reference to `_imp__pthread_getspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0xf): undefined
r
eference to `_imp__pthread_key_create'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x22): undefined
reference to `_imp__pthread_setspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x34): undefined
reference to `_imp__sem_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x55): undefined
reference to `_imp__pthread_setspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x66): undefined
reference to `_imp__sem_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x16d):
undefined
reference to `_imp__pthread_getspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x1a1):
undefined
reference to `_imp__pthread_mutex_destroy'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x1b6):
undefined
reference to `_imp__sem_destroy'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x1e1):
undefined
reference to `_imp__pthread_getspecific'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x209):
undefined
reference to `_imp__pthread_mutex_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x268):
undefined
reference to `_imp__sem_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x2dd):
undefined
reference to `_imp__pthread_attr_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x2e8):
undefined
reference to `_imp__pthread_attr_setdetachstate'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x2f9):
undefined
reference to `_imp__pthread_attr_getstacksize'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x37f):
undefined
reference to `_imp__pthread_create'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x3a7):
undefined
reference to `_imp__pthread_attr_destroy'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(team.o):(.text+0x4e5):
undefined
reference to `_imp__pthread_attr_setstacksize'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(env.o):(.text+0x4ad): undefined
reference to `_imp__pthread_attr_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(env.o):(.text+0x4bc): undefined
reference to `_imp__pthread_attr_setdetachstate'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(env.o):(.text+0x562): undefined
reference to `_imp__pthread_attr_setstacksize'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x11): undefined
r
eference to `_imp__pthread_mutex_lock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x20): undefined
r
eference to `_imp__pthread_mutex_unlock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x56): undefined
r
eference to `_imp__sem_post'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x74): undefined
r
eference to `_imp__pthread_mutex_unlock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x89): undefined
r
eference to `_imp__pthread_mutex_unlock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0xa5): undefined
r
eference to `_imp__pthread_mutex_lock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0xd0): undefined
r
eference to `_imp__sem_post'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0xed): undefined
r
eference to `_imp__pthread_mutex_lock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x122): undefined
reference to `_imp__pthread_mutex_lock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x12b): undefined
reference to `_imp__pthread_mutex_unlock'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x134): undefined
reference to `_imp__pthread_mutex_destroy'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x14a): undefined
reference to `_imp__sem_destroy'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x174): undefined
reference to `_imp__pthread_mutex_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(bar.o):(.text+0x191): undefined
reference to `_imp__sem_init'
c:/mingw/bin/../lib/gcc/mingw32/4.3.0/libgomp.a(sem.o):(.text+0xa): undefined
re
ference to `_imp__sem_wait'
collect2: ld returned 1 exit status
My question is how should I link this programme.
--
julian1844 at yahoo dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |UNCONFIRMED
Resolution|INVALID |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39939