I was under the assumption that LazSerial, which is available from Online Package Manager in the Lazarus IDE is crossplatform. But it seems like this is not the case, at least not for Raspbian Buster as target.
I have worked on porting a project in Windows (Delphi 2007) to FPC/Lazarus on Windows in order to then move to Linux. I am using FPC 3.0.4/Lazarus 2.0.8 on Windows and Raspbian Buster. I have replaced the AsyncPro serial port with LazSerial. What happens is that after I was done moving from Delphi 2007 to FPC/Lazarus in Windows 10 I went to my RPi4 installation and used OLPM to install the LazSerial package there, but it failed! During the compile of the package the process stops with errors in lazsynaser.pas: lazsynaser.pas(252,15) Error: Identifier not found "B500000" lazsynaser.pas(252,22) Error: Illegal expression lazsynaser.pas(253,14) Error: Identifier not found "B576000" lazsynaser.pas(253,21) Error: Illegal expression ... the list continues... The section of code in the source file generating the errors looks like this: Rates: array[0..MaxRates, 0..1] of cardinal = ( (0, B0), (50, B50), (75, B75), ..... {$IFDEF UNIX} ,(500000, B500000), <==ERRORS start here (576000, B576000), (921600, B921600), (1000000, B1000000), (1152000, B1152000), (1500000, B1500000), (2000000, B2000000), (2500000, B2500000), (3000000, B3000000), (3500000, B3500000), (4000000, B4000000) {$ENDIF} The rates above the first error are defined in termios.inc in the compiler rtl sources. So now I wonder if this is a problem with my installation or if it is not possible to run LazSerial on this platform? Or is there a problem with LazSerial in connection with the release version 3.0.4 of FPC? -- Bo Berglund Developer in Sweden -- _______________________________________________ lazarus mailing list lazarus@lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus