setting up the freepascal compiler on SFOS
this is basically very easy:
you just have to download the precompiled install package of fpc and run the included install.sh
after unpacking. You do not need root privileges as you are just able to use your /home/nemo directory.
After this is done, you can start compiling a helloworld :-)
in complexity nothing compared to old meemo days...
unfortunately there is no easy-to-use way to use qt-infrastructure in SFOS as in Maemo:
you could see this as a starting point as V2.6 Alpha implements qt5 bindings (however, qt5.1.1 and not the needed 5.2 for sailfish and you cannot use X-related qt Features as there is no X in SFOS).
edit 20160603: the precompiled install package described above is a version of fpc-2.6.4 softfloat-only, so if you want to try out the new Version 3.0.0 for ARM hardfloat, you'll have to use the binaries in this repo. It works as noted here. Installing is possible (I will not encourage the reader unless he/she knows exactly what is happening here - proceed on your own risk!) after converting the _armhf.deb packages with alien-script to _armhf.rpm (note: switch off converting in-package scripts/macros as they will fail) they could be installed via frightening rpm -i --ignorearch --noscripts package-name.rpm
.
After that you'll have to create a symbolic link from /usr/bin/as
to /usr/bin/arm-linux-as
and change paths in the config file .fpc.cfg
in your home-directory if you did install fpc-2.6.4 softfloat previously.
Then you are done and able to use fpc as high-level language compiler with hard-float (up to VFPV3-D16) support!
There is a (fedora)rpm binary package available here that claims to be armv7hl(-d32) (which Jolla1 users are able to run, Jolla C users not), but trying to use hardfloat by -Cfvfpv3
compiler option - which would enable use of vfpv3-d32 - as well as -Cfvfpv3_d16
is returning an error: Trying to use a unit which was compiled with a different FPU mode
indicating usage of fpu emulation mode for this fpc arm eabi version (What a pity! Avoidance of alien-script and rpm -i --ignorearch would be great...).
Thanks for sharing @lpr! You might also be interested and join our scientific application thread here: https://together.jolla.com/question/121144/scientific-applications-in-jolla-sailfishos
lakutalo ( 2016-05-12 21:19:08 +0200 )editBrilliant - totally forgot about Freepascal. Last used it on OS/2. Have to give this a go.
flywheel ( 2016-06-04 15:03:37 +0200 )edit