Skip to content

Instantly share code, notes, and snippets.

Last active November 28, 2023 14:28
  • Star 20 You must be signed in to star a gist
  • Fork 6 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
This script automates the setup of Ubuntu 22.04 LTS for Delphi 11.3 Alexandria

Settings up Ubuntu LTS for Delphi 11.3 Alexandria

Short link for this GIST

The below Bash script works with Ubuntu 20.04 LTS and 22.04 LTS, on WSL2, VM, or hardware install.

Installing WSL2 on Windows 11

Microsoft has a full article with all the details. This is a summary for quick reference.

On Windows you need to do this from an elevated (administrator) command prompt or PowerShell window. Easiest way is Win+X,A.

wsl --install -d Ubuntu

Once your machine has finished rebooting, installation will continue and you will be asked to enter a username and password. This will be your Linux credential for the Ubuntu distribution.

Start Ubuntu from the start menu, or from the terminal by typing ubuntu

Then run the following script

curl -L | bash

If you don't have curl installed then run sudo apt install curl -y first

# Download and execute with the following:
# curl -L | bash
echo "Updating the local package directory"
sudo apt update
echo "Upgrading any outdated pacakges"
sudo apt full-upgrade -y
echo "Install new packages necessary for Delphi & FMXLinux"
sudo apt install joe python3 libpython3-dev wget p7zip-full curl libgtk-3-dev openssh-server build-essential zlib1g-dev libgtk-3-dev libcurl4-gnutls-dev libncurses5 xorg libgl1-mesa-dev libosmesa-dev libgtk-3-bin -y
echo "Clean-up unused packages"
sudo apt autoremove -y
cd ~
echo "Downloading Linux PAServer for Alexandria 11.3 (22.0)"
echo "Setting up directories to extract PA Server into"
mkdir PAServer
mkdir PAServer/22.0
rm PAServer/22.0/*
tar xvf LinuxPAServer22.0.tar.gz -C PAServer/22.0 --strip-components=1
# This fixes the Python 3.6 dependency
ln -sf `ls -1 /usr/lib/x86_64-linux-gnu/libpython3.*.so.1.0 | tail -1` ~/PAServer/22.0/lldb/lib/
rm LinuxPAServer22.0.tar.gz
echo \#\!\/bin\/bash >
echo # >>
echo ~/PAServer/22.0/paserver >>
chmod +x
echo "-----------------------------------"
echo " To launch PAServer type ~/"
echo "-----------------------------------"
# ~/
Copy link

Awesome script. Tested on Ubuntu 22.04 LTS. It works perfectly!

Copy link

Jedt3D commented May 7, 2023

Thanks! Test on Elementary OS 7 (based on Ubuntu 22.04) it is working too.


  • Embarcadero's URL for PA Server
  • I've managed to install some dependencies for TMS FNC to use with FMX Linux too. According to their installation guide, we should install this packages.
sudo apt install joe wget p7zip-full curl openssh-server build-essential zlib1g-dev libcurl4-gnutls-dev libncurses5
sudo apt-get install zlib1g-dev
sudo apt install libgl1-mesa-glx libglu1-mesa libgtk-3-common libgstreamer1.0-0 libgstreamer-plugins-base1.0-0
sudo apt install libwebkit2gtk-4.0-dev

Copy link

Jedt3D commented Jun 29, 2023

@jimmckeeth I've tested on LinuxMint 21.1 cinnamon today (June 29, 2023).
It's working well also.
Small typos in the scripts

  1. libgtk-3-dev appears two times in line 11
  2. echo # https://do... should be echo \# https://do...

Thank you for your Linux support!

Copy link

Vizit0r commented Jul 14, 2023

after updating to latest Delphi (28.0.48361.3236) PAServer also was updated to version, but script downloads from server the old version (, which is incompatible with newest.
So, i have to use script, than manually change all paserver files, and use chmod +x (recursively).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment