Skip to content

use of clock_gettime() blocks build of xray on macOS 10.11 and less #38307

Open
@kencu

Description

@kencu
Bugzilla Link 38959
Version unspecified
OS MacOS X
CC @devnexen

Extended Description

clock_gettime() was added in macOS 10.12.

https://stackoverflow.com/questions/5167269/clock-gettime-alternative-in-mac-os-x

clock_gettime() is used in several instances in the xray runtime library, and CLOCK_REALTIME is used but undefined on 10.11 and earlier, and so the build fails on systems without this function and definition.

A possible replacement function is used in MacPorts for a similar failure in other software:

https://github.com/macports/macports-ports/blob/master/graphics/cogl/files/patch-clock_gettime.diff

Another clock_gettime() replacement function with an MIT license is noted here https://gist.github.com/alfwatt/3588c5aa1f7a1ef7a3bb

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugzillaIssues migrated from bugzillaxray

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions