0Pricing
Linux Server Deployment & SSH Mastery · Lesson

Building from Source and Using Snap/Flatpak

Go beyond the system package manager: compile software from source when no package exists, and use universal package formats like Snap and Flatpak to install modern applications independently of your distro's repositories.

Building from Source and Using Snap/Flatpak is a free Linux Server Deployment & SSH Mastery lesson on CoddyKit — lesson 4 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the Linux Server Deployment & SSH Mastery learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.

When the Package Manager Is Not Enough

APT and YUM cover most needs, but sometimes a tool is not packaged, is too old in the repos, or you need a specific version. In those cases you have two options:

  • Compile the software from source
  • Use a universal package format like Snap or Flatpak

This lesson covers both.

Getting Build Tools Ready

Compiling needs a toolchain: a compiler, make, and development libraries. On Debian/Ubuntu the build-essential meta-package pulls in the basics.

sudo apt install build-essential
# RHEL/Fedora:
sudo dnf groupinstall 'Development Tools'

Getting the Source Code

Source usually arrives as a compressed tarball or a git repository. Download and unpack it, then enter the directory.

wget https://example.com/tool-1.2.tar.gz
tar -xzf tool-1.2.tar.gz
cd tool-1.2

The configure / make / install Cycle

The classic GNU build process has three steps:

  • ./configure — checks your system and prepares the build
  • make — compiles the code
  • sudo make install — copies binaries into place

This pattern is decades old and still common.

./configure
make
sudo make install

Choosing an Install Prefix

By default software installs into /usr/local. You can change this with --prefix to keep it isolated, which makes cleanup easy.

Installing into your home directory avoids needing root entirely.

./configure --prefix=/opt/tool
make
sudo make install

Handling Missing Dependencies

If ./configure stops complaining about a missing library, install the matching -dev package. Development packages provide the headers source code needs to compile against.

sudo apt install libssl-dev zlib1g-dev
./configure

Uninstalling Source Builds

The downside of source installs: no automatic uninstall. If the project supports it, run make uninstall from the build directory. Otherwise an isolated --prefix lets you just delete the folder.

sudo make uninstall
# or, if you used --prefix=/opt/tool:
sudo rm -rf /opt/tool

Universal Packages: Snap

Snap packages bundle an app with its dependencies, so they run on any distro that has snapd. They auto-update and are sandboxed.

sudo snap install htop
snap list
sudo snap remove htop

Universal Packages: Flatpak

Flatpak is another universal format, popular for desktop apps and distributed via remotes like Flathub. Add the remote once, then install by application ID.

flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
flatpak install flathub org.gimp.GIMP
flatpak run org.gimp.GIMP

Choosing the Right Method

Pick the approach that fits:

  • APT/YUM — default, best integration, auto-updates
  • Snap/Flatpak — latest versions, cross-distro, sandboxed
  • Source — last resort for unpackaged or custom builds

Prefer packages; build from source only when necessary.

Best Practices

Install safely outside the package manager:

  • Always install build deps before configuring
  • Use a clean --prefix so you can remove source builds later
  • Verify download checksums or signatures
  • Prefer Snap/Flatpak over source when a maintained package exists

Quick Check

Test your installation knowledge.

Recap

You can now install software beyond the standard repos:

  • From source: ./configuremakemake install, with --prefix for isolation
  • Snap: snap install for self-contained, auto-updating apps
  • Flatpak: Flathub remotes and app IDs

Reach for these only when APT/YUM cannot deliver what you need.

Frequently asked questions

Is the “Building from Source and Using Snap/Flatpak” lesson free?

Yes — the full text of “Building from Source and Using Snap/Flatpak” is free to read here on the web, and the Linux Server Deployment & SSH Mastery course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the Linux Server Deployment & SSH Mastery course, upgrade to CoddyKit PRO.

What will I learn in “Building from Source and Using Snap/Flatpak”?

Go beyond the system package manager: compile software from source when no package exists, and use universal package formats like Snap and Flatpak to install modern applications independently of your… You practise Linux Server Deployment & SSH Mastery with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.

Do I need any experience to start Linux Server Deployment & SSH Mastery?

No prior experience is required. Linux Server Deployment & SSH Mastery on CoddyKit is structured for beginners through advanced learners; this is — lesson 4 of 4, so you can start here or from the beginning and move at your own pace.

How long does the “Building from Source and Using Snap/Flatpak” lesson take?

Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.

Can I write and run code in this Linux Server Deployment & SSH Mastery lesson?

Yes. Every Linux Server Deployment & SSH Mastery lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.

All lessons in this course

  1. APT and YUM Package Managers
  2. Installing and Updating Software
  3. Managing Software Repositories
  4. Building from Source and Using Snap/Flatpak
← Back to Linux Server Deployment & SSH Mastery