2016-12-25 11:32:24 +00:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
|
|
|
, fetchurl
|
|
|
|
, alsaLib
|
|
|
|
, atk
|
|
|
|
, bzip2
|
|
|
|
, cairo
|
|
|
|
, curl
|
|
|
|
, expat
|
|
|
|
, fontconfig
|
|
|
|
, freetype
|
|
|
|
, gdk_pixbuf
|
|
|
|
, glib
|
|
|
|
, glibc
|
|
|
|
, graphite2
|
|
|
|
, gtk2
|
|
|
|
, harfbuzz
|
|
|
|
, libICE
|
|
|
|
, libSM
|
|
|
|
, libX11
|
|
|
|
, libXau
|
|
|
|
, libXcomposite
|
|
|
|
, libXcursor
|
|
|
|
, libXdamage
|
|
|
|
, libXdmcp
|
|
|
|
, libXext
|
|
|
|
, libXfixes
|
|
|
|
, libXi
|
|
|
|
, libXinerama
|
|
|
|
, libXrandr
|
|
|
|
, libXrender
|
|
|
|
, libXt
|
|
|
|
, libXxf86vm
|
|
|
|
, libdrm
|
|
|
|
, libffi
|
|
|
|
, libpng
|
|
|
|
, libvdpau
|
|
|
|
, libxcb
|
|
|
|
, libxshmfence
|
|
|
|
, nspr
|
|
|
|
, nss
|
|
|
|
, pango
|
|
|
|
, pcre
|
|
|
|
, pixman
|
|
|
|
, zlib
|
|
|
|
, unzip
|
|
|
|
, debug ? false
|
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
|
|
|
arch =
|
2017-04-14 10:42:32 +01:00
|
|
|
if stdenv.system == "x86_64-linux" then
|
2016-12-25 11:32:24 +00:00
|
|
|
"x86_64"
|
|
|
|
else throw "Flash Player is not supported on this platform";
|
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "flashplayer-standalone-${version}";
|
2017-04-14 10:42:32 +01:00
|
|
|
version = "25.0.0.148";
|
2016-12-25 11:32:24 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url =
|
|
|
|
if debug then
|
2017-03-14 15:02:08 +00:00
|
|
|
"https://fpdownload.macromedia.com/pub/flashplayer/updaters/25/flash_player_sa_linux_debug.x86_64.tar.gz"
|
2016-12-25 11:32:24 +00:00
|
|
|
else
|
2017-03-14 15:02:08 +00:00
|
|
|
"https://fpdownload.macromedia.com/pub/flashplayer/updaters/25/flash_player_sa_linux.x86_64.tar.gz";
|
2016-12-25 11:32:24 +00:00
|
|
|
sha256 =
|
|
|
|
if debug then
|
2017-04-14 10:42:32 +01:00
|
|
|
"1pkzpip8d3m92kyzap00xxq40yilgmaqnc47nak3i7gnbic8fa2r"
|
2016-12-25 11:32:24 +00:00
|
|
|
else
|
2017-04-14 10:42:32 +01:00
|
|
|
"0xxsbxnkf9xnljy6sn61jqx9xd1w0lm5mbw4ca7xk5rkc84ik91z";
|
2016-12-25 11:32:24 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ unzip ];
|
|
|
|
|
|
|
|
sourceRoot = ".";
|
|
|
|
|
|
|
|
dontStrip = true;
|
|
|
|
dontPatchELF = true;
|
|
|
|
|
|
|
|
preferLocalBuild = true;
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
cp -pv flashplayer${lib.optionalString debug "debugger"} $out/bin
|
|
|
|
|
|
|
|
patchelf \
|
|
|
|
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
|
|
|
|
--set-rpath "$rpath" \
|
|
|
|
$out/bin/flashplayer${lib.optionalString debug "debugger"}
|
|
|
|
'';
|
|
|
|
|
|
|
|
rpath = lib.makeLibraryPath
|
|
|
|
[ stdenv.cc.cc
|
|
|
|
alsaLib atk bzip2 cairo curl expat fontconfig freetype gdk_pixbuf glib
|
|
|
|
glibc graphite2 gtk2 harfbuzz libICE libSM libX11 libXau libXcomposite
|
|
|
|
libXcursor libXdamage libXdmcp libXext libXfixes libXi libXinerama
|
|
|
|
libXrandr libXrender libXt libXxf86vm libdrm libffi libpng libvdpau
|
|
|
|
libxcb libxshmfence nspr nss pango pcre pixman zlib
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Adobe Flash Player standalone executable";
|
|
|
|
homepage = https://www.adobe.com/support/flashplayer/debug_downloads.html;
|
|
|
|
license = stdenv.lib.licenses.unfree;
|
|
|
|
maintainers = [];
|
|
|
|
platforms = [ "x86_64-linux" ];
|
|
|
|
};
|
|
|
|
}
|