HomePhabricator

[CMAKE] Fix getentropy detection on OSX

Authored by Fabien on Jan 17 2020, 21:36.

Description

[CMAKE] Fix getentropy detection on OSX

Summary:
OSX needs both unistd.h and sys/random.h in order to define
getentropy().

Test Plan:
On OSX:

cmake -GNinja ..

Check the first getentropy (only unistd.h) fails, and the second one
(both unistd.h and sys/random.h) succeeds.

Run the OSX gitian build.

Reviewers: #bitcoin_abc, deadalnix, jasonbcox

Reviewed By: #bitcoin_abc, deadalnix, jasonbcox

Differential Revision: https://reviews.bitcoinabc.org/D5007

Details

Committed
FabienJan 17 2020, 21:48
Pushed
FabienJan 17 2020, 21:48
Reviewer
Restricted Project
Differential Revision
D5007: [CMAKE] Fix getentropy detection on OSX
Parents
rABC56a37f9d7cb5: [CMAKE] Fix daemon() detection on OSX
Branches
Unknown
Tags
Unknown