flashplayer: 11.2.202.644 -> 24.0.0.186 [Critical security fix] (#21337)

* flashplayer: 11.2.202.644 -> 24.0.0.186

* flashplayer: add debug version

* flashplayer-standalone: 11.2.202.644 -> 24.0.0.186
This commit is contained in:
taku0 2016-12-25 20:32:24 +09:00 committed by zimbatm
parent 4383aa26f2
commit f3287b0aa5
3 changed files with 264 additions and 4 deletions

View File

@ -0,0 +1,146 @@
{ 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
/* you have to add ~/mm.cfg :
TraceOutputFileEnable=1
ErrorReportingEnable=1
MaxWarnings=1
in order to read the flash trace at ~/.macromedia/Flash_Player/Logs/flashlog.txt
Then FlashBug (a FireFox plugin) shows the log as well
*/
}:
let
arch =
if stdenv.system == "x86_64-linux" then
"x86_64"
else if stdenv.system == "i686-linux" then
"i386"
else throw "Flash Player is not supported on this platform";
lib_suffix =
if stdenv.system == "x86_64-linux" then
"64"
else
"";
in
stdenv.mkDerivation rec {
name = "flashplayer-${version}";
version = "24.0.0.186";
src = fetchurl {
url =
if debug then
"https://fpdownload.macromedia.com/pub/flashplayer/updaters/24/flash_player_npapi_linux_debug.${arch}.tar.gz"
else
"https://fpdownload.adobe.com/get/flashplayer/pdc/${version}/flash_player_npapi_linux.${arch}.tar.gz";
sha256 =
if debug then
if arch == "x86_64" then
"0i7c861n42vb2zd9hnp26lxjakkv0fxp53smcwzc9xhdbjr14ail"
else
"0gj59iinh8gbjm5bn24qi3niyvi8x6byyc1sa6qvqkvjwh1ckdi3"
else
if arch == "x86_64" then
"0qs6hx31p1q2zqsr8jcf7niwsp6nncpqs3igb6l9f9fi0a8va8f7"
else
"1zcinq7629bgbashx25krby8r91sag2v8382q620951iiww06n1v";
};
nativeBuildInputs = [ unzip ];
sourceRoot = ".";
dontStrip = true;
dontPatchELF = true;
preferLocalBuild = true;
installPhase = ''
mkdir -p $out/lib/mozilla/plugins
cp -pv libflashplayer.so $out/lib/mozilla/plugins
mkdir -p $out/bin
cp -pv usr/bin/flash-player-properties $out/bin
mkdir -p $out/lib${lib_suffix}/kde4
cp -pv usr/lib${lib_suffix}/kde4/kcm_adobe_flash_player.so $out/lib${lib_suffix}/kde4
patchelf --set-rpath "$rpath" \
$out/lib/mozilla/plugins/libflashplayer.so \
$out/lib${lib_suffix}/kde4/kcm_adobe_flash_player.so
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
--set-rpath "$rpath" \
$out/bin/flash-player-properties
'';
passthru = {
mozillaPlugin = "/lib/mozilla/plugins";
};
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 browser plugin";
homepage = http://www.adobe.com/products/flashplayer/;
license = stdenv.lib.licenses.unfree;
maintainers = [];
platforms = [ "x86_64-linux" "i686-linux" ];
};
}

View File

@ -0,0 +1,110 @@
{ 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 =
if stdenv.system == "x86_64-linux" then
"x86_64"
else if stdenv.system == "i686-linux" then
"i386"
else throw "Flash Player is not supported on this platform";
in
stdenv.mkDerivation rec {
name = "flashplayer-standalone-${version}";
version = "24.0.0.186";
src = fetchurl {
url =
if debug then
"https://fpdownload.macromedia.com/pub/flashplayer/updaters/24/flash_player_sa_linux_debug.x86_64.tar.gz"
else
"https://fpdownload.macromedia.com/pub/flashplayer/updaters/24/flash_player_sa_linux.x86_64.tar.gz";
sha256 =
if debug then
"09653jphzijk3w3dcd05f4pya1ciaymna31qqrmcwhxa0ginxhz2"
else
"0q0wc2lgjzi1v4lpcr5x5nszigli3vsryfq2zk4qq4pqy3i6aq7q";
};
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" ];
};
}

View File

@ -13151,13 +13151,17 @@ in
flac = callPackage ../applications/audio/flac { };
flashplayer = callPackage ../applications/networking/browsers/mozilla-plugins/flashplayer-11 {
flashplayer = callPackage ../applications/networking/browsers/mozilla-plugins/flashplayer {
debug = config.flashplayer.debug or false;
};
flashplayer-standalone = pkgsi686Linux.flashplayer.sa;
flashplayer-standalone = callPackage ../applications/networking/browsers/mozilla-plugins/flashplayer/standalone.nix {
debug = config.flashplayer.debug or false;
};
flashplayer-standalone-debugger = (pkgsi686Linux.flashplayer.override { debug = true; }).sa;
flashplayer-standalone-debugger = flashplayer-standalone.override {
debug = true;
};
fluxbox = callPackage ../applications/window-managers/fluxbox { };