diff --git a/pkgs/applications/networking/browsers/chromium/default.nix b/pkgs/applications/networking/browsers/chromium/default.nix index 2b20e26b3f9..5d191b2550d 100644 --- a/pkgs/applications/networking/browsers/chromium/default.nix +++ b/pkgs/applications/networking/browsers/chromium/default.nix @@ -13,13 +13,11 @@ , gcc, bison, gperf , glib, gtk, dbus_glib , libXScrnSaver, libXcursor, mesa - -# dependencies for v25 -, libvpx - -# dependencies for >= v25 , protobuf +# dependencies for v25 only +, libvpx + # dependencies for >= v26 , speechd, libXdamage @@ -59,7 +57,7 @@ let use_system_libexpat = true; use_system_libexif = true; use_system_libjpeg = true; - use_system_libpng = !post24; + use_system_libpng = false; # PNG dlopen() version conflict use_system_libusb = true; use_system_libxml = true; use_system_speex = true; @@ -76,7 +74,7 @@ let use_system_skia = false; use_system_sqlite = false; # http://crbug.com/22208 use_system_v8 = false; - } // optionalAttrs (post24 && !post25) { + } // optionalAttrs pre26 { use_system_libvpx = true; use_system_protobuf = true; }; @@ -89,14 +87,8 @@ let libusb1 libexif ]; - post23 = !versionOlder sourceInfo.version "24.0.0.0"; - post24 = !versionOlder sourceInfo.version "25.0.0.0"; - post25 = !versionOlder sourceInfo.version "26.0.0.0"; - only24 = post23 && !post24; - only25 = post24 && !post25; - - maybeFixPulseAudioBuild = optional (only24 && pulseSupport) - ./pulse_audio_fix.patch; + pre26 = versionOlder sourceInfo.version "26.0.0.0"; + post25 = !pre26; in stdenv.mkDerivation rec { name = "${packageName}-${version}"; @@ -119,13 +111,13 @@ in stdenv.mkDerivation rec { krb5 glib gtk dbus_glib libXScrnSaver libXcursor mesa + pciutils protobuf ] ++ optional gnomeKeyringSupport libgnome_keyring ++ optionals gnomeSupport [ gconf libgcrypt ] ++ optional enableSELinux libselinux ++ optional cupsSupport libgcrypt ++ optional pulseSupport pulseaudio - ++ optionals post24 [ pciutils protobuf ] - ++ optional only25 libvpx + ++ optional pre26 libvpx ++ optionals post25 [ speechd libXdamage ]; opensslPatches = optional useOpenSSL openssl.patches; @@ -134,15 +126,14 @@ in stdenv.mkDerivation rec { patches = optional cupsSupport ./cups_allow_deprecated.patch ++ optional pulseSupport ./pulseaudio_array_bounds.patch - ++ maybeFixPulseAudioBuild ++ optional post25 ./clone_detached.patch # XXX: Remove after stdenv-updates merge! ++ singleton "/dev/null"; - postPatch = optionalString useOpenSSL '' + postPatch = '' + sed -i -r -e 's/-f(stack-protector)(-all)?/-fno-\1/' build/common.gypi + '' + optionalString useOpenSSL '' cat $opensslPatches | patch -p1 -d third_party/openssl/openssl - '' + optionalString post24 '' - sed -i -r -e "s/-f(stack-protector)(-all)?/-fno-\1/" build/common.gypi '' + optionalString post25 '' sed -i -e 's|/usr/bin/gcc|gcc|' \ third_party/WebKit/Source/WebCore/WebCore.gyp/WebCore.gyp diff --git a/pkgs/applications/networking/browsers/chromium/pulse_audio_fix.patch b/pkgs/applications/networking/browsers/chromium/pulse_audio_fix.patch deleted file mode 100644 index 01ff89a9a63..00000000000 --- a/pkgs/applications/networking/browsers/chromium/pulse_audio_fix.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- chromium-build/media/audio/pulse/pulse_output.cc.orig 2012-10-26 09:44:38.509209905 -0700 -+++ chromium-build/media/audio/pulse/pulse_output.cc 2012-10-26 09:45:32.178819603 -0700 -@@ -86,7 +86,7 @@ - - // All channel maps have the same size array of channel positions. - for (unsigned int channel = 0; channel != CHANNELS_MAX; ++channel) { -- int channel_position = kChannelOrderings[channel_layout][channel]; -+ int channel_position = ChannelOrder(channel_layout, static_cast(channel)); - if (channel_position > -1) { - channel_map.map[channel_position] = ChromiumToPAChannelPosition( - static_cast(channel));