Configure Delphi and RedHat or Ubuntu for Linux development.

Image courtesy of Jim McKeeth.

33 Responses

  1. Ivan Revelli says:

    Hi Craig,
    compliments for the post, i use fmxLinux with 10.4 and it’s very cool to build really cool applications, servers, kiosk and so on.
    But i have a trouble in debug mode, when i deploy to linux my scratchdir will always empty before deploy and i lose all associated files, is possible to avoid empty the scratch dir before deploy?


  2. Fr0sT-Brutal says:

    Thanks for the instruction though I managed to set things up with official Emba manual – but for compilation only. I use 10.3 Rio.
    For actual running I was getting error “PAServer-20.0/linuxgdb: error while loading shared libraries: cannot open shared object file: No such file or directory” so I had to install libncurses. I grabbed all versions at once with “sudo apt-get install libncurses*”; I saw people solving the issue with making symlinks to existing libs or installing the exact versions but this was the easiest solution for me.

  3. Hello Craig,

    We have been using Delphi versions 7 and 10. We have recently switched to 64-bit with Embarcadero Delphi 10.2, which is also available for a Linux implementation. Our goal is to integrate our legacy Delphi code and call a DLL in C in the Linux operating system. Specifically, we want to integrate the PETSc library, which is a scientific linear algebra package. We have done DLL integrations in Windows, but never done it from Linux to Linux, especially with Delphi. We wonder whether you had any advice on calling a DLL in 64-bit Delphi from Linux into a Linux DLL and whether you would be able to assist us to perform the integration between Delphi and PETSc.

  4. Excellent tutorial Craig! is there a tutorial for Datasnap server in console mode for linux?, thanks in advance.

    • I did cover WebBroker for Linux in a CodeRage / Webinar session, which should be more or less the same for Datasnap (datasnap is WebBroker plus). I’ll see if I can find a link.

      • Hi Craig,

        I tried to compile a simple datasnapo example from embarcadero and I got the following error message “[DCC Error] E2597 C:\Program Files (x86)\Embarcadero\Studio\19.0\bin\ld-linux.exe: error: cannot find -lgcc_s”. I have a virtual machine running on azure Ubuntu 16.04.3 LTS, paserver running and tested, Win 7 Pro 64 running on virtual box and delphi tokio 10.2.2. Do I need to install a lgcc_s library on windows? thanks in advance.

  5. Hi Craig,

    I have released my newest Linux (GUI) application called i3DConverter.
    (I made it using Rad Studio Tokyo + FMXLinux+ TMS FMX UI Pack.)

    It is a powerful 3D polygon model converter, and also an interactive 3D model viewer tool. The program supports 760 file formats.

    I have tested it on the following Linux systems:
    CentOS 7;
    Debian 9.1;
    Kali Linux 2017.2;
    Linux Mint 18.1;
    openSUSE Leap 42.2;
    Ubuntu 16.10

    I have uploaded sample 3d models (textured, textured with bone, DDM):

  6. I have used your very detailed post to setup VirtualBox and install Ubuntu under VirtualBox on my Win7 64bit system.

    I have installed the Ubuntu without any problems, but I could not deploy PAServer to Ubuntu.
    I ran the ifconfig command to get the Ubuntu’s IP address ( and I did try to use the WinCP with the correct IP address. After the ’Searching for host…’ window I got the following error message: ’Network error: Connection to „” refused. The server rejected SFTP connection, but it listens to for FTP connections.

    I did try to use the Total Commander’s SFTP plugin without success.

    I can ping the Ubuntu’s IP address from the Win7 side, but I can’t imagine what is the problem on the Ubuntu’s side.

    I used the followings to ’deploy’ and install the PAServer:

    I uploaded the LinuxPAServer19.0.tar.gz file to my web page and I downloaded it using the Ubuntu’s FireFox browser. I installed the Double Commander under Ubuntu and I extracted the LinuxPAServer19.0.tar.gz file and I run the paserver app in the terminal window.

    • The first things which spring to mind are:
      (Usually the defaults prevent these issues, but it’s possible something different happened during your install)

      1) Do you have SSH installed? – try typing “sudo apt-get install openssh-server” at the command line, it’ll tell you either that it’s already installed (and that zero packages will be installed) or else it should install SSH. SSH is required for winSCP to connect.

      2) There may be a firewall issue? Try “sudo ufw allow 22” at the command line to open port 22 on the firewall for SSH.

      I would also guess that it’s possible that the networking settings which worked for me may not work for everyone? i.e. different network cards having different drivers, may not support the bridged connection. I’ve not come across this problem myself, but can’t rule it out.

      If you have access to a web server, you could upload the PAServer tar file to your web site, and then use the wget command in linux to download it. Assuming there is no firewall, and that networking is functioning as it should, you’ll then be able to connect to PA server. You also mentioned FTP access? If you have FTP it’s as good a way as any to transfer the PAServer file.

  7. says:

    I’m having the following error while compiling:

    [Ed Craig Chapman: I removed the error post because it’s very long. See follow up comment..]

    • I removed the error output because it’s very long.

      I am forwarding the error messages to our engineering team to take a look at, from what I can see there are missing dependencies on your system which may be down to a broken install or failed SDK import. I will connect with you via email (the address you gave to post this comment) regarding any follow up from our engineering team.

  8. says:

    Simple hello world app doesn’t compile as it doesn’t find the libs.
    Obviously, RHEL and Ubuntu have files in the *.5.* shape, Fedora25 and CentOS7 are *.6.*
    So I wanted to know whether something was wrong on my side.
    The hello world sample compiles with 137 errors, each time, on both platforms.

    • Unfortunately, my claim that it ought to work on other distributions may have been optimistic.
      I am experimenting with this to see if I can make any progress, however, as you say there are differing library versions which may prohibit this from working.

  9. says:

    Hi Craig,
    Did you try with either CentOS7 or Fedora25?
    Just plain doesn’t work…

  1. 2017-02-15

    […] Configure Delphi and RedHat or Ubuntu for Linux development […]

  2. 2017-02-28

    […] Also see my earlier step-by-step guide to configuring either a Red Hat Enterprise server, or an Ubun… […]

  3. 2017-03-25

    […] However, things aren’t that difficult.  To get started, I recommend that you read and follow this excellent (and startlingly detailed) blog post by Craig Chapman.  It should get your Linux all set up and ready to run.  You’ll even get a sample […]

  4. 2017-03-25

    […] ver el siguiente blogs de Chapman World en Inglés relacionado con este mismo […]

  5. 2017-04-05
  6. 2017-04-06
  7. 2017-09-09

    […] applications into a linux server. A very nice set-up guide for the linux environment can he found here; instead if you want to be able to use firemonkey and target a linux dekstop client (Ubuntu 16.04 […]

  8. 2018-10-10

    […] [ Continue Reading ] […]

  9. 2018-10-22

    […] Craig Chapman already described the process of installing Ubuntu and Red Hat Enterprise distributions into an Oracle's VirtualBox. In this post I'm going to focus in Ubuntu and use VMWare that is a different virtualisation technology. […]

  10. 2019-02-01

    […] projects for these Linux distributions. The official documentation is very good example but, also, this article has a very detailed guide on the […]

  11. 2019-09-04
  12. 2020-08-18

    […] best source of information how to configure Ubuntu for Delphi development is Craig Chapman’s blog post and last week’s “Delphi Linux Bootcamp” webinar with Craig. The only […]

  13. 2020-08-18

    […] Craig Chapman already described the process of installing Ubuntu and Red Hat Enterprise distributions into an Oracle’s VirtualBox. In this post I’m going to focus in Ubuntu and use VMWare that is a different virtualisation technology. […]

  14. 2020-08-18

    […] Craig Chapman already described the process of installing Ubuntu and Red Hat Enterprise distributions into an Oracle’s VirtualBox. In this post I’m going to focus in Ubuntu and use VMWare that is a different virtualisation technology. […]

  15. 2020-08-18

    […] [ Continue Reading ] […]

Leave a Reply