Add aarch64 typora
This commit is contained in:
parent
9412c57a05
commit
583ed20387
|
@ -44,6 +44,8 @@ in
|
||||||
|
|
||||||
discord
|
discord
|
||||||
|
|
||||||
|
typora
|
||||||
|
|
||||||
# Java & sbt
|
# Java & sbt
|
||||||
openjdk11
|
openjdk11
|
||||||
sbt
|
sbt
|
||||||
|
|
|
@ -43,6 +43,10 @@ let
|
||||||
});
|
});
|
||||||
# Zotero does not have their own aarch64-linux build
|
# Zotero does not have their own aarch64-linux build
|
||||||
zotero = final.callPackage ./packages/aarch64-linux/zotero.nix { };
|
zotero = final.callPackage ./packages/aarch64-linux/zotero.nix { };
|
||||||
|
# Typora for aarch64-linux only
|
||||||
|
typora = optionalOverride
|
||||||
|
(builtins.abort "no support for non-aarch64-linux")
|
||||||
|
(final.callPackage ./packages/aarch64-linux/typora.nix { });
|
||||||
};
|
};
|
||||||
|
|
||||||
overlay-asahi = inputs.nixos-m1.overlays.default;
|
overlay-asahi = inputs.nixos-m1.overlays.default;
|
||||||
|
|
50
packages/aarch64-linux/typora.nix
Normal file
50
packages/aarch64-linux/typora.nix
Normal file
|
@ -0,0 +1,50 @@
|
||||||
|
{ pkgs, runCommand, zstd, lib, buildFHSUserEnv }:
|
||||||
|
|
||||||
|
let
|
||||||
|
typora-tar = builtins.fetchurl {
|
||||||
|
url = "https://download.typora.io/linux/Typora-linux-arm64.tar.gz";
|
||||||
|
sha256 = "sha256:1xp25rvr8hr8b4dwb55d9229bbnpq7kd2bxvz7l3dfhn39zpxxjg";
|
||||||
|
};
|
||||||
|
|
||||||
|
typora-src = runCommand "typora-src" { } ''
|
||||||
|
mkdir -p $out
|
||||||
|
tar xvf ${typora-tar} -C $out
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
buildFHSUserEnv {
|
||||||
|
name = "typora";
|
||||||
|
targetPkgs = pkgs: with pkgs; [
|
||||||
|
glib
|
||||||
|
nss
|
||||||
|
nspr
|
||||||
|
at-spi2-atk
|
||||||
|
cups
|
||||||
|
dbus
|
||||||
|
gtk3
|
||||||
|
pango
|
||||||
|
cairo
|
||||||
|
mesa
|
||||||
|
expat
|
||||||
|
libdrm
|
||||||
|
libxkbcommon
|
||||||
|
alsa-lib
|
||||||
|
freefont_ttf
|
||||||
|
liberation_ttf
|
||||||
|
wayland
|
||||||
|
libglvnd
|
||||||
|
electron
|
||||||
|
] ++ (with pkgs.xorg; [
|
||||||
|
libX11
|
||||||
|
libXcomposite
|
||||||
|
libXdamage
|
||||||
|
libXext
|
||||||
|
libXfixes
|
||||||
|
libXrandr
|
||||||
|
libxcb
|
||||||
|
]);
|
||||||
|
extraBuildCommands = ''
|
||||||
|
# ldd ${typora-src}/bin/Typora-linux-arm64/Typora && false
|
||||||
|
'';
|
||||||
|
# runScript = "${typora-src}/bin/Typora-linux-arm64/Typora --enable-features=UseOzonePlatform --ozone-platform=wayland";
|
||||||
|
runScript = "electron ${typora-src}/bin/Typora-linux-arm64/resources/app.asar";
|
||||||
|
}
|
Loading…
Reference in a new issue