Define thread primitives if they're supported.
authorShea Levy <shea@shealevy.com>
Tue, 29 Nov 2016 18:28:27 +0000 (13:28 -0500)
committerBen Gamari <ben@smart-cactus.org>
Tue, 29 Nov 2016 19:39:55 +0000 (14:39 -0500)
commit1732d7ac43ca578deca39ea5a63cbf34f3cd9dd5
tree258f187815dddea45843d17e57dad0dfcfd020ac
parent36e36227e438d95fae367d10183ea43b4819854f
Define thread primitives if they're supported.

On iOS, we use the pthread-based implementation of Itimer.c even for a
non-threaded RTS. Since 999c464, this relies on synchronization
primitives like Mutex, so ensure those primitives are defined whenever
they are supported, even if !THREADED_RTS.

Fixes #12799.

Reviewers: erikd, austin, simonmar, bgamari

Reviewed By: simonmar, bgamari

Subscribers: thomie

Differential Revision: https://phabricator.haskell.org/D2712

GHC Trac Issues: #12799
includes/rts/OSThreads.h
rts/posix/OSThreads.c