A low-level tool to generate an AppImage from an existing AppDir
  • C 83.9%
  • C++ 6.9%
  • Shell 5.5%
  • CMake 3.7%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Gianluca Renzi 11d54c9acc elf.c: read the section headers in the byte order of the ELF file
appimage_get_elf_section_offset_and_length() read e_shoff, e_shnum,
e_shstrndx, sh_name, sh_offset and sh_size as they are in the file: with the
runtime of a big endian architecture (ppc64) on a little endian machine, it
got wrong offsets and read past the mapping, so appimagetool crashed
(segmentation fault) when embedding the update information or the MD5
digest. They now go through file16/32/64_to_cpu(), which know the byte order
from e_ident; open() and mmap() failures are reported instead of crashing.

read_elf32() converted the 32 bit sh_offset and sh_size with
file64_to_cpu(): file32_to_cpu() now.
2026-11-06 01:46:21 +01:00
.github Bump actions/download-artifact from 4 to 8 2026-11-01 21:13:26 +01:00
ci Revert "Use Debian's zsync patches" 2025-03-06 02:07:03 +01:00
resources First call readlink on argument 0 and then dirname (#110) 2025-11-18 18:45:44 +01:00
src elf.c: read the section headers in the byte order of the ELF file 2026-11-06 01:46:21 +01:00
.gitignore Initial commit 2023-06-26 15:29:18 +02:00
CMakeLists.txt CMake: properly look for the argp.h header file 2025-04-21 22:47:32 +02:00
LICENSE Add missing license 2025-03-11 00:32:25 +01:00
README.md Add APPIMAGETOOL_RUNTIME_FILE environment variable 2026-10-04 16:53:33 +02:00

appimagetool Downloads irc Donate

Usage

appimagetool is used to generate an AppImage from an existing AppDir. Many community-provided higher-level tools for deploying applications in AppImage format use it internally. A precompiled version can be downloaded on GitHub Releases, but in most cases you will be better off using one of the higher-level tools instead of using appimagetool directly.

Usage in a nutshell, assuming that you already have an AppDir in place:

ARCH=x86_64 ./appimagetool-x86_64.AppImage some.AppDir

Detailed usage:

Usage:
  appimagetool [OPTION...] SOURCE [DESTINATION] - Generate AppImages from existing AppDirs

Help Options:
  -h, --help                  Show help options

Application Options:
  -l, --list                  List files in SOURCE AppImage
  -u, --updateinformation     Embed update information STRING; if zsyncmake is installed, generate zsync file
  -g, --guess                 Guess update information based on environment variables set by common CI systems (GitHub actions, GitLab CI)
  --version                   Show version number
  -v, --verbose               Produce verbose output
  -s, --sign                  Sign with gpg[2]
  --comp                      Squashfs compression
  -n, --no-appstream          Do not check AppStream metadata
  --exclude-file              Uses given file as exclude file for mksquashfs, in addition to .appimageignore.
  --runtime-file              Runtime file to use
  --sign-key                  Key ID to use for gpg[2] signatures
  --sign-args                 Extra arguments to use when signing with gpg[2]

Environment variables

Some of the parameters above can alternatively be specified as environment variables. Also, some additional environment variables are available, too.

  • ARCH: Needs to be set whenever appimagetool cannot automatically determine the architecture of the binaries inside the AppDir to choose a suitable runtime (e.g., when binaries for multiple architectures or just shell scripts are contained in there).
  • APPIMAGETOOL_APP_NAME: If no destination is set by the user, appimagetool automatically generates a suitable output filename, using the root desktop entry's Name field. With this environment variable, this value can be set explicitly by the user.
  • APPIMAGETOOL_SIGN_PASSPHRASE: If the --sign-key is encrypted and requires a passphrase to be used for signing (and, for some reason, GnuPG cannot be used interactively, e.g., in a CI environment), this environment variable can be used to safely pass the key.
  • APPIMAGETOOL_RUNTIME_FILE: Path to a local AppImage runtime. If --runtime-file is specified, it takes precedence over this environment variable.
  • VERSION: This value will be inserted by appimagetool into the root desktop file and (if the destination parameter is not provided by the user) in the output filename.

Building

To build for various architectures on a local machine (or on GitHub Codespaces) using Docker:

  • For 64 bit Intel, run ARCH=x86_64 bash ./ci/build-in-docker.sh
  • For 32 bit Intel, run ARCH=i686 bash ./ci/build-in-docker.sh

If you are on an Intel machine and would like to cross-compile for ARM:

  • Prepare the Docker system for cross-compiling with docker run --rm --privileged multiarch/qemu-user-static --reset -p yes, then run
  • For 64 bit ARM, run ARCH=aarch64 bash ./ci/build-in-docker.sh
  • For 32 bit ARM, run ARCH=armhf bash ./ci/build-in-docker.sh

Changelog

  • Unlike previous versions of this tool provided in the AppImageKit repository, this version downloads the latest AppImage runtime (which will become part of the AppImage) from https://github.com/AppImage/type2-runtime/releases. If you do not like this (or if your build system does not have Internet access), you can supply a locally downloaded AppImage runtime using the APPIMAGETOOL_RUNTIME_FILE environment variable or --runtime-file parameter instead.