[GHC] #7356: Building HEAD on Mac OS X 10.5 reports Undefined "_pthread_threadid_np" ref'd from _kernelThreadId in libHSrts_thr.a(OSThreads.thr_o)
GHC
cvs-ghc at haskell.org
Sun Oct 21 21:37:14 CEST 2012
#7356: Building HEAD on Mac OS X 10.5 reports Undefined "_pthread_threadid_np"
ref'd from _kernelThreadId in libHSrts_thr.a(OSThreads.thr_o)
---------------------------------+------------------------------------------
Reporter: thorkilnaur | Owner:
Type: bug | Status: new
Priority: normal | Component: Runtime System
Version: 7.7 | Keywords:
Os: MacOS X | Architecture: x86
Failure: Building GHC failed | Testcase:
Blockedby: | Blocking:
Related: |
---------------------------------+------------------------------------------
On a Mac OS X 10.5
{{{
$ uname -a
Darwin thorkil-naurs-intel-mac-mini.local 9.8.0 Darwin Kernel Version
9.8.0: Wed Jul 15 16:55:01 PDT 2009; root:xnu-1228.15.4~1/RELEASE_I386
i386
$
}}}
a build of recent HEAD
(http://darcs.haskell.org/ghcBuilder/builders/tn23/731.html) reports
{{{
"inplace/bin/ghc-stage1" -o ghc/stage2/build/tmp/ghc-stage2 -static -H32m
-O -hide-all-packages -i -ighc/. -ighc/stage2/build
-ighc/stage2/build/autogen -Ighc/stage2/build -Ighc/stage2/build/autogen
-optP-DGHCI -optP-include -optPghc/stage2/build/autogen/cabal_macros.h
-package array-0.4.0.1 -package base-4.6.0.0 -package bytestring-0.10.1.0
-package directory-1.2.0.0 -package filepath-1.3.0.1 -package
ghc-7.7.20121021 -package haskeline-0.7.0.3 -package process-1.1.0.2
-package transformers-0.3.0.0 -package unix-2.6.0.0 -fno-warn-name-
shadowing -Wall -XHaskell98 -XForeignFunctionInterface -XUnboxedTuples
-XFlexibleInstances -XMagicHash -XNondecreasingIndentation -XCPP
-XPatternGuards -O2 -threaded -no-user-package-db -rtsopts -odir
ghc/stage2/build -hidir ghc/stage2/build -stubdir ghc/stage2/build -hisuf
hi -osuf o -hcsuf hc ghc/stage2/build/Main.o
ghc/stage2/build/InteractiveUI.o ghc/stage2/build/GhciMonad.o
ghc/stage2/build/GhciTags.o ghc/stage2/build/hschooks.o
Undefined symbols:
"_pthread_threadid_np", referenced from:
_kernelThreadId in libHSrts_thr.a(OSThreads.thr_o)
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[1]: *** [ghc/stage2/build/tmp/ghc-stage2] Error 1
make: *** [all] Error 2
}}}
The reason seems to be (http://elliotth.blogspot.dk/2012/04/gettid-on-mac-
os.html):
Speaking of 10.6, there's also a non-portable pthread_threadid_np(3)
that turns a pthread_t into a uint64_t. This gives the same values you'd
get from thread_selfid(2). Again, this is unsupported in 10.5 and earlier.
Best regards
Thorkil
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7356>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list