Re: [chrony-dev] clock_gettime() on macOS |
[ Thread Index |
Date Index
| More chrony.tuxfamily.org/chrony-dev Archives
]
- To: chrony-dev@xxxxxxxxxxxxxxxxxxxx
- Subject: Re: [chrony-dev] clock_gettime() on macOS
- From: Bryan Christianson <bryan@xxxxxxxxxxxxx>
- Date: Mon, 22 Aug 2016 20:41:13 +1200
- Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=smtpcorp.com; s=a0-2; h=Feedback-ID:X-Smtpcorp-Track:To:Message-Id:Date: From:Subject:List-Unsubscribe:Reply-To; bh=g/EQOkdPS5vlg7tyyOhe6dmE8RTSzp0Mo8ZwkEQVmWM=; b=0pINvEHZaXgNDscy+DLjkYlbVk alI6FjzSY7i4HDPtjmNTBuBC8xYcPu79Xuu+4kSZz3Hb9TKmlNm/omyVQKdbkIMScWya/TfTUquem T/WGLWNI26EZMo1rfFGqZWiL6qMVlc81B+dvKZ+67ZHWHKkXfMYBVclZX2phf6bKlhIXW0r9ZRqIj /1G6zo5+4Bht2tvq2wa8YAV/L4lHW7VaYDgwf9heKTGj1j75CJZJk3nSG3JWGgy3FiB9rrOsE2qIa NnKwRRKSVpdke0drEfxay1AFyGFt0rUUxNn1pD4CcY0Qqh7VxdDFd4BBx9IN8WTVodN5MOx6CP2ve eZBpLmag==;
- Feedback-id: 149811m:149811acx33YQ:149811sZGAxWlSVq:SMTPCORP
> On 22/08/2016, at 8:14 PM, Miroslav Lichvar <mlichvar@xxxxxxxxxx> wrote:
>
> On Mon, Aug 22, 2016 at 10:49:30AM +1200, Bryan Christianson wrote:
>> We need to make sure that chrony compiled on macOS 10.12 (or later) will still run on versions earlier than macOS 10.12
>
> Hm, is that a common practice on macOS to run binaries compiled on
> newer version of the system? For instance, on Linux with glibc (using
> versioned symbols) that wouldn't work.
Yeah - It is common practice. Compile on ‘current' software (in this case I’m compiling against the next version but I won’t be releasing any binaries until 10.12 is ‘current') and have runtime checks to ensure the function is implemented. That way you can release a single binary for all the versions of the OS that you have compiled against. Usually you only need to support back 2 or maybe 3 releases of the system software. For example - programs compiled in Swift will run on the version of MacOS that was current prior to Swift being released, OSX 10.9. ChronyControl, compiled on 1.12 will still run on 10.9
>
>> This patch allows that but I’m not sure it’s structured correctly for chrony and I don’t like the duplication of the gettimeofday() fallback.
>> Another option would be to modify configure so that HAVE_CLOCK_GETTIME is never set on macOS but that doesn’t feel right either.
>
> I don't know, both seem like ugly hacks to me. I'd rather add a more
> general "--without-clock-gettime" option to the configure script, so
> you can disable it if you have a good reason, but leave the detection
> enabled by default.
OK - That would work
Bryan Christianson
bryan@xxxxxxxxxxxxx
--
To unsubscribe email chrony-dev-request@xxxxxxxxxxxxxxxxxxxx with "unsubscribe" in the subject.
For help email chrony-dev-request@xxxxxxxxxxxxxxxxxxxx with "help" in the subject.
Trouble? Email listmaster@xxxxxxxxxxxxxxxxxxxx.