Re: [fpc-pascal] Strange swap function, what does it do?

2020-08-13 Thread Sven Barth via fpc-pascal
Am 13.08.2020 um 22:37 schrieb Bo Berglund via fpc-pascal: I am working on the conversion of a service application from Windows/Delphi to Linux/FPC. When going through the code I found this procedure, which I do not quite understand the workings of, can someone please explain how it operates? p

[fpc-pascal] Strange swap function, what does it do?

2020-08-13 Thread Bo Berglund via fpc-pascal
I am working on the conversion of a service application from Windows/Delphi to Linux/FPC. When going through the code I found this procedure, which I do not quite understand the workings of, can someone please explain how it operates? procedure Swap2(var Source); var H, L: word; begin H := Hi

Re: [fpc-pascal] Raspberry PI download

2020-08-13 Thread Bo Berglund via fpc-pascal
On Thu, 13 Aug 2020 12:07:10 +0200, "Carsten Bager" wrote: >The links to download the Raspberry PI version, is not working. >Does anyone know if there will be a PI version in the future Why not simply check out the fpc sources via svn to the RPi and build it yourself there? You will need the see

[fpc-pascal] Bad code generation

2020-08-13 Thread Colin Western
On win 64, I have some code that consistently gives a segmentation fault with the current trunk fpc under -O4, and debugging suggests bad code generation. On Linux it works fine. I only intermittently compile with fpc on windows; stepping back through the revisions indicated that 43384 was the c

[fpc-pascal] Raspberry PI download

2020-08-13 Thread Carsten Bager
The links to download the Raspberry PI version, is not working. Does anyone know if there will be a PI version in the future I have tried on the Hungary and Canada site. The distribution in the archive below is for an EABIHF, compiled on RaspBerry 1 arm-linux system (for armv6 cpu). ftp://mirror

Re: [fpc-pascal] RTL semaphore supported?

2020-08-13 Thread Sven Barth via fpc-pascal
Ryan Joseph via fpc-pascal schrieb am Do., 13. Aug. 2020, 09:35: > > > > On Aug 13, 2020, at 12:42 PM, Sven Barth > wrote: > > > > The way to go with semaphores would be to implement the Delphi > compatible TSemaphore in the unit SyncObjs. > > Link? I'm looking at > https://www.freepascal.org/do

Re: [fpc-pascal] RTL semaphore supported?

2020-08-13 Thread Nico Neumann via fpc-pascal
It's not implemented yet, see https://bugs.freepascal.org/view.php?id=37440. For unix systems the pthread.inc already contains the API headers for the sem_* functions ( https://svn.freepascal.org/cgi-bin/viewvc.cgi/trunk/rtl/linux/pthread.inc?view=markup&sortby=file#l183) but for Mac OS X 10.4.8 th

Re: [fpc-pascal] RTL semaphore supported?

2020-08-13 Thread Tomas Hajny
On 2020-08-13 07:42, Sven Barth via fpc-pascal wrote: Am 13.08.2020 um 06:36 schrieb Ryan Joseph via fpc-pascal: Are semaphores actually supported in the RTL? I don't see they're available on macOS (compiling with trunk even). https://www.freepascal.org/docs-html/3.0.0/rtl/system/semaphoreinit

Re: [fpc-pascal] RTL semaphore supported?

2020-08-13 Thread Ryan Joseph via fpc-pascal
> On Aug 13, 2020, at 12:42 PM, Sven Barth wrote: > > The way to go with semaphores would be to implement the Delphi compatible > TSemaphore in the unit SyncObjs. Link? I'm looking at https://www.freepascal.org/docs-html/fcl/syncobjs/index-4.html and I don't see it. Regards, Ryan J