probably relates to openSSL and your use of FPC304.
Most sites you connect to require thee standards in openssl3 as a minium, FPC304 and its associated apps were releeased before ssl3 existed.
Why are you using such a old compiler ?
In practice, you need to use FPC322 AND install the libssl3 dev libraries or use FPC-Fixes.
I don't think FPC304 will build FPC-Fixes, so perhaps its going to be 304->322->fixes I am afraid. See -
If you want fixes, sensible choice, you must build it from source, so, may as well build both from source. But if happy with fpc322, just download and install the Tar, very quick and easy.
Davo
EDIT - I strongly suggest you install your new FPC in user space, do not mess with the copies up in /usr/bin and /lib installed by apt. And add a line in your .bashrc that adds a path to the new fpc bin directory. eg
FPCV='fpc-3.2.2'
export PATH="$HOME/bin/FPC/$FPCV/bin":"$PATH"