Running Lazarus on Linux configured to target Android on ARM.

synaser.pas [r207] failed to compile due to missing rate constants which
are found in ./fpc/rtl/linux/termios.inc.  Adjusting two IFDEF from UNIX to
LINUX allows it to compile (and TTCPBlockSocket works btw on Android).

According to http://wiki.freepascal.org/Android :
The compiler does NOT define LINUX during compilation! It defines UNIX and
ANDROID though.


--- ./synaser.pas 2017-06-07 07:53:38.000000000
+++ ./synaser_edited.pas 2018-04-13 13:20:29.000000000
@@ -193,17 +193,17 @@
     EvtChar: CHAR;
     wReserved1: Word;
   end;
   PDCB = ^TDCB;

 const
-{$IFDEF UNIX}
+{$IFDEF LINUX}
   {$IFDEF BSD}
   MaxRates = 18;  //MAC
   {$ELSE}
-   MaxRates = 30; //UNIX
+   MaxRates = 30; //LINUX
   {$ENDIF}
 {$ELSE}
   MaxRates = 19;  //WIN
 {$ENDIF}
   Rates: array[0..MaxRates, 0..1] of cardinal =
   (
@@ -225,13 +225,13 @@
     (38400, B38400),
     (57600, B57600),
     (115200, B115200),
     (230400, B230400)
 {$IFNDEF BSD}
     ,(460800, B460800)
-  {$IFDEF UNIX}
+  {$IFDEF LINUX}
     ,(500000, B500000),
     (576000, B576000),
     (921600, B921600),
     (1000000, B1000000),
     (1152000, B1152000),
     (1500000, B1500000),
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
synalist-public mailing list
synalist-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/synalist-public

Reply via email to