<div dir="ltr"><div>It's not implemented yet, see <a href="https://bugs.freepascal.org/view.php?id=37440">https://bugs.freepascal.org/view.php?id=37440</a>.</div><div>For unix systems the
pthread.inc
already contains the API headers for the sem_* functions (<a href="https://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/rtl/linux/pthread.inc?view=markup&sortby=file#l183">https://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/rtl/linux/pthread.inc?view=markup&sortby=file#l183</a>) but for
Mac OS X 10.4.8 the dynamic loading of
sem_init needs to be implemented (<a href="https://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/rtl/darwin/pthread.inc?view=markup&sortby=file#l71">https://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/rtl/darwin/pthread.inc?view=markup&sortby=file#l71</a>) and also another way to init a semaphore.</div><div>For Windows, see <a href="https://docs.microsoft.com/en-us/windows/win32/sync/using-semaphore-objects">https://docs.microsoft.com/en-us/windows/win32/sync/using-semaphore-objects</a>.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Am Do., 13. Aug. 2020 um 10:05 Uhr schrieb Ryan Joseph via fpc-pascal <<a href="mailto:fpc-pascal@lists.freepascal.org">fpc-pascal@lists.freepascal.org</a>>:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br>
<br>
> On Aug 13, 2020, at 12:42 PM, Sven Barth <<a href="mailto:pascaldragon@googlemail.com" target="_blank">pascaldragon@googlemail.com</a>> wrote:<br>
> <br>
> The way to go with semaphores would be to implement the Delphi compatible TSemaphore in the unit SyncObjs.<br>
<br>
Link? I'm looking at <a href="https://www.freepascal.org/docs-html/fcl/syncobjs/index-4.html" rel="noreferrer" target="_blank">https://www.freepascal.org/docs-html/fcl/syncobjs/index-4.html</a> and I don't see it.<br>
<br>
Regards,<br>
Ryan Joseph<br>
<br>
_______________________________________________<br>
fpc-pascal maillist - <a href="mailto:fpc-pascal@lists.freepascal.org" target="_blank">fpc-pascal@lists.freepascal.org</a><br>
<a href="https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal" rel="noreferrer" target="_blank">https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal</a><br>
</blockquote></div>