Re: [fpc-pascal] Using built-in serial instead of synaser and the like for Linux console app?

2020-09-01 Thread Bo Berglund via fpc-pascal
On Mon, 31 Aug 2020 12:01:33 +0200, Bo Berglund via fpc-pascal wrote: >Thanks, I was worried about reading more data than specified. >Now I can let the loop in Execute read say 10 bytes or so with timeout >ane process these, then loop back after firing off the event. Just a follow-up for complet

Re: [fpc-pascal] Using built-in serial instead of synaser and the like for Linux console app?

2020-09-01 Thread Bo Berglund via fpc-pascal
On Tue, 01 Sep 2020 10:22:08 +0200, Bo Berglund via fpc-pascal wrote: >Maybe I could tie the timeout to the actual baud used? Slower speeds >use longer timeout etc? Timeout could be set to the time it takes to >transfer the number of bytes to read? > >And both arguments could be made properties o

Re: [fpc-pascal] Linux GTK-2 GUI app

2020-09-01 Thread Adriaan van Os via fpc-pascal
leledumbo via fpc-pascal wrote: Or create different packages for different distros ? If you can afford the maintenance burden, this is the best that every specific distro user will love. Otherwise, just provide a compressed archive with README inside. What about flatpak or snap-pak packages

Re: [fpc-pascal] Linux GTK-2 GUI app

2020-09-01 Thread Michael Van Canneyt via fpc-pascal
On Tue, 1 Sep 2020, Adriaan van Os via fpc-pascal wrote: leledumbo via fpc-pascal wrote: Or create different packages for different distros ? If you can afford the maintenance burden, this is the best that every specific distro user will love. Otherwise, just provide a compressed archive

Re: [fpc-pascal] Using built-in serial instead of synaser and the like for Linux console app?

2020-09-01 Thread Jean SUZINEAU via fpc-pascal
Le 01/09/2020 à 10:49, Bo Berglund via fpc-pascal a écrit : Is there no way to declare a property to have a default non-zero value? I'm not sure but I think the syntax is for this something like property ReadPacketSize: integer read FPacketSize write FPacketSize default 10; Reference: https:

Re: [fpc-pascal] Using built-in serial instead of synaser and the like for Linux console app?

2020-09-01 Thread Jean SUZINEAU via fpc-pascal
Ooops, wrong url, I just learn know that property could belong to a global block... ;-) For classes: https://www.freepascal.org/docs-html/ref/refsu33.html#x86-1080006.7.1 ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freep

Re: [fpc-pascal] Using built-in serial instead of synaser and the like for Linux console app?

2020-09-01 Thread Michael Van Canneyt via fpc-pascal
On Tue, 1 Sep 2020, Bo Berglund via fpc-pascal wrote: On Tue, 01 Sep 2020 10:22:08 +0200, Bo Berglund via fpc-pascal wrote: Maybe I could tie the timeout to the actual baud used? Slower speeds use longer timeout etc? Timeout could be set to the time it takes to transfer the number of bytes

[fpc-pascal] fpcmake packaging

2020-09-01 Thread Ryan Joseph via fpc-pascal
I've never used fpcmake before and instead relied on my own custom build system solutions which are a pain to maintain and non-standard which it makes extra work configuring the pascal language server I'm using now. My first question of fpcmake is, can I package application bundles and copy res

Re: [fpc-pascal] fpcmake packaging

2020-09-01 Thread Michael Van Canneyt via fpc-pascal
On Tue, 1 Sep 2020, Ryan Joseph via fpc-pascal wrote: I've never used fpcmake before and instead relied on my own custom build system solutions which are a pain to maintain and non-standard which it makes extra work configuring the pascal language server I'm using now. My first question of

Re: [fpc-pascal] fpcmake packaging

2020-09-01 Thread Tony Whyman via fpc-pascal
fpcmake is a pre-processor that generates makefiles for fpc projects. You can use it to do just about anything a standard makefile can do, including including resource files and running scripts. I use it all the time for building production versions of lazarus programs and prior to packaging th

Re: [fpc-pascal] fpcmake packaging

2020-09-01 Thread Ryan Joseph via fpc-pascal
> On Sep 1, 2020, at 7:46 PM, Tony Whyman via fpc-pascal > wrote: > > fpcmake is a pre-processor that generates makefiles for fpc projects. You can > use it to do just about anything a standard makefile can do, including > including resource files and running scripts. I use it all the time f

Re: [fpc-pascal] fpcmake packaging

2020-09-01 Thread Tomas Hajny via fpc-pascal
On 2020-09-01 15:29, Ryan Joseph via fpc-pascal wrote: On Sep 1, 2020, at 7:46 PM, Tony Whyman via fpc-pascal wrote: fpcmake is a pre-processor that generates makefiles for fpc projects. You can use it to do just about anything a standard makefile can do, including including resource files a

Re: [fpc-pascal] fpcmake packaging

2020-09-01 Thread Tony Whyman via fpc-pascal
On 01/09/2020 14:29, Ryan Joseph via fpc-pascal wrote: On Sep 1, 2020, at 7:46 PM, Tony Whyman via fpc-pascal wrote: fpcmake is a pre-processor that generates makefiles for fpc projects. You can use it to do just about anything a standard makefile can do, including including resource file

Re: [fpc-pascal] Linux GTK-2 GUI app

2020-09-01 Thread Adriaan van Os via fpc-pascal
Michael Van Canneyt wrote: Normally a zip file with a the binary and supporing files, plus a README file should be enough. Can you refer me to an example ? Thanks, Adriaan van Os ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://

Re: [fpc-pascal] Linux GTK-2 GUI app

2020-09-01 Thread Michael Van Canneyt via fpc-pascal
On Tue, 1 Sep 2020, Adriaan van Os via fpc-pascal wrote: Michael Van Canneyt wrote: Normally a zip file with a the binary and supporing files, plus a README file should be enough. Can you refer me to an example ? You can't get more simple than this I think: https://github.com/gohugoio/h

Re: [fpc-pascal] Using built-in serial instead of synaser and the like for Linux console app?

2020-09-01 Thread Bo Berglund via fpc-pascal
On Tue, 1 Sep 2020 14:21:44 +0200 (CEST), Michael Van Canneyt via fpc-pascal wrote: >You must still set the default value in the constructor. > >> >> Note that the thread itself has no idea what is the baudrate in use so >> it cannot calculate the proper value at the start of Execute... >> And th

[fpc-pascal] x86-linux-gnu cross

2020-09-01 Thread Adriaan van Os via fpc-pascal
On Mac OS X 10.8, I have built an fpc-3.0.4 runtime-library for CPU_TARGET=x86_64 OS_TARGET=linux BINUTILSPREFIX=x86_64-linux-gnu- after building gnu binutils-2.34 for --target=x86_64-linux-gnu --host=i686-apple-darwin --build=i686-apple-darwin --prefix=/usr/local. Now the following program c

Re: [fpc-pascal] Using built-in serial instead of synaser and the like for Linux console app?

2020-09-01 Thread Michael Van Canneyt via fpc-pascal
On Tue, 1 Sep 2020, Bo Berglund via fpc-pascal wrote: On Tue, 1 Sep 2020 14:21:44 +0200 (CEST), Michael Van Canneyt via fpc-pascal wrote: You must still set the default value in the constructor. Note that the thread itself has no idea what is the baudrate in use so it cannot calculate th

[fpc-pascal] Lazarus complains that it cannot find a dependency, why?

2020-09-01 Thread Bo Berglund via fpc-pascal
I get an error message when building a project after updating from SVN to get the sources that build fine on another RPi4 identical in configuration. "Fatal: Cannot find LazSerial used by RemoteIO. Check if package LazSerialPort is in the dependencies." The LazSerial dependency has been *removed*

Re: [fpc-pascal] x86-linux-gnu cross

2020-09-01 Thread Marco van de Voort via fpc-pascal
Op 2020-09-01 om 20:28 schreef Adriaan van Os via fpc-pascal: On Mac OS X 10.8, I have built an fpc-3.0.4  runtime-library for CPU_TARGET=x86_64 OS_TARGET=linux BINUTILSPREFIX=x86_64-linux-gnu- after building gnu binutils-2.34 for  --target=x86_64-linux-gnu --host=i686-apple-darwin --build=i68

Re: [fpc-pascal] Lazarus complains that it cannot find a dependency, why?

2020-09-01 Thread Bo Berglund via fpc-pascal
On Tue, 01 Sep 2020 21:07:56 +0200, Bo Berglund via fpc-pascal wrote: >I get an error message when building a project after updating from SVN >to get the sources that build fine on another RPi4 identical in >configuration. > >"Fatal: Cannot find LazSerial used by RemoteIO. Check if package >LazSe

Re: [fpc-pascal] Lazarus complains that it cannot find a dependency, why?

2020-09-01 Thread Bo Berglund via fpc-pascal
On Tue, 01 Sep 2020 22:46:55 +0200, Bo Berglund via fpc-pascal wrote: >STRANGE "SOLUTION", BUT WHY? > >So even though I am not really using *anything* in LazSerial I added >LazSerialPort back to the dependencies and rebuilt the application. >Now the thread creation doe

Re: [fpc-pascal] Lazarus complains that it cannot find a dependency, why?

2020-09-01 Thread Tomas Hajny via fpc-pascal
On 2020-09-01 23:44, Bo Berglund via fpc-pascal wrote: On Tue, 01 Sep 2020 22:46:55 +0200, Bo Berglund via fpc-pascal wrote: Hi, Further to this mystery: If I remove LazSerialPort from the dependencies and instead put SdpoSerialLaz there instead it also solves the problem: - Program builds

Re: [fpc-pascal] Lazarus complains that it cannot find a dependency, why?

2020-09-01 Thread Bo Berglund via fpc-pascal
On Tue, 01 Sep 2020 23:55:08 +0200, Tomas Hajny via fpc-pascal wrote: >Well, I believe that this supposed mystery may be resolved easily. ;-) >First of all - have you tried to find out what does the displayed error >number (232) mean? Quick searching reveals that runtime error 232 may >signali

Re: [fpc-pascal] Lazarus complains that it cannot find a dependency, why?

2020-09-01 Thread Tomas Hajny via fpc-pascal
On 2020-09-02 00:21, Bo Berglund via fpc-pascal wrote: . . Strange because I have read that cthreads must be first in uses in the lpr program files in order to make threads work. How could it work if I add the dependencies, then it would come later or maybe earlier??? The real requirement is

Re: [fpc-pascal] Lazarus complains that it cannot find a dependency, why?

2020-09-01 Thread Bo Berglund via fpc-pascal
On Wed, 02 Sep 2020 00:34:23 +0200, Tomas Hajny via fpc-pascal wrote: >On 2020-09-02 00:21, Bo Berglund via fpc-pascal wrote: > > . > . >> Strange because I have read that cthreads must be first in uses in the >> lpr program files in order to make threads work. >> How could it work if I add the