Skip to content

Instantly share code, notes, and snippets.

@Mitra-88
Forked from veganaize/Aseprite-build-linux.md
Last active March 15, 2025 12:44
Show Gist options
  • Save Mitra-88/4ae1bff376df819391e5b74a31a9e474 to your computer and use it in GitHub Desktop.
Save Mitra-88/4ae1bff376df819391e5b74a31a9e474 to your computer and use it in GitHub Desktop.
Compile Aseprite from source code for GNU/Linux

Prerequisites

Install dependencies

on Ubuntu/Debian:

sudo apt install g++ clang libc++-dev libc++abi-dev cmake ninja-build libx11-dev libxcursor-dev libxi-dev libgl1-mesa-dev libfontconfig1-dev curl unzip -y

On Fedora:

sudo dnf install gcc-c++ clang libcxx-devel cmake ninja-build libX11-devel libXcursor-devel libXi-devel mesa-libGL-devel fontconfig-devel curl unzip -y

On Arch Linux:

sudo pacman -S gcc clang libc++ cmake ninja libx11 libxcursor mesa-libgl fontconfig curl unzip --noconfirm

On OpenSUSE:

sudo zypper -n install gcc-c++ clang libc++-devel libc++abi-devel cmake ninja libX11-devel libXcursor-devel libXi-devel Mesa-libGL-devel fontconfig-devel unzip curl

Create folders

mkdir -p ~/src/aseprite/build ~/src/deps/skia

Download & extract Aseprite source

cd ~/src/aseprite
curl --proto '=https' --tlsv1.3 -LsSf https://github.com/aseprite/aseprite/releases/download/v1.3.9.1/Aseprite-v1.3.9.1-Source.zip
unzip Aseprite-v1.3.9.1-Source.zip

Download & extract Skia

cd ~/src/deps/skia
curl --proto '=https' --tlsv1.3 -LsSf https://github.com/aseprite/skia/releases/download/m102-861e4743af/Skia-Linux-Release-x64-libc++.zip
unzip Skia-Linux-Release-x64-libc++.zip

Build Aseprite

cd ~/src/aseprite/build
export CC=clang
export CXX=clang++
cmake \
  -DCMAKE_BUILD_TYPE=RelWithDebInfo \
  -DCMAKE_CXX_FLAGS:STRING=--stdlib=libc++ \
  -DCMAKE_EXE_LINKER_FLAGS:STRING=--stdlib=libc++ \
  -DLAF_BACKEND=skia \
  -DSKIA_DIR=$HOME/src/deps/skia \
  -DSKIA_LIBRARY_DIR=$HOME/src/deps/skia/out/Release-x64 \
  -DSKIA_LIBRARY=$HOME/src/deps/skia/out/Release-x64/libskia.a \
  -G Ninja ..
ninja aseprite

Install program

mkdir ~/opt
mv -T bin ~/opt/aseprite

To run Aseprite, execute the following command:

~/opt/aseprite/aseprite

Tested With Aseprite v1.3.9.1

Please remember to support the creators of Aseprite. Only use this method to try the program or if you don't have access to funds or a credit card :)

@Linkspeedrunner
Copy link

i not have a credit card,tanks you ;)

@Mitra-88
Copy link
Author

i not have a credit card,tanks you ;)

np :)

@back2Lobby
Copy link

back2Lobby commented Aug 25, 2024

Adding Aseprite Desktop Entry (with icon) for Ubuntu:

First add your executable to the path with:

sudo ln -s ~/opt/aseprite/aseprite /usr/local/bin/aseprite

Now you should be able to open aseprite from anywhere using command asperite.

Create a file in /usr/share/applications as aseprite.desktop with following content.

[Desktop Entry]
Type=Application
Name=Aseprite
GenericName=Sprite Editor
Comment=Animated sprite editor & pixel art tool
Icon=<aseprite-icon>
Categories=Graphics;2DGraphics;RasterGraphics
Exec=aseprite %U
TryExec=aseprite
Terminal=false
StartupNotify=false
StartupWMClass=Aseprite
MimeType=image/bmp;image/gif;image/jpeg;image/png;image/x-pcx;image/x-tga;image/vnd.microsoft.icon;video/x-flic;image/webp;image/x-aseprite;

Replace <aseprite-icon> with a path to any png aseprite icon. You can get it from any of the following sources:

  • Get it directory from the repo source you downloaded. At ~/src/aseprite/data/icons/ase256.png. You can copy it to the ~/opt/aseprite so all the resources are at same place.
  • After building (completing full tutorial) you can also get it from the ~/opt/aseprite/data/icons/ase256.png
  • Or download any png icon from internet, place it anywhere.

Note: Use absolute path to specify icons. Avoid using ~ in the path. Corrent Example is: /home/yourname/opt/aseprite/data/icons/ase256.png

Now update the entries using update-desktop-database ~/.local/share/applications/

Note: If you still see a desktop entry for Aseprite with settings icon or an empty icon on the entry, then most likely its an issue with your icon path.

@Mitra-88
Copy link
Author

Adding Aseprite Desktop Entry (with icon) for Ubuntu:

First add your executable to the path with:

sudo ln -s ~/opt/aseprite/aseprite /usr/local/bin/aseprite

Create a file in /usr/share/applications as aseprite.desktop with following content.

[Desktop Entry]
Type=Application
Name=Aseprite
GenericName=Sprite Editor
Comment=Animated sprite editor & pixel art tool
Icon=<aseprite-icon>
Categories=Graphics;2DGraphics;RasterGraphics
Exec=aseprite %U
TryExec=aseprite
Terminal=false
StartupNotify=false
StartupWMClass=Aseprite
MimeType=image/bmp;image/gif;image/jpeg;image/png;image/x-pcx;image/x-tga;image/vnd.microsoft.icon;video/x-flic;image/webp;image/x-aseprite;

Replace <aseprite-icon> with a path to any png aseprite icon. You can get it from any of the following sources:

  • Get it directory from the repo source you downloaded. At ~/src/aseprite/data/icons/ase256.png. You can copy it to the ~/opt/aseprite so all the resources are at same place.
  • After building (completing full tutorial) you can also get it from the ~/opt/aseprite/data/icons/ase256.png
  • Or download any png icon from internet, place it anywhere.

Note: Use absolute path to specify icons. Avoid using ~ in the path. Corrent Example is: /home/yourname/opt/aseprite/data/icons/ase256.png

Now update the entries using update-desktop-database ~/.local/share/applications/

Note: If you still see a desktop entry for Aseprite with settings icon or not empty icon on the entry, then most likely its an issue with your icon path.

thank you :) im not that good with linux :)

@vonMort
Copy link

vonMort commented Aug 25, 2024

Adding Aseprite Desktop Entry (with icon) for Ubuntu:

...many blabla...

Just to mention it, exact these steps work on all ubuntu based dists including pop_os

@back2Lobby
Copy link

back2Lobby commented Aug 26, 2024

Just to mention it, exact these steps work on all ubuntu based dists including pop_os

That's good to know, I've only used a few random distros other than ubuntu so I didn't have a clue lol.

@Linkspeedrunner
Copy link

just navigate to the folther and make a desktop entry with the file explorer :/

@Linkspeedrunner
Copy link

...

@Linkspeedrunner
Copy link

If you think you are pro, use the shortcut tutorial

@Mitra-88
Copy link
Author

just navigate to the folther and make a desktop entry with the file explorer :/

im not that good with linux :(

@aurora-1-2-3
Copy link

thanks, but how do i pin it to taskbar and make a desktop entry for aseprite

@Mitra-88
Copy link
Author

thanks, but how do i pin it to taskbar and make a desktop entry for aseprite

well im not quite sure myself lol, check @back2Lobby's reply it might help you

@aurora-1-2-3
Copy link

Sorry, I didn't said but I am using fedora with KDE plasma

@aurora-1-2-3
Copy link

aurora-1-2-3 commented Oct 18, 2024

Shortcut for Fedora

  1. Make a txt file named aseprite.desktop on the dektop

  2. Open the .desktop file with a text editor

3.Paste the code

#!/usr/bin/env xdg-open
[Desktop Entry]
Name=Aseprite
Exec=~/opt/aseprite/aseprite %U
Terminal=false
Type=Application
GenericName=Sprite Editor
Icon=~/opt/aseprite/data/icons/ase.ico
StartupWMClass=Aseprite
Comment=Animated sprite editor & pixel art tool
Categories=Graphics;2DGraphics;RasterGraphics
StartupNotify=false

and save. You should now have a desktop icon

  1. Go to ~/.local/share/applications and copy paste the .desktop file

  2. Now you should have an Aseprite shortcut on the desktop and the application menu, like this

image

@aurora-1-2-3
Copy link

aurora-1-2-3 commented Oct 18, 2024

Sorry, I didn't said but I am using fedora with KDE plasma

image

@Mitra-88
Copy link
Author

Sorry, I didn't said but I am using fedora with KDE plasma

image

i didnt see that sorry 😭 i dont know im not that good with linux vro 😭

@aurora-1-2-3
Copy link

lmao

@Mitra-88
Copy link
Author

lmao

well thank you for sharing it tho :)

@aurora-1-2-3
Copy link

np

@Observer55
Copy link

Hello, I am using ZOrinOS 17.2 (as a newbie on linux) and I think I don't have the latest ubuntu version, I think I am using Ubuntu 22.04. Is it a big problem to continue with that?

@aurora-1-2-3
Copy link

it shouldnt be

@Observer55
Copy link

Thank you

it shouldnt be

@Mitra-88
Copy link
Author

Hello, I am using ZOrinOS 17.2 (as a newbie on linux) and I think I don't have the latest ubuntu version, I think I am using Ubuntu 22.04. Is it a big problem to continue with that?

no im only listing the latest versions to avoid problems (22.04 should work)

@aurora-1-2-3
Copy link

aurora-1-2-3 commented Mar 11, 2025

when will the guide be updated for the latest version

@Mitra-88
Copy link
Author

when will the guide be updated for the latest version

will do some time later, u dont for it to be updated just change the urls to the latest version

@aurora-1-2-3
Copy link

tried, didnt work. Got stuck at the last part ninja aseprite

@Mitra-88
Copy link
Author

tried, didnt work. Got stuck at the last part ninja aseprite

same maybe its because im using arch ill try it on ubnutu, older releases seems to be working just fine

@Mitra-88
Copy link
Author

Mitra-88 commented Mar 13, 2025

tried, didnt work. Got stuck at the last part ninja aseprite

okay i tried Skia-m124 i was able to compile it but it fails at the end so its pointless, i followed the official guide and it seems like im not the only one having this issue hopefully it gets fixed soon

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