2024-05-07 08:02:50 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
stdenv,
|
|
|
|
fetchurl,
|
|
|
|
unzip,
|
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
|
|
|
bits = if stdenv.hostPlatform.is64bit then "x64" else "ia32";
|
2024-10-27 21:04:05 +00:00
|
|
|
version = "0.93.0";
|
2024-05-07 08:02:50 +00:00
|
|
|
in
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
pname = "nwjs-ffmpeg-prebuilt";
|
|
|
|
inherit version;
|
|
|
|
|
|
|
|
src =
|
|
|
|
let
|
|
|
|
hashes = {
|
2024-10-27 21:04:05 +00:00
|
|
|
"x64" = "sha256-8FcoZ9pN/FKun3QuoFSKKreKCfj8tp2IgkRiDajT5ms=";
|
|
|
|
"ia32" = "sha256-8FcoZ9pN/FKun3QuoFSKKreKCfj8tp2IgkRiDajT5ms=";
|
2024-05-07 08:02:50 +00:00
|
|
|
};
|
|
|
|
in
|
|
|
|
fetchurl {
|
|
|
|
url = "https://github.com/nwjs-ffmpeg-prebuilt/nwjs-ffmpeg-prebuilt/releases/download/${version}/${version}-linux-${bits}.zip";
|
|
|
|
hash = hashes.${bits};
|
|
|
|
};
|
|
|
|
sourceRoot = ".";
|
|
|
|
|
|
|
|
nativeBuildInputs = [ unzip ];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
mkdir -p $out/lib
|
|
|
|
cp -R libffmpeg.so $out/lib/
|
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "An app runtime based on Chromium and node.js";
|
|
|
|
homepage = "https://nwjs.io/";
|
|
|
|
platforms = [
|
|
|
|
"i686-linux"
|
|
|
|
"x86_64-linux"
|
|
|
|
];
|
|
|
|
sourceProvenance = [ lib.sourceTypes.binaryNativeCode ];
|
|
|
|
maintainers = with lib.maintainers; [
|
|
|
|
ilya-epifanov
|
|
|
|
mikaelfangel
|
|
|
|
];
|
|
|
|
license = lib.licenses.gpl2Plus;
|
|
|
|
};
|
|
|
|
}
|