How to install a Linux / Mac computer clock with C # / Mono?

how can I programmatically set the clock of a hardware computer under Linux and Mac in C # using Mono CLR?

EDIT:

I created a C # library for this, so if everyone else needs this function, take it here:

https://github.com/mc-kay/sharp-timetools/

+3
source share
1 answer

You will need to use PInvoke (documentation: http://www.mono-project.com/Interop_with_Native_Libraries ) for this inline (c / C ++) function. For linux, here is the native function / struct: How do you programmatically install a hardware clock in Linux?

+1

Source: https://habr.com/ru/post/1777293/


All Articles