Skip to content

Instantly share code, notes, and snippets.

@DevTrunk
Created June 5, 2021 04:36
Show Gist options
  • Star 8 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save DevTrunk/2ade37348d580d97618679f22533390e to your computer and use it in GitHub Desktop.
Save DevTrunk/2ade37348d580d97618679f22533390e to your computer and use it in GitHub Desktop.
Two scripts for Windows and Linux to install aseprite
#!/bin/bash
(
ABSPATH=$(readlink -f $0)
ABSDIR=$(dirname $ABSPATH)
echo "Download and install all necesarry things"
sudo apt-get install -y curl g++ cmake ninja-build libx11-dev libxcursor-dev libxi-dev libgl1-mesa-dev libfontconfig1-dev
curl -L -o skia.zip https://github.com/aseprite/skia/releases/download/m81-b607b32047/Skia-Linux-Release-x64.zip
unzip -d ${ABSDIR}/skia skia.zip
git clone --recursive https://github.com/aseprite/aseprite.git
echo "Compiling aseprite"
cd aseprite || (echo "aseprite not downloaded"; exit 1)
mkdir build
cd build || (echo "mkdir failed"; exit 1)
cmake \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DLAF_BACKEND=skia \
-DSKIA_DIR=${ABSDIR}/skia \
-DSKIA_LIBRARY_DIR=${ABSDIR}/skia/out/Release-x64 \
-DSKIA_LIBRARY=${ABSDIR}/skia/out/Release-x64/libskia.a \
-G Ninja \
..
ninja aseprite
)
SET mypath=%~dp0
vs_Community.exe --installPath "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community" ^
--add Microsoft.VisualStudio.Workload.CoreEditor ^
--add Microsoft.VisualStudio.Workload.NativeDesktop ^
--add Microsoft.VisualStudio.Component.VC.CMake.Project ^
--passive --norestart ^
--includeRecommended ^
--wait
curl -L -o skia.zip https://github.com/aseprite/skia/releases/download/m81-b607b32047/Skia-Windows-Release-x64.zip
mkdir skia
tar -xf skia.zip -C skia
curl -L -o ninja.zip https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip
tar -xf ninja.zip
git clone --recursive https://github.com/aseprite/aseprite.git
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\Tools\VsDevCmd.bat" -arch=x64
cd aseprite
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ^
-DLAF_BACKEND=skia -DSKIA_DIR="%mypath%skia" ^
-DSKIA_LIBRARY_DIR="%mypath%skia\out\Release-x64" ^
-DSKIA_LIBRARY="%mypath%skia\out\Release-x64\skia.lib" -G Ninja ..
%mypath%ninja aseprite
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment