diff --git a/nixos/doc/manual/release-notes/rl-2003.xml b/nixos/doc/manual/release-notes/rl-2003.xml
index 72766f16eb9..d02e52cb0cf 100644
--- a/nixos/doc/manual/release-notes/rl-2003.xml
+++ b/nixos/doc/manual/release-notes/rl-2003.xml
@@ -131,6 +131,13 @@
networking.interfaces.<name>.… options.
+
+
+ The stdenv now runs all bash with set -u, to catch the use of undefined variables.
+ Before, it itself used set -u but was careful to unset it so other packages' code ran as before.
+ Now, all bash code is held to the same high standard, and the rather complex stateful manipulation of the options can be discarded.
+
+
diff --git a/nixos/modules/system/boot/systemd.nix b/nixos/modules/system/boot/systemd.nix
index 33b350902a1..9e3c6149f92 100644
--- a/nixos/modules/system/boot/systemd.nix
+++ b/nixos/modules/system/boot/systemd.nix
@@ -63,6 +63,7 @@ let
"systemd-logind.service"
"autovt@.service"
"systemd-user-sessions.service"
+ "dbus-org.freedesktop.import1.service"
"dbus-org.freedesktop.machine1.service"
"user@.service"
"user-runtime-dir@.service"
@@ -145,6 +146,7 @@ let
"user.slice"
"machine.slice"
"machines.target"
+ "systemd-importd.service"
"systemd-machined.service"
"systemd-nspawn@.service"
diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix
index b285f817d96..64aac8c8a1f 100644
--- a/nixos/tests/all-tests.nix
+++ b/nixos/tests/all-tests.nix
@@ -263,6 +263,7 @@ in
systemd-confinement = handleTest ./systemd-confinement.nix {};
systemd-timesyncd = handleTest ./systemd-timesyncd.nix {};
systemd-networkd-wireguard = handleTest ./systemd-networkd-wireguard.nix {};
+ systemd-nspawn = handleTest ./systemd-nspawn.nix {};
pdns-recursor = handleTest ./pdns-recursor.nix {};
taskserver = handleTest ./taskserver.nix {};
telegraf = handleTest ./telegraf.nix {};
diff --git a/nixos/tests/systemd-nspawn.nix b/nixos/tests/systemd-nspawn.nix
new file mode 100644
index 00000000000..c2039bb5980
--- /dev/null
+++ b/nixos/tests/systemd-nspawn.nix
@@ -0,0 +1,58 @@
+import ./make-test.nix ({pkgs, lib, ...}:
+let
+ gpgKeyring = (pkgs.runCommand "gpg-keyring" { buildInputs = [ pkgs.gnupg ]; } ''
+ mkdir -p $out
+ export GNUPGHOME=$out
+ cat > foo < $out/pubkey.gpg
+ '');
+
+ nspawnImages = (pkgs.runCommand "localhost" { buildInputs = [ pkgs.coreutils pkgs.gnupg ]; } ''
+ mkdir -p $out
+ cd $out
+ dd if=/dev/urandom of=$out/testimage.raw bs=$((1024*1024+7)) count=5
+ sha256sum testimage.raw > SHA256SUMS
+ export GNUPGHOME="$(mktemp -d)"
+ cp -R ${gpgKeyring}/* $GNUPGHOME
+ gpg --batch --sign --detach-sign --output SHA256SUMS.gpg SHA256SUMS
+ '');
+in {
+ name = "opensmtpd";
+
+ nodes = {
+ server = { pkgs, ... }: {
+ networking.firewall.allowedTCPPorts = [ 80 ];
+ services.nginx = {
+ enable = true;
+ virtualHosts."server".root = nspawnImages;
+ };
+ };
+ client = { pkgs, ... }: {
+ environment.etc."systemd/import-pubring.gpg".source = "${gpgKeyring}/pubkey.gpg";
+ };
+ };
+
+ testScript = ''
+ startAll;
+
+ $server->waitForUnit("nginx.service");
+ $client->waitForUnit("network-online.target");
+ $client->succeed("machinectl pull-raw --verify=signature http://server/testimage.raw");
+ $client->succeed("cmp /var/lib/machines/testimage.raw ${nspawnImages}/testimage.raw");
+ '';
+})
diff --git a/pkgs/applications/audio/i-score/default.nix b/pkgs/applications/audio/i-score/default.nix
index 2cc39e64943..f3928499413 100644
--- a/pkgs/applications/audio/i-score/default.nix
+++ b/pkgs/applications/audio/i-score/default.nix
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
];
preConfigure = ''
- export CMAKE_PREFIX_PATH="$CMAKE_PREFIX_PATH:$(echo "${jamomacore}/jamoma/share/cmake/Jamoma")"
+ export CMAKE_PREFIX_PATH="''${CMAKE_PREFIX_PATH-}:$(echo "${jamomacore}/jamoma/share/cmake/Jamoma")"
'';
postInstall = ''rm $out/bin/i-score.sh'';
diff --git a/pkgs/applications/audio/mpg123/default.nix b/pkgs/applications/audio/mpg123/default.nix
index 0d5445650a0..6c4b9a43176 100644
--- a/pkgs/applications/audio/mpg123/default.nix
+++ b/pkgs/applications/audio/mpg123/default.nix
@@ -3,11 +3,11 @@
}:
stdenv.mkDerivation rec {
- name = "mpg123-1.25.12";
+ name = "mpg123-1.25.13";
src = fetchurl {
url = "mirror://sourceforge/mpg123/${name}.tar.bz2";
- sha256 = "1l9iwwgqzw6yg5zk9pqmlbfyq6d8dqysbmj0j3m8dyrxd34wgzhz";
+ sha256 = "02l915jq0ymndb082g6w89bpf66z04ifa1lr7ga3yycw6m46hc4h";
};
buildInputs = stdenv.lib.optional (!stdenv.isDarwin) alsaLib;
diff --git a/pkgs/applications/audio/mpg321/default.nix b/pkgs/applications/audio/mpg321/default.nix
index 65dfe3484b6..fdefcf7e77d 100644
--- a/pkgs/applications/audio/mpg321/default.nix
+++ b/pkgs/applications/audio/mpg321/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, libao, libmad, libid3tag, zlib, alsaLib
+{stdenv, fetchurl, fetchpatch, libao, libmad, libid3tag, zlib, alsaLib
# Specify default libao output plugin to use (e.g. "alsa", "pulse" …).
# If null, it will use the libao system default.
, defaultAudio ? null
@@ -13,6 +13,14 @@ stdenv.mkDerivation rec {
sha256 = "0ki8mh76bbmdh77qsiw682dvi8y468yhbdabqwg05igmwc1wqvq5";
};
+ patches = [
+ (fetchpatch {
+ name = "CVE-2018-7263.patch";
+ url = "https://sources.debian.org/data/main/m/mpg321/0.3.2-3/debian/patches/handle_illegal_bitrate_value.patch";
+ sha256 = "15simp5fjvm9b024ryfh441rkh2d5bcrizqkzlrh07n9sm7fkw6x";
+ })
+ ];
+
hardeningDisable = [ "format" ];
configureFlags =
diff --git a/pkgs/applications/editors/vim/common.nix b/pkgs/applications/editors/vim/common.nix
index 9d22cdbf4a8..0a099ea630d 100644
--- a/pkgs/applications/editors/vim/common.nix
+++ b/pkgs/applications/editors/vim/common.nix
@@ -1,12 +1,12 @@
{ lib, fetchFromGitHub }:
rec {
- version = "8.1.2188";
+ version = "8.1.2237";
src = fetchFromGitHub {
owner = "vim";
repo = "vim";
rev = "v${version}";
- sha256 = "0ixq96l991b84sj66v63ds61yr75gx5zz411213yn6bz3s2fvlcv";
+ sha256 = "1qwh3cw5zmjmnk07g0nc8nz8k5nlq9ilvvygnfdjy1fqg69q8p0h";
};
enableParallelBuilding = true;
diff --git a/pkgs/applications/graphics/renderdoc/default.nix b/pkgs/applications/graphics/renderdoc/default.nix
index 594429503a3..426985d312c 100644
--- a/pkgs/applications/graphics/renderdoc/default.nix
+++ b/pkgs/applications/graphics/renderdoc/default.nix
@@ -1,32 +1,34 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ stdenv, fetchFromGitHub, cmake, pkgconfig, mkDerivation
, qtbase, qtx11extras, qtsvg, makeWrapper
-, vulkan-loader, xorg
-, python3, bison, pcre, automake, autoconf
+, vulkan-loader, xorg, python3, python3Packages
+, bison, pcre, automake, autoconf, addOpenGLRunpath
}:
let
custom_swig = fetchFromGitHub {
owner = "baldurk";
repo = "swig";
- rev = "renderdoc-modified-6";
- sha256 = "00ykqlzx1k9iwqjlc54kfch7cnzsj53hxn7ql70dj3rxqzrnadc0";
+ rev = "renderdoc-modified-7";
+ sha256 = "15r2m5kcs0id64pa2fsw58qll3jyh71jzc04wy20pgsh2326zis6";
};
+ pythonPackages = python3Packages;
in
-stdenv.mkDerivation rec {
- version = "1.4";
+mkDerivation rec {
+ version = "1.5";
pname = "renderdoc";
src = fetchFromGitHub {
owner = "baldurk";
repo = "renderdoc";
rev = "v${version}";
- sha256 = "1iann73r4yzkwnm13h4zqipqrp5i5cnkv27yyap0axz6h3npw94r";
+ sha256 = "0a05f6qfq90wrf4fixchp9knx4nhqhwjxl02n03a7k56xzxxnlci";
};
buildInputs = [
qtbase qtsvg xorg.libpthreadstubs xorg.libXdmcp qtx11extras vulkan-loader python3
- ];
+ ]; # ++ (with pythonPackages; [pyside2 pyside2-tools shiboken2]);
+ # TODO: figure out how to make cmake recognise pyside2
- nativeBuildInputs = [ cmake makeWrapper pkgconfig bison pcre automake autoconf ];
+ nativeBuildInputs = [ cmake makeWrapper pkgconfig bison pcre automake autoconf addOpenGLRunpath ];
postUnpack = ''
cp -r ${custom_swig} swig
@@ -40,19 +42,23 @@ stdenv.mkDerivation rec {
"-DBUILD_VERSION_DIST_VER=${version}"
"-DBUILD_VERSION_DIST_CONTACT=https://github.com/NixOS/nixpkgs/tree/master/pkgs/applications/graphics/renderdoc"
"-DBUILD_VERSION_STABLE=ON"
- # TODO: add once pyside2 is in nixpkgs
- #"-DPYSIDE2_PACKAGE_DIR=${python36Packages.pyside2}"
];
- # Future work: define these in the above array via placeholders
+ # TODO: define these in the above array via placeholders, once those are widely supported
preConfigure = ''
cmakeFlags+=" -DVULKAN_LAYER_FOLDER=$out/share/vulkan/implicit_layer.d/"
cmakeFlags+=" -DRENDERDOC_SWIG_PACKAGE=$PWD/../swig"
'';
+ dontWrapQtApps = true;
preFixup = ''
- wrapProgram $out/bin/qrenderdoc --suffix LD_LIBRARY_PATH : $out/lib --suffix LD_LIBRARY_PATH : ${vulkan-loader}/lib
- wrapProgram $out/bin/renderdoccmd --suffix LD_LIBRARY_PATH : $out/lib --suffix LD_LIBRARY_PATH : ${vulkan-loader}/lib
+ wrapQtApp $out/bin/qrenderdoc --suffix LD_LIBRARY_PATH : "$out/lib:${vulkan-loader}/lib"
+ wrapProgram $out/bin/renderdoccmd --suffix LD_LIBRARY_PATH : "$out/lib:${vulkan-loader}/lib"
+ '';
+
+ # The only documentation for this so far is in pkgs/build-support/add-opengl-runpath/setup-hook.sh
+ postFixup = ''
+ addOpenGLRunpath $out/lib/librenderdoc.so
'';
enableParallelBuilding = true;
diff --git a/pkgs/applications/networking/protocol/default.nix b/pkgs/applications/networking/protocol/default.nix
index 7fdb062ef80..8785d2449b3 100644
--- a/pkgs/applications/networking/protocol/default.nix
+++ b/pkgs/applications/networking/protocol/default.nix
@@ -1,14 +1,14 @@
{ stdenv, buildPythonApplication, fetchFromGitHub }:
buildPythonApplication {
- pname = "protocol";
- version = "20171226";
+ pname = "protocol-unstable";
+ version = "2019-03-28";
src = fetchFromGitHub {
owner = "luismartingarcia";
repo = "protocol";
- rev = "d450da7d8a58595d8ef82f1d199a80411029fc7d";
- sha256 = "1g31s2xx0bw8ak5ag1c6mv0p0b8bj5dp3lkk9mxaf2ndj1m1qdkw";
+ rev = "4e8326ea6c2d288be5464c3a7d9398df468c0ada";
+ sha256 = "13l10jhf4vghanmhh3pn91b2jdciispxy0qadz4n08blp85qn9cm";
};
meta = with stdenv.lib; {
diff --git a/pkgs/applications/office/zotero/default.nix b/pkgs/applications/office/zotero/default.nix
index 334a380d914..34dace1cadb 100644
--- a/pkgs/applications/office/zotero/default.nix
+++ b/pkgs/applications/office/zotero/default.nix
@@ -34,11 +34,11 @@
stdenv.mkDerivation rec {
pname = "zotero";
- version = "5.0.73";
+ version = "5.0.77";
src = fetchurl {
url = "https://download.zotero.org/client/release/${version}/Zotero-${version}_linux-x86_64.tar.bz2";
- sha256 = "0m2i3l0gy22h6c7rk39cd17vyksyz5l5py2fn9pza8lcbypkwf3l";
+ sha256 = "1dgxzprpb8f5wpmvlvkxix0xxckfgjsi3wfcy9mb221a17cv0029";
};
buildInputs= [ wrapGAppsHook gsettings-desktop-schemas gtk3 gnome3.adwaita-icon-theme gnome3.dconf ];
diff --git a/pkgs/applications/science/math/mathematica/default.nix b/pkgs/applications/science/math/mathematica/default.nix
index ca9a87abe13..7cd1b2eb99f 100644
--- a/pkgs/applications/science/math/mathematica/default.nix
+++ b/pkgs/applications/science/math/mathematica/default.nix
@@ -93,13 +93,16 @@ stdenv.mkDerivation rec {
# Fix library paths
cd $out/libexec/Mathematica/Executables
for path in mathematica MathKernel Mathematica WolframKernel wolfram math; do
- sed -i -e 's#export LD_LIBRARY_PATH$#export LD_LIBRARY_PATH=${zlib}/lib:\''${LD_LIBRARY_PATH}#' $path
+ sed -i -e "2iexport LD_LIBRARY_PATH=${zlib}/lib:\''${LD_LIBRARY_PATH}\n" $path
done
# Fix xkeyboard config path for Qt
for path in mathematica Mathematica; do
sed -i -e "2iexport QT_XKB_CONFIG_ROOT=\"${xkeyboard_config}/share/X11/xkb\"\n" $path
done
+
+ # Remove some broken libraries
+ rm $out/libexec/Mathematica/SystemFiles/Libraries/Linux-x86-64/libz.so*
'';
preFixup = ''
diff --git a/pkgs/applications/version-management/git-and-tools/git/default.nix b/pkgs/applications/version-management/git-and-tools/git/default.nix
index 46bbc72fb3b..a6b53561771 100644
--- a/pkgs/applications/version-management/git-and-tools/git/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git/default.nix
@@ -21,7 +21,7 @@ assert sendEmailSupport -> perlSupport;
assert svnSupport -> perlSupport;
let
- version = "2.23.0";
+ version = "2.24.0";
svn = subversionClient.override { perlBindings = perlSupport; };
gitwebPerlLibs = with perlPackages; [ CGI HTMLParser CGIFast FCGI FCGIProcManager HTMLTagCloud ];
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
src = fetchurl {
url = "https://www.kernel.org/pub/software/scm/git/git-${version}.tar.xz";
- sha256 = "0rv0y45gcd3h191isppn77acih695v4pipdj031jvs9rd1ds0kr3";
+ sha256 = "06rpakbwzck85ncfsgv4xmq3iwab9d4f5y6dqhl8nvb2fccxcwcz";
};
outputs = [ "out" ];
@@ -93,7 +93,7 @@ stdenv.mkDerivation {
++ (if perlSupport then ["PERL_PATH=${perlPackages.perl}/bin/perl"] else ["NO_PERL=1"])
++ (if pythonSupport then ["PYTHON_PATH=${python}/bin/python"] else ["NO_PYTHON=1"])
++ stdenv.lib.optionals stdenv.isSunOS ["INSTALL=install" "NO_INET_NTOP=" "NO_INET_PTON="]
- ++ (if stdenv.isDarwin then ["NO_APPLE_COMMON_CRYPTO=1"] else ["sysconfdir=/etc/"])
+ ++ (if stdenv.isDarwin then ["NO_APPLE_COMMON_CRYPTO=1"] else ["sysconfdir=/etc"])
++ stdenv.lib.optionals stdenv.hostPlatform.isMusl ["NO_SYS_POLL_H=1" "NO_GETTEXT=YesPlease"]
++ stdenv.lib.optional withpcre2 "USE_LIBPCRE2=1";
diff --git a/pkgs/applications/video/kodi/default.nix b/pkgs/applications/video/kodi/default.nix
index 7953cde2413..8edc99c5f02 100644
--- a/pkgs/applications/video/kodi/default.nix
+++ b/pkgs/applications/video/kodi/default.nix
@@ -8,7 +8,7 @@
, libXt, libXmu, libXext
, libXinerama, libXrandr
, libXtst, libXfixes, systemd
-, alsaLib, libGLU_combined, glew, fontconfig, freetype, ftgl
+, alsaLib, libGLU, libGL, glew, fontconfig, freetype, ftgl
, libjpeg, jasper, libpng, libtiff
, libmpeg2, libsamplerate, libmad
, libogg, libvorbis, flac, libxslt
@@ -156,7 +156,7 @@ in stdenv.mkDerivation {
openssl gperf tinyxml2 taglib libssh swig jre
libX11 xorgproto libXt libXmu libXext
libXinerama libXrandr libXtst libXfixes
- alsaLib libGLU_combined glew fontconfig freetype ftgl
+ alsaLib libGL libGLU glew fontconfig freetype ftgl
libjpeg jasper libpng libtiff
libmpeg2 libsamplerate libmad
libogg libvorbis flac libxslt systemd
diff --git a/pkgs/build-support/bintools-wrapper/default.nix b/pkgs/build-support/bintools-wrapper/default.nix
index e02e77de45e..4a56f00db49 100644
--- a/pkgs/build-support/bintools-wrapper/default.nix
+++ b/pkgs/build-support/bintools-wrapper/default.nix
@@ -111,17 +111,13 @@ stdenv.mkDerivation {
installPhase =
''
- set -u
-
mkdir -p $out/bin $out/nix-support
wrap() {
local dst="$1"
local wrapper="$2"
export prog="$3"
- set +u
substituteAll "$wrapper" "$out/bin/$dst"
- set -u
chmod +x "$out/bin/$dst"
}
''
@@ -163,8 +159,6 @@ stdenv.mkDerivation {
[[ -e "$underlying" ]] || continue
wrap ${targetPrefix}$variant ${./ld-wrapper.sh} $underlying
done
-
- set +u
'';
emulation = let
@@ -205,11 +199,7 @@ stdenv.mkDerivation {
];
postFixup =
- ''
- set -u
- ''
-
- + optionalString (libc != null) (''
+ optionalString (libc != null) (''
##
## General libc support
##
@@ -307,7 +297,6 @@ stdenv.mkDerivation {
''
+ ''
- set +u
substituteAll ${./add-flags.sh} $out/nix-support/add-flags.sh
substituteAll ${./add-hardening.sh} $out/nix-support/add-hardening.sh
substituteAll ${../wrapper-common/utils.bash} $out/nix-support/utils.bash
diff --git a/pkgs/build-support/bintools-wrapper/setup-hook.sh b/pkgs/build-support/bintools-wrapper/setup-hook.sh
index 2e15fa95c79..a714bd151c9 100644
--- a/pkgs/build-support/bintools-wrapper/setup-hook.sh
+++ b/pkgs/build-support/bintools-wrapper/setup-hook.sh
@@ -2,8 +2,6 @@
#
# See comments in cc-wrapper's setup hook. This works exactly the same way.
-set -u
-
# Skip setup hook if we're neither a build-time dep, nor, temporarily, doing a
# native compile.
#
@@ -73,4 +71,3 @@ export NIX_HARDENING_ENABLE
# No local scope in sourced file
unset -v role_pre role_post cmd upper_case
-set +u
diff --git a/pkgs/build-support/build-dotnet-package/default.nix b/pkgs/build-support/build-dotnet-package/default.nix
index f36c69e4339..dae9ed888c7 100644
--- a/pkgs/build-support/build-dotnet-package/default.nix
+++ b/pkgs/build-support/build-dotnet-package/default.nix
@@ -29,9 +29,9 @@ attrsOrig @
configurePhase = ''
runHook preConfigure
- [ -z "$dontPlacateNuget" ] && placate-nuget.sh
- [ -z "$dontPlacatePaket" ] && placate-paket.sh
- [ -z "$dontPatchFSharpTargets" ] && patch-fsharp-targets.sh
+ [ -z "''${dontPlacateNuget-}" ] && placate-nuget.sh
+ [ -z "''${dontPlacatePaket-}" ] && placate-paket.sh
+ [ -z "''${dontPatchFSharpTargets-}" ] && patch-fsharp-targets.sh
runHook postConfigure
'';
@@ -69,7 +69,7 @@ attrsOrig @
cp -rv ${arrayToShell outputFiles} "''${outputFilesArray[@]}" "$target"
- if [ -z "$dontRemoveDuplicatedDlls" ]
+ if [ -z "''${dontRemoveDuplicatedDlls-}" ]
then
pushd "$out"
remove-duplicated-dlls.sh
diff --git a/pkgs/build-support/cc-wrapper/default.nix b/pkgs/build-support/cc-wrapper/default.nix
index cf2d38cd997..d6037552ef6 100644
--- a/pkgs/build-support/cc-wrapper/default.nix
+++ b/pkgs/build-support/cc-wrapper/default.nix
@@ -134,8 +134,6 @@ stdenv.mkDerivation {
installPhase =
''
- set -u
-
mkdir -p $out/bin $out/nix-support
wrap() {
@@ -224,8 +222,6 @@ stdenv.mkDerivation {
postFixup =
''
- set -u
-
# Backwards compatability for packages expecting this file, e.g. with
# `$NIX_CC/nix-support/dynamic-linker`.
#
diff --git a/pkgs/build-support/cc-wrapper/setup-hook.sh b/pkgs/build-support/cc-wrapper/setup-hook.sh
index 211b5063291..5b13f268309 100644
--- a/pkgs/build-support/cc-wrapper/setup-hook.sh
+++ b/pkgs/build-support/cc-wrapper/setup-hook.sh
@@ -54,8 +54,6 @@
# For more details, read the individual files where the mechanisms used to
# accomplish this will be individually documented.
-set -u
-
# Skip setup hook if we're neither a build-time dep, nor, temporarily, doing a
# native compile.
#
@@ -120,4 +118,3 @@ export NIX_HARDENING_ENABLE
# No local scope in sourced file
unset -v role_pre role_post
-set +u
diff --git a/pkgs/build-support/emacs/setup-hook.sh b/pkgs/build-support/emacs/setup-hook.sh
index e1db3e828fd..b55c1873802 100644
--- a/pkgs/build-support/emacs/setup-hook.sh
+++ b/pkgs/build-support/emacs/setup-hook.sh
@@ -1,11 +1,11 @@
addEmacsVars () {
- if test -d $1/share/emacs/site-lisp; then
- export EMACSLOADPATH="$1/share/emacs/site-lisp:$EMACSLOADPATH"
+ if [[ -d "$1/share/emacs/site-lisp" ]]; then
+ export EMACSLOADPATH="$1/share/emacs/site-lisp${EMACSLOADPATH:+:}${EMACSLOADPATH-}"
fi
}
# If this is for a wrapper derivation, emacs and the dependencies are all
# run-time dependencies. If this is for precompiling packages into bytecode,
# emacs is a compile-time dependency of the package.
-addEnvHooks "$targetOffset" addEmacsVars
+addEnvHooks "$hostOffset" addEmacsVars
addEnvHooks "$targetOffset" addEmacsVars
diff --git a/pkgs/build-support/ocaml/default.nix b/pkgs/build-support/ocaml/default.nix
index cc2001c66e2..3957b955a2c 100644
--- a/pkgs/build-support/ocaml/default.nix
+++ b/pkgs/build-support/ocaml/default.nix
@@ -23,7 +23,7 @@ stdenv.mkDerivation (args // {
setupHook = if setupHook == null && hasSharedObjects
then writeText "setupHook.sh" ''
- export CAML_LD_LIBRARY_PATH="''${CAML_LD_LIBRARY_PATH}''${CAML_LD_LIBRARY_PATH:+:}''$1/lib/ocaml/${ocaml.version}/site-lib/${name}/"
+ export CAML_LD_LIBRARY_PATH="''${CAML_LD_LIBRARY_PATH-}''${CAML_LD_LIBRARY_PATH:+:}''$1/lib/ocaml/${ocaml.version}/site-lib/${name}/"
''
else setupHook;
diff --git a/pkgs/build-support/setup-hooks/audit-tmpdir.sh b/pkgs/build-support/setup-hooks/audit-tmpdir.sh
index 5264ce39851..c9dd32d1dd2 100644
--- a/pkgs/build-support/setup-hooks/audit-tmpdir.sh
+++ b/pkgs/build-support/setup-hooks/audit-tmpdir.sh
@@ -7,7 +7,7 @@
# the moment that would produce too many spurious errors (e.g. debug
# info or assertion messages that refer to $TMPDIR).
-fixupOutputHooks+=('if [ -z "$noAuditTmpdir" -a -e "$prefix" ]; then auditTmpdir "$prefix"; fi')
+fixupOutputHooks+=('if [[ -z "${noAuditTmpdir-}" && -e "$prefix" ]]; then auditTmpdir "$prefix"; fi')
auditTmpdir() {
local dir="$1"
diff --git a/pkgs/build-support/setup-hooks/auto-patchelf.sh b/pkgs/build-support/setup-hooks/auto-patchelf.sh
index 6af8eb1aed9..52c50091d08 100644
--- a/pkgs/build-support/setup-hooks/auto-patchelf.sh
+++ b/pkgs/build-support/setup-hooks/auto-patchelf.sh
@@ -228,7 +228,7 @@ autoPatchelf() {
# behaviour as fixupOutputHooks because the setup hook for patchelf is run in
# fixupOutput and the postFixup hook runs later.
postFixupHooks+=('
- if [ -z "$dontAutoPatchelf" ]; then
+ if [ -z "${dontAutoPatchelf-}" ]; then
autoPatchelf -- $(for output in $outputs; do
[ -e "${!output}" ] || continue
echo "${!output}"
diff --git a/pkgs/build-support/setup-hooks/compress-man-pages.sh b/pkgs/build-support/setup-hooks/compress-man-pages.sh
index d10a898d6e4..82e48cd8aa7 100644
--- a/pkgs/build-support/setup-hooks/compress-man-pages.sh
+++ b/pkgs/build-support/setup-hooks/compress-man-pages.sh
@@ -1,4 +1,4 @@
-fixupOutputHooks+=('if [ -z "$dontGzipMan" ]; then compressManPages "$prefix"; fi')
+fixupOutputHooks+=('if [ -z "${dontGzipMan-}" ]; then compressManPages "$prefix"; fi')
compressManPages() {
local dir="$1"
diff --git a/pkgs/build-support/setup-hooks/find-xml-catalogs.sh b/pkgs/build-support/setup-hooks/find-xml-catalogs.sh
index 85364a61f61..f446a6f27fd 100644
--- a/pkgs/build-support/setup-hooks/find-xml-catalogs.sh
+++ b/pkgs/build-support/setup-hooks/find-xml-catalogs.sh
@@ -11,12 +11,12 @@ addXMLCatalogs () {
done
}
-if [ -z "$libxmlHookDone" ]; then
+if [ -z "${libxmlHookDone-}" ]; then
libxmlHookDone=1
# Set up XML_CATALOG_FILES. An empty initial value prevents
# xmllint and xsltproc from looking in /etc/xml/catalog.
- export XML_CATALOG_FILES
+ export XML_CATALOG_FILES=''
if [ -z "$XML_CATALOG_FILES" ]; then XML_CATALOG_FILES=" "; fi
addEnvHooks "$hostOffset" addXMLCatalogs
fi
diff --git a/pkgs/build-support/setup-hooks/move-lib64.sh b/pkgs/build-support/setup-hooks/move-lib64.sh
index 7724be369c9..9517af79732 100644
--- a/pkgs/build-support/setup-hooks/move-lib64.sh
+++ b/pkgs/build-support/setup-hooks/move-lib64.sh
@@ -8,7 +8,7 @@
fixupOutputHooks+=(_moveLib64)
_moveLib64() {
- if [ "$dontMoveLib64" = 1 ]; then return; fi
+ if [ "${dontMoveLib64-}" = 1 ]; then return; fi
if [ ! -e "$prefix/lib64" -o -L "$prefix/lib64" ]; then return; fi
echo "moving $prefix/lib64/* to $prefix/lib"
mkdir -p $prefix/lib
diff --git a/pkgs/build-support/setup-hooks/move-sbin.sh b/pkgs/build-support/setup-hooks/move-sbin.sh
index cc51c27cafd..1c0c4dc9f2d 100644
--- a/pkgs/build-support/setup-hooks/move-sbin.sh
+++ b/pkgs/build-support/setup-hooks/move-sbin.sh
@@ -5,7 +5,7 @@
fixupOutputHooks+=(_moveSbin)
_moveSbin() {
- if [ "$dontMoveSbin" = 1 ]; then return; fi
+ if [ "${dontMoveSbin-}" = 1 ]; then return; fi
if [ ! -e "$prefix/sbin" -o -L "$prefix/sbin" ]; then return; fi
echo "moving $prefix/sbin/* to $prefix/bin"
mkdir -p $prefix/bin
diff --git a/pkgs/build-support/setup-hooks/multiple-outputs.sh b/pkgs/build-support/setup-hooks/multiple-outputs.sh
index d43b1877674..2e95495c96f 100644
--- a/pkgs/build-support/setup-hooks/multiple-outputs.sh
+++ b/pkgs/build-support/setup-hooks/multiple-outputs.sh
@@ -9,8 +9,8 @@ _assignFirst() {
local varName="$1"
local REMOVE=REMOVE # slightly hacky - we allow REMOVE (i.e. not a variable name)
shift
- while [ $# -ge 1 ]; do
- if [ -n "${!1}" ]; then eval "${varName}"="$1"; return; fi
+ while (( $# )); do
+ if [ -n "${!1-}" ]; then eval "${varName}"="$1"; return; fi
shift
done
echo "Error: _assignFirst found no valid variant!"
@@ -19,7 +19,7 @@ _assignFirst() {
# Same as _assignFirst, but only if "$1" = ""
_overrideFirst() {
- if [ -z "${!1}" ]; then
+ if [ -z "${!1-}" ]; then
_assignFirst "$@"
fi
}
diff --git a/pkgs/build-support/setup-hooks/patch-shebangs.sh b/pkgs/build-support/setup-hooks/patch-shebangs.sh
index 3e900d0704c..29fed7ad794 100644
--- a/pkgs/build-support/setup-hooks/patch-shebangs.sh
+++ b/pkgs/build-support/setup-hooks/patch-shebangs.sh
@@ -105,7 +105,7 @@ patchShebangs() {
}
patchShebangsAuto () {
- if [ -z "$dontPatchShebangs" -a -e "$prefix" ]; then
+ if [ -z "${dontPatchShebangs-}" -a -e "$prefix" ]; then
# Dev output will end up being run on the build platform. An
# example case of this is sdl2-config. Otherwise, we can just
diff --git a/pkgs/build-support/setup-hooks/prune-libtool-files.sh b/pkgs/build-support/setup-hooks/prune-libtool-files.sh
index 5d7432e8f09..0ec56549645 100644
--- a/pkgs/build-support/setup-hooks/prune-libtool-files.sh
+++ b/pkgs/build-support/setup-hooks/prune-libtool-files.sh
@@ -8,7 +8,7 @@
fixupOutputHooks+=(_pruneLibtoolFiles)
_pruneLibtoolFiles() {
- if [ "$dontPruneLibtoolFiles" ] || [ ! -e "$prefix" ]; then
+ if [ "${dontPruneLibtoolFiles-}" ] || [ ! -e "$prefix" ]; then
return
fi
diff --git a/pkgs/build-support/setup-hooks/strip.sh b/pkgs/build-support/setup-hooks/strip.sh
index fc4c7bfbaf9..f5fa9378fd7 100644
--- a/pkgs/build-support/setup-hooks/strip.sh
+++ b/pkgs/build-support/setup-hooks/strip.sh
@@ -10,7 +10,7 @@ _doStrip() {
local -ra stripCmds=(STRIP TARGET_STRIP)
# Optimization
- if [[ "$STRIP" == "$TARGET_STRIP" ]]; then
+ if [[ "${STRIP-}" == "${TARGET_STRIP-}" ]]; then
dontStripTarget+=1
fi
@@ -20,7 +20,7 @@ _doStrip() {
local -n stripCmd="${stripCmds[$i]}"
# `dontStrip` disables them all
- if [[ "$dontStrip" || "$flag" ]] || ! type -f "$stripCmd" 2>/dev/null
+ if [[ "${dontStrip-}" || "${flag-}" ]] || ! type -f "${stripCmd-}" 2>/dev/null
then continue; fi
stripDebugList=${stripDebugList:-lib lib32 lib64 libexec bin sbin}
diff --git a/pkgs/build-support/setup-hooks/update-autotools-gnu-config-scripts.sh b/pkgs/build-support/setup-hooks/update-autotools-gnu-config-scripts.sh
index 66f4e91c7bb..ebd3afa05d9 100644
--- a/pkgs/build-support/setup-hooks/update-autotools-gnu-config-scripts.sh
+++ b/pkgs/build-support/setup-hooks/update-autotools-gnu-config-scripts.sh
@@ -1,7 +1,7 @@
preConfigurePhases+=" updateAutotoolsGnuConfigScriptsPhase"
updateAutotoolsGnuConfigScriptsPhase() {
- if [ -n "$dontUpdateAutotoolsGnuConfigScripts" ]; then return; fi
+ if [ -n "${dontUpdateAutotoolsGnuConfigScripts-}" ]; then return; fi
for script in config.sub config.guess; do
for f in $(find . -type f -name "$script"); do
diff --git a/pkgs/build-support/setup-hooks/wrap-gapps-hook.sh b/pkgs/build-support/setup-hooks/wrap-gapps-hook.sh
index 717740f1f20..a05d4f689db 100644
--- a/pkgs/build-support/setup-hooks/wrap-gapps-hook.sh
+++ b/pkgs/build-support/setup-hooks/wrap-gapps-hook.sh
@@ -15,7 +15,7 @@ wrapGApp() {
wrapProgram "$program" "${gappsWrapperArgs[@]}" "$@"
}
-# Note: $gappsWrapperArgs still gets defined even if $dontWrapGApps is set.
+# Note: $gappsWrapperArgs still gets defined even if ${dontWrapGApps-} is set.
wrapGAppsHook() {
# guard against running multiple times (e.g. due to propagation)
[ -z "$wrapGAppsHookHasRun" ] || return 0
diff --git a/pkgs/desktops/gnome-2/default.nix b/pkgs/desktops/gnome-2/default.nix
index 6cc6848b316..d0a7a890355 100644
--- a/pkgs/desktops/gnome-2/default.nix
+++ b/pkgs/desktops/gnome-2/default.nix
@@ -37,9 +37,7 @@ lib.makeScope pkgs.newScope (self: with self; {
gnome_python_desktop = callPackage ./bindings/gnome-python-desktop { };
- gnome_vfs = callPackage ./platform/gnome-vfs {
- openssl = pkgs.openssl_1_0_2;
- };
+ gnome_vfs = callPackage ./platform/gnome-vfs { };
libgnome = callPackage ./platform/libgnome { };
diff --git a/pkgs/desktops/gnome-2/platform/gnome-vfs/default.nix b/pkgs/desktops/gnome-2/platform/gnome-vfs/default.nix
index c15f43b542a..7196840978f 100644
--- a/pkgs/desktops/gnome-2/platform/gnome-vfs/default.nix
+++ b/pkgs/desktops/gnome-2/platform/gnome-vfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxml2, bzip2, openssl, dbus-glib
+{ stdenv, fetchurl, fetchpatch, pkgconfig, libxml2, bzip2, openssl, dbus-glib
, glib, gamin, cdparanoia, intltool, GConf, gnome_mime_data, avahi, acl }:
stdenv.mkDerivation rec {
@@ -20,6 +20,18 @@ stdenv.mkDerivation rec {
propagatedBuildInputs = [ GConf glib ];
+ # struct SSL is opaque in openssl-1.1; and the SSL_free() man page
+ # says that one should not free members of it manually (in both
+ # the openssl-1.0 and openssl-1.1 man pages).
+ # https://bugs.gentoo.org/592540
+ patches = [ (fetchpatch {
+ name = "gnome-vfs-2.24.4-openssl-1.1.patch";
+ url = "https://bugs.gentoo.org/attachment.cgi?id=535944";
+ sha256 = "1q4icapvmwmd5rjah7rr0bqazzk5cg36znmjlpra20n9y27nz040";
+ extraPrefix = "";
+ })
+ ];
+
postPatch = "find . -name Makefile.in | xargs sed 's/-DG_DISABLE_DEPRECATED//g' -i ";
doCheck = false; # needs dbus daemon
diff --git a/pkgs/desktops/gnome-3/core/mutter/3.28.nix b/pkgs/desktops/gnome-3/core/mutter/3.28.nix
index cc00fc5ece4..85208163415 100644
--- a/pkgs/desktops/gnome-3/core/mutter/3.28.nix
+++ b/pkgs/desktops/gnome-3/core/mutter/3.28.nix
@@ -56,6 +56,8 @@ stdenv.mkDerivation rec {
})
# See patch commit message
./0001-Revert-ClutterActor-Preserve-valid-paint-volumes-til.patch
+ # Fix build with libglvnd provided headers
+ ./libglvnd-328.patch
];
configureFlags = [
diff --git a/pkgs/desktops/gnome-3/core/mutter/default.nix b/pkgs/desktops/gnome-3/core/mutter/default.nix
index d2745c2a90d..8fad9e3c288 100644
--- a/pkgs/desktops/gnome-3/core/mutter/default.nix
+++ b/pkgs/desktops/gnome-3/core/mutter/default.nix
@@ -66,6 +66,11 @@ stdenv.mkDerivation rec {
src = ./fix-paths.patch;
inherit zenity;
})
+ # Fix build with libglvnd provided headers
+ (fetchpatch {
+ url = "https://gitlab.gnome.org/GNOME/mutter/commit/a444a4c5f58ea516ad3cd9d6ddc0056c3ca9bc90.patch";
+ sha256 = "0imy2j8af9477jliwdq4jc40yw1cifsjjf196gnmwxr9rkj0hbrd";
+ })
];
postPatch = ''
diff --git a/pkgs/desktops/gnome-3/core/mutter/libglvnd-328.patch b/pkgs/desktops/gnome-3/core/mutter/libglvnd-328.patch
new file mode 100644
index 00000000000..96e27559828
--- /dev/null
+++ b/pkgs/desktops/gnome-3/core/mutter/libglvnd-328.patch
@@ -0,0 +1,63 @@
+diff --git a/cogl/configure.ac b/cogl/configure.ac
+index 3be282f..d338cd1 100644
+--- a/cogl/configure.ac
++++ b/cogl/configure.ac
+@@ -490,6 +490,11 @@ AS_IF([test "x$enable_gles1" = "xyes"],
+ #include "],
+ [],
+ [$COGL_EGL_INCLUDES])
++ AC_CHECK_HEADERS([EGL/eglmesaext.h],
++ [COGL_EGL_INCLUDES="$COGL_EGL_INCLUDE
++#include "],
++ [],
++ [$COGL_EGL_INCLUDES])
+
+ # Check for a GLES 1.x Common Profile library with/without EGL.
+ #
+@@ -759,7 +764,9 @@ AS_IF([test "x$NEED_EGL" = "xyes" && test "x$EGL_CHECKED" != "xyes"],
+ )
+
+ COGL_EGL_INCLUDES="#include
+-#include "
++#include
++#include
++"
+ AC_SUBST([COGL_EGL_INCLUDES])
+ ])
+
+diff --git a/src/backends/meta-egl-ext.h b/src/backends/meta-egl-ext.h
+index 8705e7d..db0b74f 100644
+--- a/src/backends/meta-egl-ext.h
++++ b/src/backends/meta-egl-ext.h
+@@ -29,6 +29,7 @@
+
+ #include
+ #include
++#include
+
+ /*
+ * This is a little different to the tests shipped with EGL implementations,
+diff --git a/src/backends/meta-egl.c b/src/backends/meta-egl.c
+index 755ec49..bd253c9 100644
+--- a/src/backends/meta-egl.c
++++ b/src/backends/meta-egl.c
+@@ -31,6 +31,7 @@
+
+ #include
+ #include
++#include
+ #include
+ #include
+ #include
+diff --git a/src/backends/meta-egl.h b/src/backends/meta-egl.h
+index 060c7cd..2fef264 100644
+--- a/src/backends/meta-egl.h
++++ b/src/backends/meta-egl.h
+@@ -27,6 +27,7 @@
+
+ #include
+ #include
++#include
+ #include
+
+ #define META_EGL_ERROR meta_egl_error_quark ()
diff --git a/pkgs/development/compilers/adoptopenjdk-bin/jdk-darwin-base.nix b/pkgs/development/compilers/adoptopenjdk-bin/jdk-darwin-base.nix
index 03857627952..3b9cb752b9b 100644
--- a/pkgs/development/compilers/adoptopenjdk-bin/jdk-darwin-base.nix
+++ b/pkgs/development/compilers/adoptopenjdk-bin/jdk-darwin-base.nix
@@ -37,7 +37,7 @@ let cpuName = stdenv.hostPlatform.parsed.cpu.name;
# Set JAVA_HOME automatically.
cat <> $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/adoptopenjdk-bin/jdk-linux-base.nix b/pkgs/development/compilers/adoptopenjdk-bin/jdk-linux-base.nix
index 509050209fb..fe38f2b2163 100644
--- a/pkgs/development/compilers/adoptopenjdk-bin/jdk-linux-base.nix
+++ b/pkgs/development/compilers/adoptopenjdk-bin/jdk-linux-base.nix
@@ -54,7 +54,7 @@ let result = stdenv.mkDerivation rec {
# Set JAVA_HOME automatically.
cat <> "$out/nix-support/setup-hook"
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/graalvm/default.nix b/pkgs/development/compilers/graalvm/default.nix
index 41cf956cd9f..11a94ebcce5 100644
--- a/pkgs/development/compilers/graalvm/default.nix
+++ b/pkgs/development/compilers/graalvm/default.nix
@@ -270,7 +270,7 @@ in rec {
# Set JAVA_HOME automatically.
mkdir -p $out/nix-support
cat < $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
postFixup = openjdk.postFixup or null;
diff --git a/pkgs/development/compilers/graalvm/enterprise-edition.nix b/pkgs/development/compilers/graalvm/enterprise-edition.nix
index 84cb38aa8d1..e180455cb7c 100644
--- a/pkgs/development/compilers/graalvm/enterprise-edition.nix
+++ b/pkgs/development/compilers/graalvm/enterprise-edition.nix
@@ -72,7 +72,7 @@ let
# Set JAVA_HOME automatically.
mkdir -p $out/nix-support
cat < $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/llvm/7/libc++/default.nix b/pkgs/development/compilers/llvm/7/libc++/default.nix
index 7a0716a6eb3..f6f9970d7a6 100644
--- a/pkgs/development/compilers/llvm/7/libc++/default.nix
+++ b/pkgs/development/compilers/llvm/7/libc++/default.nix
@@ -1,4 +1,5 @@
-{ lib, stdenv, fetch, cmake, python, libcxxabi, fixDarwinDylibNames, version }:
+{ lib, stdenv, fetch, cmake, python, libcxxabi, fixDarwinDylibNames, version
+, enableShared ? ! stdenv.hostPlatform.isMusl }:
stdenv.mkDerivation {
pname = "libc++";
@@ -31,7 +32,8 @@ stdenv.mkDerivation {
"-DLIBCXX_LIBCXXABI_LIB_PATH=${libcxxabi}/lib"
"-DLIBCXX_LIBCPPABI_VERSION=2"
"-DLIBCXX_CXX_ABI=libcxxabi"
- ] ++ stdenv.lib.optional stdenv.hostPlatform.isMusl "-DLIBCXX_HAS_MUSL_LIBC=1";
+ ] ++ stdenv.lib.optional stdenv.hostPlatform.isMusl "-DLIBCXX_HAS_MUSL_LIBC=1"
+ ++ stdenv.lib.optional (!enableShared) "-DLIBCXX_ENABLE_SHARED=OFF" ;
enableParallelBuilding = true;
diff --git a/pkgs/development/compilers/llvm/7/libc++abi.nix b/pkgs/development/compilers/llvm/7/libc++abi.nix
index 522c8d1a163..9067bf43a8f 100644
--- a/pkgs/development/compilers/llvm/7/libc++abi.nix
+++ b/pkgs/development/compilers/llvm/7/libc++abi.nix
@@ -1,4 +1,6 @@
-{ stdenv, cmake, fetch, libcxx, llvm, version }:
+{ stdenv, cmake, fetch, libcxx, llvm, version
+ # on musl the shared objects don't build
+, enableShared ? ! stdenv.hostPlatform.isMusl }:
stdenv.mkDerivation {
pname = "libc++abi";
@@ -11,13 +13,15 @@ stdenv.mkDerivation {
postUnpack = ''
unpackFile ${libcxx.src}
unpackFile ${llvm.src}
- export cmakeFlags="-DLLVM_PATH=$PWD/$(ls -d llvm-*) -DLIBCXXABI_LIBCXX_PATH=$PWD/$(ls -d libcxx-*)"
+ cmakeFlagsArray=($cmakeFlagsArray -DLLVM_PATH=$PWD/$(ls -d llvm-*) -DLIBCXXABI_LIBCXX_PATH=$PWD/$(ls -d libcxx-*) )
'' + stdenv.lib.optionalString stdenv.isDarwin ''
export TRIPLE=x86_64-apple-darwin
'' + stdenv.lib.optionalString stdenv.hostPlatform.isMusl ''
patch -p1 -d $(ls -d libcxx-*) -i ${../libcxx-0001-musl-hacks.patch}
'';
+ cmakeFlags = stdenv.lib.optional (!enableShared) "-DLIBCXXABI_ENABLE_SHARED=OFF";
+
installPhase = if stdenv.isDarwin
then ''
for file in lib/*.dylib; do
@@ -34,10 +38,10 @@ stdenv.mkDerivation {
else ''
install -d -m 755 $out/include $out/lib
install -m 644 lib/libc++abi.a $out/lib
- install -m 644 lib/libc++abi.so.1.0 $out/lib
+ ${stdenv.lib.optionalString enableShared "install -m 644 lib/libc++abi.so.1.0 $out/lib"}
install -m 644 ../include/cxxabi.h $out/include
- ln -s libc++abi.so.1.0 $out/lib/libc++abi.so
- ln -s libc++abi.so.1.0 $out/lib/libc++abi.so.1
+ ${stdenv.lib.optionalString enableShared "ln -s libc++abi.so.1.0 $out/lib/libc++abi.so"}
+ ${stdenv.lib.optionalString enableShared "ln -s libc++abi.so.1.0 $out/lib/libc++abi.so.1"}
'';
meta = {
diff --git a/pkgs/development/compilers/openjdk/11.nix b/pkgs/development/compilers/openjdk/11.nix
index 57911f2d58e..e365b9b28b3 100644
--- a/pkgs/development/compilers/openjdk/11.nix
+++ b/pkgs/development/compilers/openjdk/11.nix
@@ -106,7 +106,7 @@ let
# Set JAVA_HOME automatically.
mkdir -p $out/nix-support
cat < $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out/lib/openjdk; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out/lib/openjdk; fi
EOF
'';
diff --git a/pkgs/development/compilers/openjdk/8.nix b/pkgs/development/compilers/openjdk/8.nix
index 1a5848cd1a6..ff3d03321e2 100644
--- a/pkgs/development/compilers/openjdk/8.nix
+++ b/pkgs/development/compilers/openjdk/8.nix
@@ -231,7 +231,7 @@ let
# Set JAVA_HOME automatically.
mkdir -p $out/nix-support
cat < $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out/lib/openjdk; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out/lib/openjdk; fi
EOF
'';
diff --git a/pkgs/development/compilers/openjdk/darwin/11.nix b/pkgs/development/compilers/openjdk/darwin/11.nix
index 4c808302b4f..0b659b95aa8 100644
--- a/pkgs/development/compilers/openjdk/darwin/11.nix
+++ b/pkgs/development/compilers/openjdk/darwin/11.nix
@@ -44,7 +44,7 @@ let
# Set JAVA_HOME automatically.
cat <> $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/openjdk/darwin/8.nix b/pkgs/development/compilers/openjdk/darwin/8.nix
index d2fef9bb481..bc7a33932b2 100644
--- a/pkgs/development/compilers/openjdk/darwin/8.nix
+++ b/pkgs/development/compilers/openjdk/darwin/8.nix
@@ -44,7 +44,7 @@ let
# Set JAVA_HOME automatically.
cat <> $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/openjdk/darwin/default.nix b/pkgs/development/compilers/openjdk/darwin/default.nix
index 58e4ba99014..c954a8e2cf8 100644
--- a/pkgs/development/compilers/openjdk/darwin/default.nix
+++ b/pkgs/development/compilers/openjdk/darwin/default.nix
@@ -44,7 +44,7 @@ let
# Set JAVA_HOME automatically.
cat <> $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/openjdk/default.nix b/pkgs/development/compilers/openjdk/default.nix
index 094bd57e6e9..03121daf961 100644
--- a/pkgs/development/compilers/openjdk/default.nix
+++ b/pkgs/development/compilers/openjdk/default.nix
@@ -114,7 +114,7 @@ let
# Set JAVA_HOME automatically.
mkdir -p $out/nix-support
cat < $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out/lib/openjdk; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out/lib/openjdk; fi
EOF
'';
diff --git a/pkgs/development/compilers/oraclejdk/jdk-linux-base.nix b/pkgs/development/compilers/oraclejdk/jdk-linux-base.nix
index 549395232f9..a96e703b28c 100644
--- a/pkgs/development/compilers/oraclejdk/jdk-linux-base.nix
+++ b/pkgs/development/compilers/oraclejdk/jdk-linux-base.nix
@@ -156,7 +156,7 @@ let result = stdenv.mkDerivation rec {
# Set JAVA_HOME automatically.
cat <> $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/reason/default.nix b/pkgs/development/compilers/reason/default.nix
index 5d7d0ce6684..20286dcc43c 100644
--- a/pkgs/development/compilers/reason/default.nix
+++ b/pkgs/development/compilers/reason/default.nix
@@ -27,8 +27,8 @@ stdenv.mkDerivation rec {
postInstall = ''
wrapProgram $out/bin/rtop \
--prefix PATH : "${utop}/bin" \
- --set CAML_LD_LIBRARY_PATH ${ocaml_lwt}/lib/ocaml/${ocaml.version}/site-lib:$CAML_LD_LIBRARY_PATH \
- --set OCAMLPATH $out/lib/ocaml/${ocaml.version}/site-lib:$OCAMLPATH
+ --prefix CAML_LD_LIBRARY_PATH : "${ocaml_lwt}/lib/ocaml/${ocaml.version}/site-lib" \
+ --prefix OCAMLPATH : "$out/lib/ocaml/${ocaml.version}/site-lib"
'';
meta = with stdenv.lib; {
diff --git a/pkgs/development/compilers/rust/rustc.nix b/pkgs/development/compilers/rust/rustc.nix
index 8a7d680010d..ceaf6f4c225 100644
--- a/pkgs/development/compilers/rust/rustc.nix
+++ b/pkgs/development/compilers/rust/rustc.nix
@@ -1,6 +1,6 @@
{ stdenv, removeReferencesTo, pkgsBuildBuild, pkgsBuildHost, pkgsBuildTarget
, fetchurl, file, python2
-, llvm_7, darwin, git, cmake, rustPlatform
+, llvm_9, darwin, git, cmake, rustPlatform
, pkgconfig, openssl
, which, libffi
, withBundledLLVM ? false
@@ -12,12 +12,12 @@ let
inherit (stdenv.lib) optional optionalString;
inherit (darwin.apple_sdk.frameworks) Security;
- llvmSharedForBuild = pkgsBuildBuild.llvm_7.override { enableSharedLibraries = true; };
- llvmSharedForHost = pkgsBuildHost.llvm_7.override { enableSharedLibraries = true; };
- llvmSharedForTarget = pkgsBuildTarget.llvm_7.override { enableSharedLibraries = true; };
+ llvmSharedForBuild = pkgsBuildBuild.llvm_9.override { enableSharedLibraries = true; };
+ llvmSharedForHost = pkgsBuildHost.llvm_9.override { enableSharedLibraries = true; };
+ llvmSharedForTarget = pkgsBuildTarget.llvm_9.override { enableSharedLibraries = true; };
# For use at runtime
- llvmShared = llvm_7.override { enableSharedLibraries = true; };
+ llvmShared = llvm_9.override { enableSharedLibraries = true; };
in stdenv.mkDerivation rec {
pname = "rustc";
inherit version;
diff --git a/pkgs/development/compilers/rust/setup-hook.sh b/pkgs/development/compilers/rust/setup-hook.sh
index 7078ec7060b..5d4eb642fec 100644
--- a/pkgs/development/compilers/rust/setup-hook.sh
+++ b/pkgs/development/compilers/rust/setup-hook.sh
@@ -1,4 +1,4 @@
# Fix 'failed to open: /homeless-shelter/.cargo/.package-cache' in rust 1.36.
-if [[ -z $IN_NIX_SHELL && -z $CARGO_HOME ]]; then
+if [[ -z ${IN_NIX_SHELL-} && -z ${CARGO_HOME-} ]]; then
export CARGO_HOME=$TMPDIR
fi
diff --git a/pkgs/development/compilers/zulu/8.nix b/pkgs/development/compilers/zulu/8.nix
index d4caabc6cb8..d05ec1a682a 100644
--- a/pkgs/development/compilers/zulu/8.nix
+++ b/pkgs/development/compilers/zulu/8.nix
@@ -58,7 +58,7 @@ in stdenv.mkDerivation {
# Set JAVA_HOME automatically.
cat <> $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/compilers/zulu/default.nix b/pkgs/development/compilers/zulu/default.nix
index 5f345c87355..5fe2473bac6 100644
--- a/pkgs/development/compilers/zulu/default.nix
+++ b/pkgs/development/compilers/zulu/default.nix
@@ -55,7 +55,7 @@ in stdenv.mkDerivation {
# Set JAVA_HOME automatically.
cat <> $out/nix-support/setup-hook
- if [ -z "\$JAVA_HOME" ]; then export JAVA_HOME=$out; fi
+ if [ -z "\''${JAVA_HOME-}" ]; then export JAVA_HOME=$out; fi
EOF
'';
diff --git a/pkgs/development/interpreters/lua-5/setup-hook.sh b/pkgs/development/interpreters/lua-5/setup-hook.sh
index f7e56b62ac9..1c445b82afd 100644
--- a/pkgs/development/interpreters/lua-5/setup-hook.sh
+++ b/pkgs/development/interpreters/lua-5/setup-hook.sh
@@ -20,7 +20,7 @@ addToLuaSearchPathWithCustomDelimiter() {
if [[ ! -d "$topDir" ]]; then return; fi
# export only if we haven't already got this dir in the search path
- if [[ ${!varName} == *"$absPattern"* ]]; then return; fi
+ if [[ ${!varName-} == *"$absPattern"* ]]; then return; fi
export "${varName}=${!varName:+${!varName};}${absPattern}"
}
diff --git a/pkgs/development/interpreters/octave/default.nix b/pkgs/development/interpreters/octave/default.nix
index cc9f6fcc3c9..66f71738537 100644
--- a/pkgs/development/interpreters/octave/default.nix
+++ b/pkgs/development/interpreters/octave/default.nix
@@ -1,5 +1,5 @@
{ stdenv, fetchurl, gfortran, readline, ncurses, perl, flex, texinfo, qhull
-, libsndfile, portaudio, libX11, graphicsmagick, pcre, pkgconfig, libGLU_combined, fltk
+, libsndfile, portaudio, libX11, graphicsmagick, pcre, pkgconfig, libGL, libGLU, fltk
, fftw, fftwSinglePrec, zlib, curl, qrupdate, openblas, arpack, libwebp
, qt ? null, qscintilla ? null, ghostscript ? null, llvm ? null, hdf5 ? null,glpk ? null
, suitesparse ? null, gnuplot ? null, jdk ? null, python ? null, overridePlatforms ? null
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
++ (stdenv.lib.optional (jdk != null) jdk)
++ (stdenv.lib.optional (gnuplot != null) gnuplot)
++ (stdenv.lib.optional (python != null) python)
- ++ (stdenv.lib.optionals (!stdenv.isDarwin) [ libGLU_combined libX11 ])
+ ++ (stdenv.lib.optionals (!stdenv.isDarwin) [ libGL libGLU libX11 ])
;
# makeinfo is required by Octave at runtime to display help
diff --git a/pkgs/development/interpreters/perl/default.nix b/pkgs/development/interpreters/perl/default.nix
index 2ecc5cbb2ef..4503fd0bf49 100644
--- a/pkgs/development/interpreters/perl/default.nix
+++ b/pkgs/development/interpreters/perl/default.nix
@@ -1,5 +1,5 @@
{ config, lib, stdenv, fetchurl, pkgs, buildPackages, callPackage
-, enableThreading ? stdenv ? glibc, makeWrapper
+, enableThreading ? stdenv ? glibc, coreutils, makeWrapper
}:
with lib;
@@ -35,7 +35,7 @@ let
# TODO: Add a "dev" output containing the header files.
outputs = [ "out" "man" "devdoc" ] ++
- stdenv.lib.optional crossCompiling "dev";
+ optional crossCompiling "dev";
setOutputFlags = false;
disallowedReferences = [ stdenv.cc ];
@@ -57,12 +57,20 @@ let
++ optionals stdenv.isDarwin [ ./cpp-precomp.patch ./sw_vers.patch ]
++ optional crossCompiling ./MakeMaker-cross.patch;
- postPatch = ''
- pwd="$(type -P pwd)"
+ # This is not done for native builds because pwd may need to come from
+ # bootstrap tools when building bootstrap perl.
+ postPatch = (if crossCompiling then ''
substituteInPlace dist/PathTools/Cwd.pm \
- --replace "/bin/pwd" "$pwd"
- '' + stdenv.lib.optionalString crossCompiling ''
+ --replace "/bin/pwd" '${coreutils}/bin/pwd'
substituteInPlace cnf/configure_tool.sh --replace "cc -E -P" "cc -E"
+ '' else ''
+ substituteInPlace dist/PathTools/Cwd.pm \
+ --replace "/bin/pwd" "$(type -P pwd)"
+ '') +
+ # Perl's build system uses the src variable, and its value may end up in
+ # the output in some cases (when cross-compiling)
+ ''
+ unset src
'';
# Build a thread-safe Perl with a dynamic libperls.o. We need the
@@ -85,7 +93,7 @@ let
++ optional stdenv.isSunOS "-Dcc=gcc"
++ optional enableThreading "-Dusethreads";
- configureScript = stdenv.lib.optionalString (!crossCompiling) "${stdenv.shell} ./Configure";
+ configureScript = optionalString (!crossCompiling) "${stdenv.shell} ./Configure";
dontAddPrefix = !crossCompiling;
@@ -140,7 +148,7 @@ let
}" /no-such-path \
--replace "${stdenv.cc}" /no-such-path \
--replace "$man" /no-such-path
- '' + stdenv.lib.optionalString crossCompiling
+ '' + optionalString crossCompiling
''
mkdir -p $dev/lib/perl5/cross_perl/${version}
for dir in cnf/{stub,cpan}; do
@@ -172,7 +180,7 @@ let
platforms = platforms.all;
priority = 6; # in `buildEnv' (including the one inside `perl.withPackages') the library files will have priority over files in `perl`
};
- } // stdenv.lib.optionalAttrs (stdenv.buildPlatform != stdenv.hostPlatform) rec {
+ } // optionalAttrs (stdenv.buildPlatform != stdenv.hostPlatform) rec {
crossVersion = "980998f7d11baf97284426ca91f84681d49a08f5"; # Jul 20, 2019
perl-cross-src = fetchurl {
diff --git a/pkgs/development/interpreters/python/hooks/flit-build-hook.sh b/pkgs/development/interpreters/python/hooks/flit-build-hook.sh
index 48295dc3643..45893aae00f 100644
--- a/pkgs/development/interpreters/python/hooks/flit-build-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/flit-build-hook.sh
@@ -9,7 +9,7 @@ flitBuildPhase () {
echo "Finished executing flitBuildPhase"
}
-if [ -z "$dontUseFlitBuild" ] && [ -z "$buildPhase" ]; then
+if [ -z "${dontUseFlitBuild-}" ] && [ -z "${buildPhase-}" ]; then
echo "Using flitBuildPhase"
buildPhase=flitBuildPhase
fi
diff --git a/pkgs/development/interpreters/python/hooks/pip-build-hook.sh b/pkgs/development/interpreters/python/hooks/pip-build-hook.sh
index c297bfffb1e..a58c01ce808 100644
--- a/pkgs/development/interpreters/python/hooks/pip-build-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/pip-build-hook.sh
@@ -31,7 +31,7 @@ pipShellHook() {
echo "Finished executing pipShellHook"
}
-if [ -z "$dontUsePipBuild" ] && [ -z "$buildPhase" ]; then
+if [ -z "${dontUsePipBuild-}" ] && [ -z "${buildPhase-}" ]; then
echo "Using pipBuildPhase"
buildPhase=pipBuildPhase
fi
diff --git a/pkgs/development/interpreters/python/hooks/pip-install-hook.sh b/pkgs/development/interpreters/python/hooks/pip-install-hook.sh
index f528ec63cb8..4eefe22d3f2 100644
--- a/pkgs/development/interpreters/python/hooks/pip-install-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/pip-install-hook.sh
@@ -18,7 +18,7 @@ pipInstallPhase() {
echo "Finished executing pipInstallPhase"
}
-if [ -z "$dontUsePipInstall" ] && [ -z "$installPhase" ]; then
+if [ -z "${dontUsePipInstall-}" ] && [ -z "${installPhase-}" ]; then
echo "Using pipInstallPhase"
installPhase=pipInstallPhase
fi
diff --git a/pkgs/development/interpreters/python/hooks/pytest-check-hook.sh b/pkgs/development/interpreters/python/hooks/pytest-check-hook.sh
index 24510b9f993..18f05b6d218 100644
--- a/pkgs/development/interpreters/python/hooks/pytest-check-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/pytest-check-hook.sh
@@ -43,7 +43,7 @@ function pytestCheckPhase() {
echo "Finished executing pytestCheckPhase"
}
-if [ -z "$dontUsePytestCheck" ] && [ -z "$installCheckPhase" ]; then
+if [ -z "${dontUsePytestCheck-}" ] && [ -z "${installCheckPhase-}" ]; then
echo "Using pytestCheckPhase"
preDistPhases+=" pytestCheckPhase"
fi
diff --git a/pkgs/development/interpreters/python/hooks/python-catch-conflicts-hook.sh b/pkgs/development/interpreters/python/hooks/python-catch-conflicts-hook.sh
index e9065cf1793..374a2eddb40 100644
--- a/pkgs/development/interpreters/python/hooks/python-catch-conflicts-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/python-catch-conflicts-hook.sh
@@ -5,6 +5,6 @@ pythonCatchConflictsPhase() {
@pythonInterpreter@ @catchConflicts@
}
-if [ -z "$dontUsePythonCatchConflicts" ]; then
+if [ -z "${dontUsePythonCatchConflicts-}" ]; then
preDistPhases+=" pythonCatchConflictsPhase"
fi
diff --git a/pkgs/development/interpreters/python/hooks/python-imports-check-hook.sh b/pkgs/development/interpreters/python/hooks/python-imports-check-hook.sh
index 7e2b3f69d6d..0fc55145a8e 100644
--- a/pkgs/development/interpreters/python/hooks/python-imports-check-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/python-imports-check-hook.sh
@@ -10,7 +10,7 @@ pythonImportsCheckPhase () {
fi
}
-if [ -z "$dontUsePythonImportsCheck" ]; then
+if [ -z "${dontUsePythonImportsCheck-}" ]; then
echo "Using pythonImportsCheckPhase"
preDistPhases+=" pythonImportsCheckPhase"
fi
diff --git a/pkgs/development/interpreters/python/hooks/python-remove-bin-bytecode-hook.sh b/pkgs/development/interpreters/python/hooks/python-remove-bin-bytecode-hook.sh
index 960de767be7..2add23f2316 100644
--- a/pkgs/development/interpreters/python/hooks/python-remove-bin-bytecode-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/python-remove-bin-bytecode-hook.sh
@@ -12,6 +12,6 @@ pythonRemoveBinBytecodePhase () {
fi
}
-if [ -z "$dontUsePythonRemoveBinBytecode" ]; then
+if [ -z "${dontUsePythonRemoveBinBytecode-}" ]; then
preDistPhases+=" pythonRemoveBinBytecodePhase"
fi
diff --git a/pkgs/development/interpreters/python/hooks/setuptools-build-hook.sh b/pkgs/development/interpreters/python/hooks/setuptools-build-hook.sh
index 322a0336df2..2aec9279382 100644
--- a/pkgs/development/interpreters/python/hooks/setuptools-build-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/setuptools-build-hook.sh
@@ -36,12 +36,12 @@ setuptoolsShellHook() {
echo "Finished executing setuptoolsShellHook"
}
-if [ -z "$dontUseSetuptoolsBuild" ] && [ -z "$buildPhase" ]; then
+if [ -z "${dontUseSetuptoolsBuild-}" ] && [ -z "${buildPhase-}" ]; then
echo "Using setuptoolsBuildPhase"
buildPhase=setuptoolsBuildPhase
fi
-if [ -z "$dontUseSetuptoolsShellHook" ] && [ -z "$shellHook" ]; then
+if [ -z "${dontUseSetuptoolsShellHook-}" ] && [ -z "${shellHook-}" ]; then
echo "Using setuptoolsShellHook"
shellHook=setuptoolsShellHook
fi
diff --git a/pkgs/development/interpreters/python/hooks/setuptools-check-hook.sh b/pkgs/development/interpreters/python/hooks/setuptools-check-hook.sh
index 71bb036a91a..88b7b11931b 100644
--- a/pkgs/development/interpreters/python/hooks/setuptools-check-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/setuptools-check-hook.sh
@@ -12,7 +12,7 @@ setuptoolsCheckPhase() {
echo "Finished executing setuptoolsCheckPhase"
}
-if [ -z "$dontUseSetuptoolsCheck" ] && [ -z "$installCheckPhase" ]; then
+if [ -z "${dontUseSetuptoolsCheck-}" ] && [ -z "${installCheckPhase-}" ]; then
echo "Using setuptoolsCheckPhase"
preDistPhases+=" setuptoolsCheckPhase"
fi
diff --git a/pkgs/development/interpreters/python/hooks/wheel-unpack-hook.sh b/pkgs/development/interpreters/python/hooks/wheel-unpack-hook.sh
index 6dd0c5be4cb..fca808a933b 100644
--- a/pkgs/development/interpreters/python/hooks/wheel-unpack-hook.sh
+++ b/pkgs/development/interpreters/python/hooks/wheel-unpack-hook.sh
@@ -12,7 +12,7 @@ wheelUnpackPhase(){
echo "Finished executing wheelUnpackPhase"
}
-if [ -z "$dontUseWheelUnpack" ] && [ -z "$unpackPhase" ]; then
+if [ -z "${dontUseWheelUnpack-}" ] && [ -z "${unpackPhase-}" ]; then
echo "Using wheelUnpackPhase"
unpackPhase=wheelUnpackPhase
fi
diff --git a/pkgs/development/libraries/SDL/setup-hook.sh b/pkgs/development/libraries/SDL/setup-hook.sh
index e8f96fdd1ac..f3176f3a304 100644
--- a/pkgs/development/libraries/SDL/setup-hook.sh
+++ b/pkgs/development/libraries/SDL/setup-hook.sh
@@ -1,7 +1,9 @@
addSDLPath () {
if [ -e "$1/include/SDL" ]; then
- export SDL_PATH="$SDL_PATH $1/include/SDL"
- export SDL_LIB_PATH="$SDL_LIB_PATH -L$1/lib"
+ export SDL_PATH="${SDL_PATH-}${SDL_PATH:+ }$1/include/SDL"
+ fi
+ if [ -e "$1/lib" ]; then
+ export SDL_LIB_PATH="${SDL_LIB_PATH-}${SDL_LIB_PATH:+ }$1/lib"
fi
}
diff --git a/pkgs/development/libraries/SDL2/default.nix b/pkgs/development/libraries/SDL2/default.nix
index 8fe6bbe6113..e02ea05a726 100644
--- a/pkgs/development/libraries/SDL2/default.nix
+++ b/pkgs/development/libraries/SDL2/default.nix
@@ -75,9 +75,21 @@ stdenv.mkDerivation rec {
++ optional alsaSupport "--with-alsa-prefix=${alsaLib.out}/lib"
++ optional stdenv.isDarwin "--disable-sdltest";
+ # We remove libtool .la files when static libs are requested,
+ # because they make the builds of downstream libs like `SDL_tff`
+ # fail with `cannot find -lXext, `-lXcursor` etc. linker errors
+ # because the `.la` files are not pruned if static libs exist
+ # (see https://github.com/NixOS/nixpkgs/commit/fd97db43bcb05e37f6bb77f363f1e1e239d9de53)
+ # and they also don't carry the necessary `-L` paths of their
+ # X11 dependencies.
+ # For static linking, it is better to rely on `pkg-config` `.pc`
+ # files.
postInstall = ''
- moveToOutput lib/libSDL2main.a "$dev"
- rm $out/lib/*.a
+ if [ "$dontDisableStatic" -eq "1" ]; then
+ rm $out/lib/*.la
+ else
+ rm $out/lib/*.a
+ fi
moveToOutput bin/sdl2-config "$dev"
'';
diff --git a/pkgs/development/libraries/SDL2/setup-hook.sh b/pkgs/development/libraries/SDL2/setup-hook.sh
index 3acce9d473c..0119926491a 100644
--- a/pkgs/development/libraries/SDL2/setup-hook.sh
+++ b/pkgs/development/libraries/SDL2/setup-hook.sh
@@ -1,6 +1,6 @@
addSDL2Path () {
if [ -e "$1/include/SDL2" ]; then
- export SDL2_PATH="$SDL2_PATH $1/include/SDL2"
+ export SDL2_PATH="${SDL2_PATH-}${SDL2_PATH:+ }$1/include/SDL2"
fi
}
diff --git a/pkgs/development/libraries/clutter/default.nix b/pkgs/development/libraries/clutter/default.nix
index 7095a808540..32e723671e8 100644
--- a/pkgs/development/libraries/clutter/default.nix
+++ b/pkgs/development/libraries/clutter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libGLU_combined, libX11, libXext, libXfixes
+{ stdenv, fetchurl, pkgconfig, libGLU, libGL, libX11, libXext, libXfixes
, libXdamage, libXcomposite, libXi, libxcb, cogl, pango, atk, json-glib
, gobject-introspection, gtk3, gnome3, libinput, libgudev, libxkbcommon
}:
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
buildInputs = [ gtk3 ];
nativeBuildInputs = [ pkgconfig ];
propagatedBuildInputs =
- [ libX11 libGLU_combined libXext libXfixes libXdamage libXcomposite libXi cogl pango
+ [ libX11 libGL libGLU libXext libXfixes libXdamage libXcomposite libXi cogl pango
atk json-glib gobject-introspection libxcb libinput libgudev libxkbcommon
];
diff --git a/pkgs/development/libraries/cogl/default.nix b/pkgs/development/libraries/cogl/default.nix
index 4700d9e2418..e122c1e7b12 100644
--- a/pkgs/development/libraries/cogl/default.nix
+++ b/pkgs/development/libraries/cogl/default.nix
@@ -1,6 +1,6 @@
{ stdenv, fetchurl, fetchpatch, pkgconfig, libGL, glib, gdk-pixbuf, xorg, libintl
, pangoSupport ? true, pango, cairo, gobject-introspection, wayland, gnome3
-, mesa
+, mesa, automake, autoconf
, gstreamerSupport ? true, gst_all_1 }:
let
@@ -29,11 +29,17 @@ in stdenv.mkDerivation rec {
url = https://bug787443.bugzilla-attachments.gnome.org/attachment.cgi?id=361056;
sha256 = "09fyrdci4727fg6qm5aaapsbv71sf4wgfaqz8jqlyy61dibgg490";
})
+
+ # Fix build with libglvnd headers (these headers used to be provided by mesa)
+ (fetchpatch {
+ url = "https://gitlab.gnome.org/GNOME/cogl/commit/9c4764224aded552fb855b1c2b85b26d2b894adf.patch";
+ sha256 = "1v9drpzgcd5pq2shhdcw5px7mdiggk6ga13qjbklq8xpd92ac0i1";
+ })
];
outputs = [ "out" "dev" ];
- nativeBuildInputs = [ pkgconfig libintl ];
+ nativeBuildInputs = [ pkgconfig libintl automake autoconf ];
configureFlags = [
"--enable-introspection"
@@ -41,7 +47,7 @@ in stdenv.mkDerivation rec {
"--enable-wayland-egl-platform"
"--enable-wayland-egl-server"
] ++ stdenv.lib.optional gstreamerSupport "--enable-cogl-gst"
- ++ stdenv.lib.optionals (!stdenv.isDarwin) [ "--enable-gles1" "--enable-gles2" ];
+ ++ stdenv.lib.optionals (!stdenv.isDarwin) [ "--enable-gles1" "--enable-gles2" ];
propagatedBuildInputs = with xorg; [
glib gdk-pixbuf gobject-introspection wayland mesa
diff --git a/pkgs/development/libraries/coin3d/default.nix b/pkgs/development/libraries/coin3d/default.nix
index 74fd12ffea2..634ac27058b 100644
--- a/pkgs/development/libraries/coin3d/default.nix
+++ b/pkgs/development/libraries/coin3d/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromBitbucket, stdenv, boost, cmake, libGLU_combined }:
+{ fetchFromBitbucket, stdenv, boost, cmake, libGL, libGLU }:
stdenv.mkDerivation {
pname = "coin";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
'';
nativeBuildInputs = [ cmake ];
- buildInputs = [ boost libGLU_combined ];
+ buildInputs = [ boost libGL libGLU ];
meta = {
homepage = "https://bitbucket.org/Coin3D/coin/wiki/Home";
diff --git a/pkgs/development/libraries/ffmpeg/generic.nix b/pkgs/development/libraries/ffmpeg/generic.nix
index b3310e44ae0..ccdf4662719 100644
--- a/pkgs/development/libraries/ffmpeg/generic.nix
+++ b/pkgs/development/libraries/ffmpeg/generic.nix
@@ -3,6 +3,8 @@
, libssh, libtheora, libva, libdrm, libvorbis, libvpx, lzma, libpulseaudio, soxr
, x264, x265, xvidcore, zlib, libopus, speex, nv-codec-headers, dav1d
, openglSupport ? false, libGLU_combined ? null
+, libmfxSupport ? false, intel-media-sdk ? null
+, libaomSupport ? false, libaom ? null
# Build options
, runtimeCpuDetectBuild ? true # Detect CPU capabilities at runtime
, multithreadBuild ? true # Multithreading via pthreads/win32 threads
@@ -62,6 +64,8 @@ let
in
assert openglSupport -> libGLU_combined != null;
+assert libmfxSupport -> intel-media-sdk != null;
+assert libaomSupport -> libaom != null;
stdenv.mkDerivation rec {
@@ -135,6 +139,8 @@ stdenv.mkDerivation rec {
(ifMinVer "0.6" (enableFeature vpxSupport "libvpx"))
(ifMinVer "2.4" "--enable-lzma")
(ifMinVer "2.2" (enableFeature openglSupport "opengl"))
+ (ifMinVer "4.2" (enableFeature libmfxSupport "libmfx"))
+ (ifMinVer "4.2" (enableFeature libaomSupport "libaom"))
(disDarwinOrArmFix (ifMinVer "0.9" "--enable-libpulse") "0.9" "--disable-libpulse")
(ifMinVer "2.5" (if sdlSupport && reqMin "3.2" then "--enable-sdl2" else if sdlSupport then "--enable-sdl" else null)) # autodetected before 2.5, SDL1 support removed in 3.2 for SDL2
(ifMinVer "1.2" "--enable-libsoxr")
@@ -163,6 +169,8 @@ stdenv.mkDerivation rec {
bzip2 fontconfig freetype gnutls libiconv lame libass libogg libssh libtheora
libvdpau libvorbis lzma soxr x264 x265 xvidcore zlib libopus speex nv-codec-headers
] ++ optional openglSupport libGLU_combined
+ ++ optional libmfxSupport intel-media-sdk
+ ++ optional vpxSupport libaom
++ optional vpxSupport libvpx
++ optionals (!isDarwin && !isAarch32) [ libpulseaudio ] # Need to be fixed on Darwin and ARM
++ optional ((isLinux || isFreeBSD) && !isAarch32) libva
diff --git a/pkgs/development/libraries/fltk/default.nix b/pkgs/development/libraries/fltk/default.nix
index a22b5eef8d2..6f185e38d83 100644
--- a/pkgs/development/libraries/fltk/default.nix
+++ b/pkgs/development/libraries/fltk/default.nix
@@ -1,5 +1,5 @@
{ stdenv, fetchurl, pkgconfig, xlibsWrapper, xorgproto, libXi
-, freeglut, libGLU_combined, libjpeg, zlib, libXft, libpng
+, freeglut, libGL, libGLU, libjpeg, zlib, libXft, libpng
, libtiff, freetype, Cocoa, AGL, GLUT
}:
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
patches = stdenv.lib.optionals stdenv.isDarwin [ ./nsosv.patch ];
nativeBuildInputs = [ pkgconfig ];
- buildInputs = [ libGLU_combined libjpeg zlib libpng libXft ]
+ buildInputs = [ libGLU libGL libjpeg zlib libpng libXft ]
++ stdenv.lib.optional stdenv.isDarwin [ AGL Cocoa GLUT ];
propagatedBuildInputs = [ xorgproto ]
diff --git a/pkgs/development/libraries/fribidi/default.nix b/pkgs/development/libraries/fribidi/default.nix
index 859258f5956..3b0b30f573b 100644
--- a/pkgs/development/libraries/fribidi/default.nix
+++ b/pkgs/development/libraries/fribidi/default.nix
@@ -20,6 +20,14 @@ stdenv.mkDerivation rec {
sha256 = "0pckda4fcn0aw32lpycwdp25r2m7vca8zspq815ppi9gkwgg5das";
};
+ patches = [
+ (fetchpatch {
+ name = "CVE-2019-18397.patch";
+ url = "https://github.com/fribidi/fribidi/commit/034c6e9a1d296286305f4cfd1e0072b879f52568.patch";
+ sha256 = "102xrbf1l5gvavkxd6csx8pj3rlgcw10c0y4h4d40yhn84b1p0y8";
+ })
+ ];
+
postPatch = ''
patchShebangs test
'';
diff --git a/pkgs/development/libraries/ftgl/default.nix b/pkgs/development/libraries/ftgl/default.nix
index 289a5739985..a99228efcf4 100644
--- a/pkgs/development/libraries/ftgl/default.nix
+++ b/pkgs/development/libraries/ftgl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, freetype, libGLU_combined, OpenGL }:
+{ stdenv, fetchurl, freetype, libGL, libGLU, OpenGL }:
let
name = "ftgl-2.1.3-rc5";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
++ (if stdenv.isDarwin then
[ OpenGL ]
else
- [ libGLU_combined ])
+ [ libGL libGLU ])
;
enableParallelBuilding = true;
diff --git a/pkgs/development/libraries/gcr/default.nix b/pkgs/development/libraries/gcr/default.nix
index 1947d40dc85..cf0f22fdd40 100644
--- a/pkgs/development/libraries/gcr/default.nix
+++ b/pkgs/development/libraries/gcr/default.nix
@@ -1,49 +1,84 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gnupg, p11-kit, glib
-, libgcrypt, libtasn1, dbus-glib, gtk3, pango, gdk-pixbuf, atk
-, gobject-introspection, makeWrapper, libxslt, vala, gnome3
-, python3 }:
+{ stdenv
+, fetchurl
+, pkgconfig
+, gettext
+, gnupg
+, p11-kit
+, glib
+, libgcrypt
+, libtasn1
+, gtk3
+, pango
+, gobject-introspection
+, makeWrapper
+, libxslt
+, vala
+, gnome3
+, python3
+}:
stdenv.mkDerivation rec {
pname = "gcr";
- version = "3.33.4";
+ version = "3.34.0";
src = fetchurl {
url = "mirror://gnome/sources/${pname}/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
- sha256 = "1hf06p4qfyywnb6334ysnr6aqxik3srb37glclvr4yhb3wzrjqnm";
- };
-
- passthru = {
- updateScript = gnome3.updateScript { packageName = pname; };
+ sha256 = "0925snsixzkwh49xiayqmj6fcrmklqk8kyy0jkv7m64h9abm1pr9";
};
postPatch = ''
- patchShebangs .
+ patchShebangs build/ gcr/fixtures/
'';
outputs = [ "out" "dev" ];
- nativeBuildInputs = [ pkgconfig gettext gobject-introspection libxslt makeWrapper vala ];
+ nativeBuildInputs = [
+ pkgconfig
+ gettext
+ gobject-introspection
+ libxslt
+ makeWrapper
+ vala
+ ];
- buildInputs = [ gnupg libgcrypt libtasn1 dbus-glib pango gdk-pixbuf atk ];
+ buildInputs = [
+ gnupg
+ libgcrypt
+ libtasn1
+ pango
+ ];
- propagatedBuildInputs = [ glib gtk3 p11-kit ];
+ propagatedBuildInputs = [
+ glib
+ gtk3
+ p11-kit
+ ];
+
+ checkInputs = [
+ python3
+ ];
- checkInputs = [ python3 ];
doCheck = false; # fails 21 out of 603 tests, needs dbus daemon
- #enableParallelBuilding = true; issues on hydra
+ enableParallelBuilding = true;
preFixup = ''
wrapProgram "$out/bin/gcr-viewer" \
--prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
'';
+ passthru = {
+ updateScript = gnome3.updateScript {
+ packageName = pname;
+ };
+ };
+
meta = with stdenv.lib; {
platforms = platforms.linux;
maintainers = gnome3.maintainers;
description = "GNOME crypto services (daemon and tools)";
- homepage = https://gitlab.gnome.org/GNOME/gcr;
- license = licenses.gpl2;
+ homepage = "https://gitlab.gnome.org/GNOME/gcr";
+ license = licenses.lgpl2Plus;
longDescription = ''
GCR is a library for displaying certificates, and crypto UI, accessing
diff --git a/pkgs/development/libraries/gdk-pixbuf/setup-hook.sh b/pkgs/development/libraries/gdk-pixbuf/setup-hook.sh
index 5a7dcd79299..8b6c80867a0 100644
--- a/pkgs/development/libraries/gdk-pixbuf/setup-hook.sh
+++ b/pkgs/development/libraries/gdk-pixbuf/setup-hook.sh
@@ -2,9 +2,9 @@ findGdkPixbufLoaders() {
# choose the longest loaders.cache
local loadersCache="$1/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache"
- if [ -f "$loadersCache" ]; then
- if [ -f "$GDK_PIXBUF_MODULE_FILE" ]; then
- if [ $(cat "$loadersCache"|wc -l) -gt $(cat "$GDK_PIXBUF_MODULE_FILE"|wc -l) ]; then
+ if [[ -f "$loadersCache" ]]; then
+ if [[ -f "${GDK_PIXBUF_MODULE_FILE-}" ]]; then
+ if [[ "$(cat "$loadersCache" | wc -l)" > "$(cat "$GDK_PIXBUF_MODULE_FILE" | wc -l)" ]]; then
export GDK_PIXBUF_MODULE_FILE="$loadersCache"
fi
else
diff --git a/pkgs/development/libraries/gettext/CVE-2018-18751-bison.patch b/pkgs/development/libraries/gettext/CVE-2018-18751-bison.patch
deleted file mode 100644
index b734c1c8b02..00000000000
--- a/pkgs/development/libraries/gettext/CVE-2018-18751-bison.patch
+++ /dev/null
@@ -1,323 +0,0 @@
-This patch was generated by re-running Bison 3.0.4 on pro-gram-gen.y after
-applying CVE-2018-18751.patch. This patch removes the need to add bison to
-nativeBuildInputs.
-
---- a/gettext-tools/src/po-gram-gen.c
-+++ b/gettext-tools/src/po-gram-gen.c
-@@ -568,9 +568,9 @@ static const yytype_uint8 yytranslate[] =
- static const yytype_uint16 yyrline[] =
- {
- 0, 169, 169, 171, 172, 173, 174, 179, 187, 195,
-- 216, 240, 249, 258, 269, 278, 292, 301, 315, 321,
-- 332, 338, 350, 361, 372, 376, 391, 414, 422, 434,
-- 442
-+ 216, 237, 246, 255, 266, 275, 289, 298, 312, 318,
-+ 329, 335, 347, 358, 369, 373, 388, 411, 419, 431,
-+ 439
- };
- #endif
-
-@@ -1419,14 +1419,11 @@ yyreduce:
- check_obsolete ((yyvsp[-3].message_intro), (yyvsp[-1].string));
- check_obsolete ((yyvsp[-3].message_intro), (yyvsp[0].rhs));
- if (!(yyvsp[-3].message_intro).obsolete || pass_obsolete_entries)
-- {
-- do_callback_message ((yyvsp[-3].message_intro).ctxt, string2, &(yyvsp[-3].message_intro).pos, (yyvsp[-1].string).string,
-- (yyvsp[0].rhs).rhs.msgstr, (yyvsp[0].rhs).rhs.msgstr_len, &(yyvsp[0].rhs).pos,
-- (yyvsp[-3].message_intro).prev_ctxt,
-- (yyvsp[-3].message_intro).prev_id, (yyvsp[-3].message_intro).prev_id_plural,
-- (yyvsp[-3].message_intro).obsolete);
-- free ((yyvsp[-1].string).string);
-- }
-+ do_callback_message ((yyvsp[-3].message_intro).ctxt, string2, &(yyvsp[-3].message_intro).pos, (yyvsp[-1].string).string,
-+ (yyvsp[0].rhs).rhs.msgstr, (yyvsp[0].rhs).rhs.msgstr_len, &(yyvsp[0].rhs).pos,
-+ (yyvsp[-3].message_intro).prev_ctxt,
-+ (yyvsp[-3].message_intro).prev_id, (yyvsp[-3].message_intro).prev_id_plural,
-+ (yyvsp[-3].message_intro).obsolete);
- else
- {
- free_message_intro ((yyvsp[-3].message_intro));
-@@ -1435,11 +1432,11 @@ yyreduce:
- free ((yyvsp[0].rhs).rhs.msgstr);
- }
- }
--#line 1439 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1436 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 11:
--#line 241 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 238 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-2].message_intro), (yyvsp[-1].stringlist));
- check_obsolete ((yyvsp[-2].message_intro), (yyvsp[0].string));
-@@ -1448,11 +1445,11 @@ yyreduce:
- string_list_destroy (&(yyvsp[-1].stringlist).stringlist);
- free ((yyvsp[0].string).string);
- }
--#line 1452 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1449 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 12:
--#line 250 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 247 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-2].message_intro), (yyvsp[-1].stringlist));
- check_obsolete ((yyvsp[-2].message_intro), (yyvsp[0].rhs));
-@@ -1461,22 +1458,22 @@ yyreduce:
- string_list_destroy (&(yyvsp[-1].stringlist).stringlist);
- free ((yyvsp[0].rhs).rhs.msgstr);
- }
--#line 1465 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1462 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 13:
--#line 259 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 256 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].message_intro), (yyvsp[0].stringlist));
- po_gram_error_at_line (&(yyvsp[-1].message_intro).pos, _("missing 'msgstr' section"));
- free_message_intro ((yyvsp[-1].message_intro));
- string_list_destroy (&(yyvsp[0].stringlist).stringlist);
- }
--#line 1476 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1473 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 14:
--#line 270 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 267 "po-gram-gen.y" /* yacc.c:1646 */
- {
- (yyval.message_intro).prev_ctxt = NULL;
- (yyval.message_intro).prev_id = NULL;
-@@ -1485,11 +1482,11 @@ yyreduce:
- (yyval.message_intro).pos = (yyvsp[0].string).pos;
- (yyval.message_intro).obsolete = (yyvsp[0].string).obsolete;
- }
--#line 1489 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1486 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 15:
--#line 279 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 276 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].prev), (yyvsp[0].string));
- (yyval.message_intro).prev_ctxt = (yyvsp[-1].prev).ctxt;
-@@ -1499,11 +1496,11 @@ yyreduce:
- (yyval.message_intro).pos = (yyvsp[0].string).pos;
- (yyval.message_intro).obsolete = (yyvsp[0].string).obsolete;
- }
--#line 1503 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1500 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 16:
--#line 293 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 290 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].string), (yyvsp[0].stringlist));
- (yyval.prev).ctxt = (yyvsp[-1].string).string;
-@@ -1512,11 +1509,11 @@ yyreduce:
- (yyval.prev).pos = (yyvsp[-1].string).pos;
- (yyval.prev).obsolete = (yyvsp[-1].string).obsolete;
- }
--#line 1516 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1513 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 17:
--#line 302 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 299 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-2].string), (yyvsp[-1].stringlist));
- check_obsolete ((yyvsp[-2].string), (yyvsp[0].string));
-@@ -1526,21 +1523,21 @@ yyreduce:
- (yyval.prev).pos = (yyvsp[-2].string).pos;
- (yyval.prev).obsolete = (yyvsp[-2].string).obsolete;
- }
--#line 1530 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1527 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 18:
--#line 316 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 313 "po-gram-gen.y" /* yacc.c:1646 */
- {
- (yyval.string).string = NULL;
- (yyval.string).pos = (yyvsp[0].pos).pos;
- (yyval.string).obsolete = (yyvsp[0].pos).obsolete;
- }
--#line 1540 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1537 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 19:
--#line 322 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 319 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-2].pos), (yyvsp[-1].stringlist));
- check_obsolete ((yyvsp[-2].pos), (yyvsp[0].pos));
-@@ -1548,21 +1545,21 @@ yyreduce:
- (yyval.string).pos = (yyvsp[0].pos).pos;
- (yyval.string).obsolete = (yyvsp[0].pos).obsolete;
- }
--#line 1552 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1549 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 20:
--#line 333 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 330 "po-gram-gen.y" /* yacc.c:1646 */
- {
- (yyval.string).string = NULL;
- (yyval.string).pos = (yyvsp[0].pos).pos;
- (yyval.string).obsolete = (yyvsp[0].pos).obsolete;
- }
--#line 1562 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1559 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 21:
--#line 339 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 336 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-2].pos), (yyvsp[-1].stringlist));
- check_obsolete ((yyvsp[-2].pos), (yyvsp[0].pos));
-@@ -1570,11 +1567,11 @@ yyreduce:
- (yyval.string).pos = (yyvsp[0].pos).pos;
- (yyval.string).obsolete = (yyvsp[0].pos).obsolete;
- }
--#line 1574 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1571 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 22:
--#line 351 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 348 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].pos), (yyvsp[0].stringlist));
- plural_counter = 0;
-@@ -1582,30 +1579,30 @@ yyreduce:
- (yyval.string).pos = (yyvsp[-1].pos).pos;
- (yyval.string).obsolete = (yyvsp[-1].pos).obsolete;
- }
--#line 1586 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1583 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 23:
--#line 362 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 359 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].pos), (yyvsp[0].stringlist));
- (yyval.string).string = string_list_concat_destroy (&(yyvsp[0].stringlist).stringlist);
- (yyval.string).pos = (yyvsp[-1].pos).pos;
- (yyval.string).obsolete = (yyvsp[-1].pos).obsolete;
- }
--#line 1597 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1594 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 24:
--#line 373 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 370 "po-gram-gen.y" /* yacc.c:1646 */
- {
- (yyval.rhs) = (yyvsp[0].rhs);
- }
--#line 1605 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1602 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 25:
--#line 377 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 374 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].rhs), (yyvsp[0].rhs));
- (yyval.rhs).rhs.msgstr = XNMALLOC ((yyvsp[-1].rhs).rhs.msgstr_len + (yyvsp[0].rhs).rhs.msgstr_len, char);
-@@ -1617,11 +1614,11 @@ yyreduce:
- (yyval.rhs).pos = (yyvsp[-1].rhs).pos;
- (yyval.rhs).obsolete = (yyvsp[-1].rhs).obsolete;
- }
--#line 1621 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1618 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 26:
--#line 392 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 389 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-4].pos), (yyvsp[-3].pos));
- check_obsolete ((yyvsp[-4].pos), (yyvsp[-2].number));
-@@ -1640,11 +1637,11 @@ yyreduce:
- (yyval.rhs).pos = (yyvsp[-4].pos).pos;
- (yyval.rhs).obsolete = (yyvsp[-4].pos).obsolete;
- }
--#line 1644 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1641 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 27:
--#line 415 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 412 "po-gram-gen.y" /* yacc.c:1646 */
- {
- string_list_init (&(yyval.stringlist).stringlist);
- string_list_append (&(yyval.stringlist).stringlist, (yyvsp[0].string).string);
-@@ -1652,11 +1649,11 @@ yyreduce:
- (yyval.stringlist).pos = (yyvsp[0].string).pos;
- (yyval.stringlist).obsolete = (yyvsp[0].string).obsolete;
- }
--#line 1656 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1653 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 28:
--#line 423 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 420 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].stringlist), (yyvsp[0].string));
- (yyval.stringlist).stringlist = (yyvsp[-1].stringlist).stringlist;
-@@ -1665,11 +1662,11 @@ yyreduce:
- (yyval.stringlist).pos = (yyvsp[-1].stringlist).pos;
- (yyval.stringlist).obsolete = (yyvsp[-1].stringlist).obsolete;
- }
--#line 1669 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1666 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 29:
--#line 435 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 432 "po-gram-gen.y" /* yacc.c:1646 */
- {
- string_list_init (&(yyval.stringlist).stringlist);
- string_list_append (&(yyval.stringlist).stringlist, (yyvsp[0].string).string);
-@@ -1677,11 +1674,11 @@ yyreduce:
- (yyval.stringlist).pos = (yyvsp[0].string).pos;
- (yyval.stringlist).obsolete = (yyvsp[0].string).obsolete;
- }
--#line 1681 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1678 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
- case 30:
--#line 443 "po-gram-gen.y" /* yacc.c:1646 */
-+#line 440 "po-gram-gen.y" /* yacc.c:1646 */
- {
- check_obsolete ((yyvsp[-1].stringlist), (yyvsp[0].string));
- (yyval.stringlist).stringlist = (yyvsp[-1].stringlist).stringlist;
-@@ -1690,11 +1687,11 @@ yyreduce:
- (yyval.stringlist).pos = (yyvsp[-1].stringlist).pos;
- (yyval.stringlist).obsolete = (yyvsp[-1].stringlist).obsolete;
- }
--#line 1694 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1691 "po-gram-gen.c" /* yacc.c:1646 */
- break;
-
-
--#line 1698 "po-gram-gen.c" /* yacc.c:1646 */
-+#line 1695 "po-gram-gen.c" /* yacc.c:1646 */
- default: break;
- }
- /* User semantic actions sometimes alter yychar, and that requires
diff --git a/pkgs/development/libraries/gettext/default.nix b/pkgs/development/libraries/gettext/default.nix
index 9547c6c31ad..3c1e98730fa 100644
--- a/pkgs/development/libraries/gettext/default.nix
+++ b/pkgs/development/libraries/gettext/default.nix
@@ -1,24 +1,16 @@
-{ stdenv, lib, fetchurl, libiconv, xz, bison, automake115x, autoconf }:
+{ stdenv, lib, fetchurl, libiconv, xz }:
-let allowBisonDependency = !stdenv.isDarwin; in
stdenv.mkDerivation rec {
pname = "gettext";
- version = "0.19.8.1";
+ version = "0.20.1";
src = fetchurl {
url = "mirror://gnu/gettext/${pname}-${version}.tar.gz";
- sha256 = "0hsw28f9q9xaggjlsdp2qmbp2rbd1mp0njzan2ld9kiqwkq2m57z";
+ sha256 = "0p3zwkk27wm2m2ccfqm57nj7vqkmfpn7ja1nf65zmhz8qqs5chb6";
};
patches = [
./absolute-paths.diff
- (fetchurl {
- name = "CVE-2018-18751.patch";
- url = "https://git.savannah.gnu.org/gitweb/?p=gettext.git;a=patch;h=dce3a16e5e9368245735e29bf498dcd5e3e474a4";
- sha256 = "1lpjwwcjr1sb879faj0xyzw02kma0ivab6xwn3qciy13qy6fq5xn";
- })
- ] ++ lib.optionals (!allowBisonDependency) [
- # Only necessary for CVE-2018-18751.patch:
- ./CVE-2018-18751-bison.patch
+ ./gettext.git-2336451ed68d91ff4b5ae1acbc1eca30e47a86a9.patch
];
outputs = [ "out" "man" "doc" "info" ];
@@ -54,14 +46,6 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [
xz
xz.bin
- ]
- # Only necessary for CVE-2018-18751.patch (unless CVE-2018-18751-bison.patch
- # is also applied):
- ++ lib.optional allowBisonDependency bison
- ++ [
- # Only necessary for CVE-2018-18751.patch:
- automake115x
- autoconf
];
# HACK, see #10874 (and 14664)
buildInputs = stdenv.lib.optional (!stdenv.isLinux && !stdenv.hostPlatform.isCygwin) libiconv;
diff --git a/pkgs/development/libraries/gettext/gettext-setup-hook.sh b/pkgs/development/libraries/gettext/gettext-setup-hook.sh
index ad3763c29b6..69020146f84 100644
--- a/pkgs/development/libraries/gettext/gettext-setup-hook.sh
+++ b/pkgs/development/libraries/gettext/gettext-setup-hook.sh
@@ -10,7 +10,7 @@ addEnvHooks "$hostOffset" gettextDataDirsHook
# libintl must be listed in load flags on non-Glibc
# it doesn't hurt to have it in Glibc either though
-if [ -n "@gettextNeedsLdflags@" -a -z "$dontAddExtraLibs" ]; then
+if [ -n "@gettextNeedsLdflags@" -a -z "${dontAddExtraLibs-}" ]; then
# See pkgs/build-support/setup-hooks/role.bash
getHostRole
export NIX_${role_pre}LDFLAGS+=" -lintl"
diff --git a/pkgs/development/libraries/gettext/gettext.git-2336451ed68d91ff4b5ae1acbc1eca30e47a86a9.patch b/pkgs/development/libraries/gettext/gettext.git-2336451ed68d91ff4b5ae1acbc1eca30e47a86a9.patch
new file mode 100644
index 00000000000..4a19b11507a
--- /dev/null
+++ b/pkgs/development/libraries/gettext/gettext.git-2336451ed68d91ff4b5ae1acbc1eca30e47a86a9.patch
@@ -0,0 +1,82 @@
+From 2336451ed68d91ff4b5ae1acbc1eca30e47a86a9 Mon Sep 17 00:00:00 2001
+From: Bruno Haible
+Date: Sun, 19 May 2019 13:10:06 +0200
+Subject: [PATCH] msgmerge: Fix behaviour of --for-msgfmt on PO files with no
+ translations.
+
+Reported by Don Lawrence
+in
+via Daiki Ueno
+in .
+
+* gettext-tools/src/msgmerge.c (main): Treat force_po like true if for_msgfmt
+is true.
+* gettext-tools/tests/msgmerge-26: Add test of PO file with no translations.
+---
+ gettext-tools/src/msgmerge.c | 4 ++--
+ gettext-tools/tests/msgmerge-26 | 36 +++++++++++++++++++++++++++++++++---
+ 2 files changed, 35 insertions(+), 5 deletions(-)
+
+diff --git a/gettext-tools/src/msgmerge.c b/gettext-tools/src/msgmerge.c
+index cd762c0..92c9b7a 100644
+--- a/gettext-tools/src/msgmerge.c
++++ b/gettext-tools/src/msgmerge.c
+@@ -520,8 +520,8 @@ There is NO WARRANTY, to the extent permitted by law.\n\
+ else
+ {
+ /* Write the merged message list out. */
+- msgdomain_list_print (result, output_file, output_syntax, force_po,
+- false);
++ msgdomain_list_print (result, output_file, output_syntax,
++ for_msgfmt || force_po, false);
+ }
+
+ exit (EXIT_SUCCESS);
+diff --git a/gettext-tools/tests/msgmerge-26 b/gettext-tools/tests/msgmerge-26
+index cd3862e..b86f7a0 100755
+--- a/gettext-tools/tests/msgmerge-26
++++ b/gettext-tools/tests/msgmerge-26
+@@ -73,7 +73,37 @@ msgstr "Papaya"
+ EOF
+
+ : ${DIFF=diff}
+-${DIFF} mm-test26.ok mm-test26.out
+-result=$?
++${DIFF} mm-test26.ok mm-test26.out || Exit 1
+
+-exit $result
++# Test with a PO file that has no translated messages.
++
++cat <<\EOF > mm-test26a.in1
++msgid ""
++msgstr ""
++"Content-Type: text/plain; charset=UTF-8\n"
++
++msgid "Hello world"
++msgstr "Hallo Welt"
++EOF
++
++cat <<\EOF > mm-test26a.in2
++msgid ""
++msgstr ""
++"Content-Type: text/plain; charset=ASCII\n"
++
++msgid "Hello, world!"
++msgstr ""
++EOF
++
++: ${MSGMERGE=msgmerge}
++${MSGMERGE} --for-msgfmt -o mm-test26a.tmp mm-test26a.in1 mm-test26a.in2 \
++ || Exit 1
++LC_ALL=C tr -d '\r' < mm-test26a.tmp > mm-test26a.out || Exit 1
++
++cat <<\EOF > mm-test26a.ok
++msgid ""
++msgstr "Content-Type: text/plain; charset=UTF-8\n"
++EOF
++
++: ${DIFF=diff}
++${DIFF} mm-test26a.ok mm-test26a.out || Exit 1
+--
+1.9.1
+
diff --git a/pkgs/development/libraries/gle/default.nix b/pkgs/development/libraries/gle/default.nix
index dd72637f2eb..d656473ba80 100644
--- a/pkgs/development/libraries/gle/default.nix
+++ b/pkgs/development/libraries/gle/default.nix
@@ -1,7 +1,7 @@
-{stdenv, fetchurl, libGLU_combined, freeglut, libX11, libXt, libXmu, libXi, libXext}:
+{stdenv, fetchurl, freeglut, libX11, libXt, libXmu, libXi, libXext, libGL, libGLU}:
stdenv.mkDerivation {
name = "gle-3.1.0";
- buildInputs = [libGLU_combined freeglut libX11 libXt libXmu libXi libXext];
+ buildInputs = [libGLU libGL freeglut libX11 libXt libXmu libXi libXext];
src = fetchurl {
urls = [
"mirror://sourceforge/project/gle/gle/gle-3.1.0/gle-3.1.0.tar.gz"
diff --git a/pkgs/development/libraries/glib/setup-hook.sh b/pkgs/development/libraries/glib/setup-hook.sh
index a1cb1f40c58..20714ea7ab8 100644
--- a/pkgs/development/libraries/glib/setup-hook.sh
+++ b/pkgs/development/libraries/glib/setup-hook.sh
@@ -1,9 +1,11 @@
make_glib_find_gsettings_schemas() {
# For packages that need gschemas of other packages (e.g. empathy)
- if [ -d "$1"/share/gsettings-schemas/*/glib-2.0/schemas ]; then
- addToSearchPath GSETTINGS_SCHEMAS_PATH "$1/share/gsettings-schemas/"*
- fi
+ for maybe_dir in "$1"/share/gsettings-schemas/*/glib-2.0; do
+ if [[ -d "$maybe_dir/schemas" ]]; then
+ addToSearchPath GSETTINGS_SCHEMAS_PATH "$maybe_dir"
+ fi
+ done
}
addEnvHooks "$hostOffset" make_glib_find_gsettings_schemas
diff --git a/pkgs/development/libraries/gnu-efi/default.nix b/pkgs/development/libraries/gnu-efi/default.nix
index 0d704f74c1e..b5b8add2db5 100644
--- a/pkgs/development/libraries/gnu-efi/default.nix
+++ b/pkgs/development/libraries/gnu-efi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, pciutils }:
+{ stdenv, buildPackages, fetchurl, fetchpatch, pciutils }:
with stdenv.lib;
@@ -11,6 +11,14 @@ stdenv.mkDerivation rec {
sha256 = "1ffnc4xbzfggs37ymrgfx76j56kk2644c081ivhr2bjkla9ag3gj";
};
+ patches = [
+ # Fix build on armv6l
+ (fetchpatch {
+ url = "https://sourceforge.net/p/gnu-efi/patches/_discuss/thread/25bb273a18/9c4d/attachment/0001-Fix-ARCH-on-armv6-and-other-32-bit-ARM-platforms.patch";
+ sha256 = "0pj03h20g2bbz6fr753bj1scry6919h57l1h86z3b6q7hqfj0b4r";
+ })
+ ];
+
buildInputs = [ pciutils ];
hardeningDisable = [ "stackprotector" ];
diff --git a/pkgs/development/libraries/gstreamer/bad/default.nix b/pkgs/development/libraries/gstreamer/bad/default.nix
index 735ab4e6e18..de8556ccc96 100644
--- a/pkgs/development/libraries/gstreamer/bad/default.nix
+++ b/pkgs/development/libraries/gstreamer/bad/default.nix
@@ -1,16 +1,40 @@
-{ stdenv, fetchurl, fetchpatch, meson, ninja, gettext
+{ stdenv
+, fetchurl
+, meson
+, ninja
+, gettext
, config
-, pkgconfig, python3, gst-plugins-base, orc
+, pkgconfig
+, python3
+, gst-plugins-base
+, orc
, gobject-introspection
, enableZbar ? true
-, faacSupport ? false, faac ? null
-, faad2, libass, libkate, libmms, librdf, ladspaH
-, libnice, webrtc-audio-processing, lilv, lv2, serd, sord, sratom
-, libbs2b, libmodplug, mpeg2dec
-, openjpeg, libopus, librsvg
+, faacSupport ? false
+, faac ? null
+, faad2
+, libass
+, libkate
+, libmms
+, librdf
+, ladspaH
+, libnice
+, webrtc-audio-processing
+, lilv
+, lv2
+, serd
+, sord
+, sratom
+, libbs2b
+, libmodplug
+, mpeg2dec
+, openjpeg
+, libopus
+, librsvg
, bluez
, chromaprint
, curl
+, darwin
, directfb
, fdk_aac
, flite
@@ -27,7 +51,7 @@
, libusb1
, neon
, openal
-, opencv3
+, opencv4
, openexr
, openh264
, pango
@@ -38,10 +62,20 @@
, srtp
, zbar
, wayland-protocols
-, wildmidi, fluidsynth, libvdpau, wayland
-, libwebp, xvidcore, gnutls, mjpegtools
-, libGLU_combined, libintl, libgme
-, openssl, x265, libxml2
+, wildmidi
+, fluidsynth
+, libvdpau
+, wayland
+, libwebp
+, xvidcore
+, gnutls
+, mjpegtools
+, libGLU_combined
+, libintl
+, libgme
+, openssl
+, x265
+, libxml2
, srt
}:
@@ -49,113 +83,127 @@ assert faacSupport -> faac != null;
let
inherit (stdenv.lib) optional optionals;
-in
-stdenv.mkDerivation rec {
+in stdenv.mkDerivation rec {
pname = "gst-plugins-bad";
- version = "1.16.0";
-
- meta = with stdenv.lib; {
- description = "Gstreamer Bad Plugins";
- homepage = "https://gstreamer.freedesktop.org";
- longDescription = ''
- a set of plug-ins that aren't up to par compared to the
- rest. They might be close to being good quality, but they're missing
- something - be it a good code review, some documentation, a set of tests,
- a real live maintainer, or some actual wide use.
- '';
- license = licenses.lgpl2Plus;
- platforms = platforms.linux ++ platforms.darwin;
- maintainers = with maintainers; [ matthewbauer ];
- };
-
- preConfigure = ''
- patchShebangs .
- '';
-
- patches = [
- ./fix_pkgconfig_includedir.patch
- # Remove when https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/merge_requests/312 is merged and available to us
- (fetchpatch {
- url = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/commit/99790eaad9083cce5ab2b1646489e1a1c0faad1e.patch";
- sha256 = "11bqy4sl05qq5mj4bx5s09rq106s3j0vnpjl4np058im32j69lr3";
- })
- # Remove when https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/merge_requests/312 is merged and available to us
- (fetchpatch {
- url = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/commit/1872da81c48d3a719bd39955fd97deac7d037d74.patch";
- sha256 = "11zwrr5ggflmvr0qfssj7dmhgd3ybiadmy79b4zh24022zgw3xpz";
- })
- ];
-
- src = fetchurl {
- url = "${meta.homepage}/src/gst-plugins-bad/${pname}-${version}.tar.xz";
- sha256 = "019b0yqjrcg6jmfd4cc336h1bz5p4wxl58yz1c4sdb96avirs4r2";
- };
+ version = "1.16.1";
outputs = [ "out" "dev" ];
+ src = fetchurl {
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "1dddqacxgp77f3nl153x5a6139wdphc9phds2fpqb2cv6faiqj2n";
+ };
+
+ patches = [
+ ./fix_pkgconfig_includedir.patch
+ ];
+
nativeBuildInputs = [
- meson ninja pkgconfig python3 gettext gobject-introspection
- ]
- ++ optionals stdenv.isLinux [
+ meson
+ ninja
+ pkgconfig
+ python3
+ gettext
+ gobject-introspection
+ ] ++ optionals stdenv.isLinux [
wayland-protocols
];
buildInputs = [
- gst-plugins-base orc
- faad2 libass libkate libmms
- libnice webrtc-audio-processing # webrtc
+ gst-plugins-base
+ orc
+ faad2
+ libass
+ libkate
+ libmms
+ webrtc-audio-processing # webrtc
libbs2b
- ladspaH librdf # ladspa plug-in
- lilv lv2 serd sord sratom # lv2 plug-in
- libmodplug mpeg2dec
- openjpeg libopus librsvg
- bluez
- chromaprint
+ libmodplug
+ mpeg2dec
+ openjpeg
+ libopus
+ librsvg
curl.dev
- directfb
fdk_aac
- flite
gsm
libaom
libdc1394
libde265
- libdrm
libdvdnav
libdvdread
- libgudev
- libofa
libsndfile
libusb1
+ mjpegtools
neon
openal
- opencv3
+ opencv4
openexr
openh264
rtmpdump
pango
- sbc
soundtouch
- spandsp
srtp
- fluidsynth libvdpau
- libwebp xvidcore gnutls libGLU_combined
- libgme openssl x265 libxml2
+ fluidsynth
+ libvdpau
+ libwebp
+ xvidcore
+ gnutls
+ libGLU_combined
+ libgme
+ openssl
+ x265
+ libxml2
libintl
srt
- ]
- ++ optional enableZbar zbar
- ++ optional faacSupport faac
- ++ optional stdenv.isLinux wayland
+ ] ++ optionals enableZbar [
+ zbar
+ ] ++ optionals faacSupport [
+ faac
+ ] ++ optionals stdenv.isLinux [
+ bluez
+ wayland
+ ] ++ optionals (!stdenv.isDarwin) [
# wildmidi requires apple's OpenAL
# TODO: package apple's OpenAL, fix wildmidi, include on Darwin
- ++ optional (!stdenv.isDarwin) wildmidi
+ wildmidi
# TODO: mjpegtools uint64_t is not compatible with guint64 on Darwin
- ++ optional (!stdenv.isDarwin) mjpegtools;
+ mjpegtools
+
+ chromaprint
+ directfb
+ flite
+ libdrm
+ libgudev
+ libnice
+ libofa
+ librdf
+ sbc
+ spandsp
+
+ # ladspa plug-in
+ ladspaH
+ librdf # TODO: make build on Darwin
+
+ # lv2 plug-in
+ lilv
+ lv2
+ serd
+ sord
+ sratom
+ ] ++ optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [
+ # For unknown reasons the order is important, e.g. if
+ # VideoToolbox is last, we get:
+ # fatal error: 'VideoToolbox/VideoToolbox.h' file not found
+ VideoToolbox
+ AudioToolbox
+ AVFoundation
+ CoreMedia
+ CoreVideo
+ Foundation
+ MediaToolbox
+ ]);
mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
-
"-Dexamples=disabled" # requires many dependencies and probably not useful for our users
"-Ddts=disabled" # required `libdca` library not packaged in nixpkgs as of writing, and marked as "BIG FAT WARNING: libdca is still in early development"
@@ -191,10 +239,50 @@ stdenv.mkDerivation rec {
# see https://github.com/NixOS/nixpkgs/issues/54395
"-Dnvdec=disabled"
"-Dnvenc=disabled"
+ ]
+ ++ optionals stdenv.isDarwin [
+ "-Dbluez=disabled"
+ "-Dchromaprint=disabled"
+ "-Ddirectfb=disabled"
+ "-Dflite=disabled"
+ "-Dkms=disabled" # renders to libdrm output
+ "-Dofa=disabled"
+ "-Dlv2=disabled"
+ "-Dsbc=disabled"
+ "-Dspandsp=disabled"
+ "-Ddvb=disabled"
+ "-Dfbdev=disabled"
+ "-Duvch264=disabled" # requires gudev
+ "-Dladspa=disabled" # requires lrdf
+ "-Dwebrtc=disabled" # requires libnice, which as of writing doesn't work on Darwin in nixpkgs
+ "-Dwildmidi=disabled" # see dependencies above
+ ] ++ optionals (!gst-plugins-base.glEnabled) [
+ "-Dgl=disabled"]
+ ++ optionals (!gst-plugins-base.waylandEnabled) [
+ "-Dwayland=disabled"
+ ] ++ optionals (!gst-plugins-base.glEnabled) [
+ # `applemedia/videotexturecache.h` requires `gst/gl/gl.h`,
+ # but its meson build system does not declare the dependency.
+ "-Dapplemedia=disabled"
];
- enableParallelBuilding = true;
+ # This package has some `_("string literal")` string formats
+ # that trip up clang with format security enabled.
+ hardeningDisable = [ "format" ];
doCheck = false; # fails 20 out of 58 tests, expensive
+ meta = with stdenv.lib; {
+ description = "GStreamer Bad Plugins";
+ homepage = "https://gstreamer.freedesktop.org";
+ longDescription = ''
+ a set of plug-ins that aren't up to par compared to the
+ rest. They might be close to being good quality, but they're missing
+ something - be it a good code review, some documentation, a set of tests,
+ a real live maintainer, or some actual wide use.
+ '';
+ license = licenses.lgpl2Plus;
+ platforms = platforms.linux ++ platforms.darwin;
+ maintainers = with maintainers; [ matthewbauer ];
+ };
}
diff --git a/pkgs/development/libraries/gstreamer/base/default.nix b/pkgs/development/libraries/gstreamer/base/default.nix
index 81d91458132..d38199cf787 100644
--- a/pkgs/development/libraries/gstreamer/base/default.nix
+++ b/pkgs/development/libraries/gstreamer/base/default.nix
@@ -1,100 +1,153 @@
-{ stdenv, fetchurl, fetchpatch, lib
-, pkgconfig, meson, ninja, gettext, gobject-introspection
-, python3, gstreamer, orc, pango, libtheora
-, libintl, libopus
+{ stdenv
+, fetchurl
+, lib
+, pkgconfig
+, meson
+, ninja
+, gettext
+, gobject-introspection
+, python3
+, gstreamer
+, orc
+, pango
+, libtheora
+, libintl
+, libopus
, isocodes
, libjpeg
+, libpng
, libvisual
, tremor # provides 'virbisidec'
, libGL
-, gtk-doc, docbook_xsl, docbook_xml_dtd_412
-, enableX11 ? stdenv.isLinux, libXv
-, enableWayland ? stdenv.isLinux, wayland
-, enableAlsa ? stdenv.isLinux, alsaLib
-, enableCocoa ? false, darwin
-, enableCdparanoia ? (!stdenv.isDarwin), cdparanoia }:
+, gtk-doc
+, docbook_xsl
+, docbook_xml_dtd_43
+, enableX11 ? stdenv.isLinux
+, libXv
+, enableWayland ? stdenv.isLinux
+, wayland
+, enableAlsa ? stdenv.isLinux
+, alsaLib
+# Enabling Cocoa seems to currently not work, giving compile
+# errors. Suspected is that a newer version than clang
+# is needed than 5.0 but it is not clear.
+, enableCocoa ? false
+, darwin
+, enableGl ? (enableX11 || enableWayland || enableCocoa)
+, enableCdparanoia ? (!stdenv.isDarwin)
+, cdparanoia
+}:
stdenv.mkDerivation rec {
pname = "gst-plugins-base";
- version = "1.16.0";
-
- meta = with lib; {
- description = "Base plugins and helper libraries";
- homepage = https://gstreamer.freedesktop.org;
- license = licenses.lgpl2Plus;
- platforms = platforms.unix;
- maintainers = with maintainers; [ matthewbauer ];
- };
-
- src = fetchurl {
- url = "${meta.homepage}/src/gst-plugins-base/${pname}-${version}.tar.xz";
- sha256 = "1bmmdwbyy89ayb85xc48y217f6wdmpz96f30zm6v53z2a5xsm4s0";
- };
+ version = "1.16.1";
outputs = [ "out" "dev" ];
+ src = fetchurl {
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "0aybbwnzm15074smdk2bamj3ssck3hjvmilvgh49f19xjf4w8g2w";
+ };
+
+ patches = [
+ ./fix_pkgconfig_includedir.patch
+ ];
+
nativeBuildInputs = [
- pkgconfig python3 gettext gobject-introspection
+ meson
+ ninja
+ pkgconfig
+ python3
+ gettext
+ gobject-introspection
+
+ # docs
gtk-doc
- # Without these, enabling the 'gtk_doc' gives us `FAILED: meson-install`
- docbook_xsl docbook_xml_dtd_412
- ]
- # Broken meson with Darwin. Should hopefully be fixed soon. Tracking
- # in https://bugzilla.gnome.org/show_bug.cgi?id=781148.
- ++ lib.optionals (!stdenv.isDarwin) [ meson ninja ];
+ docbook_xsl
+ docbook_xml_dtd_43
+ ];
- # On Darwin, we currently use autoconf, on all other systems Meson
- # TODO Switch to Meson on Darwin as well
-
- # TODO How to pass these to Meson?
- configureFlags = lib.optionals stdenv.isDarwin [
- "--enable-x11=${if enableX11 then "yes" else "no"}"
- "--enable-wayland=${if enableWayland then "yes" else "no"}"
- "--enable-cocoa=${if enableCocoa then "yes" else "no"}"
- ]
- # Introspection fails on my MacBook currently
- ++ lib.optional stdenv.isDarwin "--disable-introspection";
-
- mesonFlags = lib.optionals (!stdenv.isDarwin) [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
- "-Dexamples=disabled" # requires many dependencies and probably not useful for our users
- "-Dgl-graphene=disabled" # not packaged in nixpkgs as of writing
- # See https://github.com/GStreamer/gst-plugins-base/blob/d64a4b7a69c3462851ff4dcfa97cc6f94cd64aef/meson_options.txt#L15 for a list of choices
- "-Dgl_winsys=[${lib.concatStringsSep "," (lib.optional enableX11 "x11" ++ lib.optional enableWayland "wayland" ++ lib.optional enableCocoa "cocoa")}]"
- # We must currently disable gtk_doc API docs generation,
- # because it is not compatible with some features being disabled.
- # See for example
- # https://gitlab.gnome.org/GNOME/gnome-build-meta/issues/38
- # for it failing because some Wayland symbols are missing.
- # This problem appeared between 1.15.1 and 1.16.0.
- "-Dgtk_doc=disabled"
- ]
- ++ lib.optional (!enableX11) "-Dx11=disabled"
- # TODO How to disable Wayland?
- ++ lib.optional (!enableAlsa) "-Dalsa=disabled"
- ++ lib.optional (!enableCdparanoia) "-Dcdparanoia=disabled"
- ;
-
- buildInputs = [ orc libtheora libintl libopus isocodes libjpeg tremor libGL ]
- ++ lib.optional (!stdenv.isDarwin) libvisual
- ++ lib.optional enableAlsa alsaLib
+ buildInputs = [
+ orc
+ libtheora
+ libintl
+ libopus
+ isocodes
+ libpng
+ libjpeg
+ tremor
+ libGL
+ ] ++ lib.optional (!stdenv.isDarwin) [
+ libvisual
+ ] ++ lib.optionals stdenv.isDarwin [
+ pango
+ darwin.apple_sdk.frameworks.OpenGL
+ ] ++ lib.optional enableAlsa alsaLib
++ lib.optionals enableX11 [ libXv pango ]
++ lib.optional enableWayland wayland
++ lib.optional enableCocoa darwin.apple_sdk.frameworks.Cocoa
++ lib.optional enableCdparanoia cdparanoia;
- propagatedBuildInputs = [ gstreamer ];
+ propagatedBuildInputs = [
+ gstreamer
+ ];
+
+ mesonFlags = [
+ "-Dexamples=disabled" # requires many dependencies and probably not useful for our users
+ "-Dgl-graphene=disabled" # not packaged in nixpkgs as of writing
+ "-Dgl_platform=[${lib.optionalString (enableX11 || enableWayland || enableCocoa) "auto"}]"
+ # See https://github.com/GStreamer/gst-plugins-base/blob/d64a4b7a69c3462851ff4dcfa97cc6f94cd64aef/meson_options.txt#L15 for a list of choices
+ "-Dgl_winsys=[${lib.concatStringsSep "," (lib.optional enableX11 "x11" ++ lib.optional enableWayland "wayland" ++ lib.optional enableCocoa "cocoa")}]"
+ # We must currently disable gtk_doc API docs generation,
+ # because it is not compatible with some features being disabled.
+ # See for example
+ # https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/issues/564
+ # for it failing because some Wayland symbols are missing.
+ # This problem appeared between 1.15.1 and 1.16.0.
+ # In 1.18 they should switch to hotdoc, which should make this issue irrelevant.
+ "-Dgtk_doc=disabled"
+ ]
+ ++ lib.optional (!enableX11) "-Dx11=disabled"
+ # TODO How to disable Wayland?
+ ++ lib.optional (!enableGl) "-Dgl=disabled"
+ ++ lib.optional (!enableAlsa) "-Dalsa=disabled"
+ ++ lib.optional (!enableCdparanoia) "-Dcdparanoia=disabled"
+ ++ lib.optionals stdenv.isDarwin [
+ "-Dlibvisual=disabled"
+ ];
postPatch = ''
- patchShebangs .
+ patchShebangs common/scangobj-merge.py
'';
- enableParallelBuilding = true;
+ # This package has some `_("string literal")` string formats
+ # that trip up clang with format security enabled.
+ hardeningDisable = [ "format" ];
doCheck = false; # fails, wants DRI access for OpenGL
- patches = [
- ./fix_pkgconfig_includedir.patch
- ];
+ passthru = {
+ # Downstream `gst-*` packages depending on `gst-plugins-base`
+ # have meson build options like 'gl' etc. that depend
+ # on these features being built in `-base`.
+ # If they are not built here, then the downstream builds
+ # will fail, as they, too, use `-Dauto_features=enabled`
+ # which would enable these options unconditionally.
+ # That means we must communicate to these downstream packages
+ # if the `-base` enabled these options or not, so that
+ # the can enable/disable those features accordingly.
+ # The naming `*Enabled` vs `enable*` is intentional to
+ # distinguish inputs from outputs (what is to be built
+ # vs what was built) and to make them easier to search for.
+ glEnabled = enableGl;
+ waylandEnabled = enableWayland;
+ };
+
+ meta = with lib; {
+ description = "Base GStreamer plug-ins and helper libraries";
+ homepage = "https://gstreamer.freedesktop.org";
+ license = licenses.lgpl2Plus;
+ platforms = platforms.unix;
+ maintainers = with maintainers; [ matthewbauer ];
+ };
}
diff --git a/pkgs/development/libraries/gstreamer/core/default.nix b/pkgs/development/libraries/gstreamer/core/default.nix
index f0f01a977fd..bbef0178312 100644
--- a/pkgs/development/libraries/gstreamer/core/default.nix
+++ b/pkgs/development/libraries/gstreamer/core/default.nix
@@ -1,10 +1,23 @@
-{ stdenv, fetchurl, fetchpatch, meson, ninja
-, pkgconfig, gettext, gobject-introspection
-, bison, flex, python3, glib, makeWrapper
-, libcap,libunwind, darwin
+{ stdenv
+, fetchurl
+, fetchpatch
+, meson
+, ninja
+, pkgconfig
+, gettext
+, gobject-introspection
+, bison
+, flex
+, python3
+, glib
+, makeWrapper
+, libcap
+, libunwind
+, darwin
, elfutils # for libdw
, bash-completion
-, docbook_xsl, docbook_xml_dtd_412
+, docbook_xsl
+, docbook_xml_dtd_43
, gtk-doc
, lib
, CoreServices
@@ -12,50 +25,66 @@
stdenv.mkDerivation rec {
pname = "gstreamer";
- version = "1.16.0";
+ version = "1.16.1";
- meta = with lib ;{
- description = "Open source multimedia framework";
- homepage = https://gstreamer.freedesktop.org;
- license = licenses.lgpl2Plus;
- platforms = platforms.unix;
- maintainers = with maintainers; [ ttuegel matthewbauer ];
- };
+ outputs = [ "out" "dev" "devdoc" ];
+ outputBin = "dev";
src = fetchurl {
- url = "${meta.homepage}/src/gstreamer/${pname}-${version}.tar.xz";
- sha256 = "003wy1p1in85p9sr5jsyhbnwqaiwz069flwkhyx7qhxy31qjz3hf";
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "0z9pyhf6zm1r0spw6zym80bvbyx6h8xg9h6535csbnn48ws1q882";
};
patches = [
./fix_pkgconfig_includedir.patch
];
- outputs = [ "out" "dev" ];
- outputBin = "dev";
-
nativeBuildInputs = [
- meson ninja pkgconfig gettext bison flex python3 makeWrapper gobject-introspection
+ meson
+ ninja
+ pkgconfig
+ gettext
+ bison
+ flex
+ python3
+ makeWrapper
+ gobject-introspection
bash-completion
+
+ # documentation
gtk-doc
- # Without these, enabling the 'gtk_doc' gives us `FAILED: meson-install`
- docbook_xsl docbook_xml_dtd_412
+ docbook_xsl
+ docbook_xml_dtd_43
];
- buildInputs =
- lib.optionals stdenv.isLinux [ libcap libunwind elfutils ]
- ++ lib.optional stdenv.isDarwin CoreServices;
+ buildInputs = lib.optionals stdenv.isLinux [
+ libcap
+ libunwind
+ elfutils
+ ] ++ lib.optionals stdenv.isDarwin [
+ CoreServices
+ ];
- propagatedBuildInputs = [ glib ];
+ propagatedBuildInputs = [
+ glib
+ ];
mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
"-Ddbghelp=disabled" # not needed as we already provide libunwind and libdw, and dbghelp is a fallback to those
"-Dexamples=disabled" # requires many dependencies and probably not useful for our users
- ]
+ ] ++ lib.optionals stdenv.isDarwin [
# darwin.libunwind doesn't have pkgconfig definitions so meson doesn't detect it.
- ++ stdenv.lib.optionals stdenv.isDarwin [ "-Dlibunwind=disabled" "-Dlibdw=disabled" ];
+ "-Dlibunwind=disabled"
+ "-Dlibdw=disabled"
+ ];
+
+ postPatch = ''
+ patchShebangs \
+ gst/parse/get_flex_version.py \
+ gst/parse/gen_grammar.py.in \
+ gst/parse/gen_lex.py.in \
+ libs/gst/helpers/ptp_helper_post_install.sh
+ '';
postInstall = ''
for prog in "$dev/bin/"*; do
@@ -64,21 +93,17 @@ stdenv.mkDerivation rec {
done
'';
- preConfigure=
- # These files are not executable upstream, so we need to
- # make them executable for `patchShebangs` to pick them up.
- # Can be removed when this is merged and available:
- # https://gitlab.freedesktop.org/gstreamer/gstreamer/merge_requests/141
- ''
- chmod +x gst/parse/get_flex_version.py
- '' +
- ''
- patchShebangs .
- '';
-
preFixup = ''
moveToOutput "share/bash-completion" "$dev"
'';
setupHook = ./setup-hook.sh;
+
+ meta = with lib ;{
+ description = "Open source multimedia framework";
+ homepage = "https://gstreamer.freedesktop.org";
+ license = licenses.lgpl2Plus;
+ platforms = platforms.unix;
+ maintainers = with maintainers; [ ttuegel matthewbauer ];
+ };
}
diff --git a/pkgs/development/libraries/gstreamer/core/setup-hook.sh b/pkgs/development/libraries/gstreamer/core/setup-hook.sh
index b8c741af578..026a4e5f55a 100644
--- a/pkgs/development/libraries/gstreamer/core/setup-hook.sh
+++ b/pkgs/development/libraries/gstreamer/core/setup-hook.sh
@@ -1,7 +1,7 @@
addGstreamer1LibPath () {
if test -d "$1/lib/gstreamer-1.0"
then
- export GST_PLUGIN_SYSTEM_PATH_1_0="${GST_PLUGIN_SYSTEM_PATH_1_0}${GST_PLUGIN_SYSTEM_PATH_1_0:+:}$1/lib/gstreamer-1.0"
+ export GST_PLUGIN_SYSTEM_PATH_1_0="${GST_PLUGIN_SYSTEM_PATH_1_0-}${GST_PLUGIN_SYSTEM_PATH_1_0:+:}$1/lib/gstreamer-1.0"
fi
}
diff --git a/pkgs/development/libraries/gstreamer/ges/default.nix b/pkgs/development/libraries/gstreamer/ges/default.nix
index 810cee650ca..d62af71d3ae 100644
--- a/pkgs/development/libraries/gstreamer/ges/default.nix
+++ b/pkgs/development/libraries/gstreamer/ges/default.nix
@@ -1,39 +1,66 @@
-{ stdenv, fetchurl, fetchpatch, meson, ninja
-, pkgconfig, python, gst-plugins-base, libxml2
-, flex, perl, gettext, gobject-introspection
+{ stdenv
+, fetchurl
+, fetchpatch
+, meson
+, ninja
+, pkgconfig
+, python
+, gst-plugins-base
+, libxml2
+, flex
+, perl
+, gettext
+, gobject-introspection
}:
stdenv.mkDerivation rec {
pname = "gstreamer-editing-services";
- version = "1.16.0";
-
- meta = with stdenv.lib; {
- description = "Library for creation of audio/video non-linear editors";
- homepage = "https://gstreamer.freedesktop.org";
- license = licenses.lgpl2Plus;
- platforms = platforms.unix;
- };
-
- src = fetchurl {
- url = "${meta.homepage}/src/gstreamer-editing-services/${pname}-${version}.tar.xz";
- sha256 = "1las94jkx83sxmzi5w6b0xm89dqqwzpdsb6h9w9ixndhnbpzm8w2";
- };
+ version = "1.16.1";
outputs = [ "out" "dev" ];
- nativeBuildInputs = [ meson ninja pkgconfig gettext gobject-introspection python flex perl ];
-
- propagatedBuildInputs = [ gst-plugins-base libxml2 ];
-
- mesonFlags = [
- "-Dgtk_doc=disabled"
- ];
+ src = fetchurl {
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "10375z5mc3bwfs07mhmfx943sbp55z8m8ihp9xpcknkdks7qg168";
+ };
patches = [
./fix_pkgconfig_includedir.patch
];
+ nativeBuildInputs = [
+ meson
+ ninja
+ pkgconfig
+ gettext
+ gobject-introspection
+ python
+ flex
+ perl
+ ];
+
+ buildInputs = [
+ libxml2
+ ];
+
+ propagatedBuildInputs = [
+ gst-plugins-base
+ ];
+
+ mesonFlags = [
+ "-Dgtk_doc=disabled"
+ ];
+
postPatch = ''
+ # for some reason, gst-plugins-bad cannot be found
+ # fortunately, they are only used by tests, which we do not run
sed -i -r -e 's/p(bad|good) = .*/p\1 = pbase/' tests/check/meson.build
'';
+
+ meta = with stdenv.lib; {
+ description = "Library for creation of audio/video non-linear editors";
+ homepage = "https://gstreamer.freedesktop.org";
+ license = licenses.lgpl2Plus;
+ platforms = platforms.unix;
+ };
}
diff --git a/pkgs/development/libraries/gstreamer/good/default.nix b/pkgs/development/libraries/gstreamer/good/default.nix
index c801684b065..1c7107e50fa 100644
--- a/pkgs/development/libraries/gstreamer/good/default.nix
+++ b/pkgs/development/libraries/gstreamer/good/default.nix
@@ -1,14 +1,37 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, python
-, gst-plugins-base, orc, bzip2, gettext
-, libv4l, libdv, libavc1394, libiec61883
-, libvpx, speex, flac, taglib, libshout
-, cairo, gdk-pixbuf, aalib, libcaca
-, libsoup, libpulseaudio, libintl
-, darwin, lame, mpg123, twolame
+{ stdenv
+, fetchurl
+, meson
+, ninja
+, pkgconfig
+, python
+, gst-plugins-base
+, orc
+, bzip2
+, gettext
+, libv4l
+, libdv
+, libavc1394
+, libiec61883
+, libvpx
+, speex
+, flac
+, taglib
+, libshout
+, cairo
+, gdk-pixbuf
+, aalib
+, libcaca
+, libsoup
+, libpulseaudio
+, libintl
+, darwin
+, lame
+, mpg123
+, twolame
, gtkSupport ? false, gtk3 ? null
-# As of writing, jack2 incurs a Qt dependency (big!) via `ffado`.
-# In the fuure we should probably split `ffado`.
-, enableJack ? false
+ # As of writing, jack2 incurs a Qt dependency (big!) via `ffado`.
+ # In the future we should probably split `ffado`.
+, enableJack ? false, jack2
, libXdamage
, libXext
, libXfixes
@@ -16,7 +39,6 @@
, xorg
, libgudev
, wavpack
-, jack2
}:
assert gtkSupport -> gtk3 != null;
@@ -26,39 +48,44 @@ let
in
stdenv.mkDerivation rec {
pname = "gst-plugins-good";
- version = "1.16.0";
-
- meta = with stdenv.lib; {
- description = "Gstreamer Good Plugins";
- homepage = "https://gstreamer.freedesktop.org";
- longDescription = ''
- a set of plug-ins that we consider to have good quality code,
- correct functionality, our preferred license (LGPL for the plug-in
- code, LGPL or LGPL-compatible for the supporting library).
- '';
- license = licenses.lgpl2Plus;
- platforms = platforms.linux ++ platforms.darwin;
- maintainers = with maintainers; [ matthewbauer ];
- };
-
- src = fetchurl {
- url = "${meta.homepage}/src/gst-plugins-good/${pname}-${version}.tar.xz";
- sha256 = "1zdhif1mhf0ihkjpjyrh65g2iz2cawkjjb3h5w8h9ml06grxwjk5";
- };
+ version = "1.16.1";
outputs = [ "out" "dev" ];
+ src = fetchurl {
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "07wgz9anf4ram2snp8n1wv6l0q3pd00iaw8bvw3wgklg05lvxflz";
+ };
+
patches = [ ./fix_pkgconfig_includedir.patch ];
- nativeBuildInputs = [ pkgconfig python meson ninja gettext ];
-
- NIX_LDFLAGS = "-lncurses";
+ nativeBuildInputs = [
+ pkgconfig
+ python
+ meson
+ ninja
+ gettext
+ ];
buildInputs = [
- gst-plugins-base orc bzip2
- libdv libvpx speex flac taglib
- cairo gdk-pixbuf aalib libcaca
- libsoup libshout lame mpg123 twolame libintl
+ gst-plugins-base
+ orc
+ bzip2
+ libdv
+ libvpx
+ speex
+ flac
+ taglib
+ cairo
+ gdk-pixbuf
+ aalib
+ libcaca
+ libsoup
+ libshout
+ lame
+ mpg123
+ twolame
+ libintl
libXdamage
libXext
libXfixes
@@ -66,29 +93,59 @@ stdenv.mkDerivation rec {
xorg.libXfixes
xorg.libXdamage
wavpack
- ]
- ++ optional gtkSupport gtk3 # for gtksink
- ++ optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.Cocoa ]
- ++ optionals stdenv.isLinux [ libv4l libpulseaudio libavc1394 libiec61883 libgudev ]
- ++ optionals (stdenv.isLinux && enableJack) [
+ ] ++ optional gtkSupport [
+ # for gtksink
+ gtk3
+ ] ++ optionals stdenv.isDarwin [
+ darwin.apple_sdk.frameworks.Cocoa
+ ] ++ optionals stdenv.isLinux [
+ libv4l
+ libpulseaudio
+ libavc1394
+ libiec61883
+ libgudev
+ ] ++ optionals (stdenv.isLinux && enableJack) [
jack2
];
mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
"-Dexamples=disabled" # requires many dependencies and probably not useful for our users
"-Dqt5=disabled" # not clear as of writing how to correctly pass in the required qt5 deps
- ]
- ++ optional (!gtkSupport) "-Dgtk3=disabled"
- ++ optionals (!stdenv.isLinux || !enableJack) [
+ ] ++ optionals (!gtkSupport) [
+ "-Dgtk3=disabled"
+ ] ++ optionals (!stdenv.isLinux || !enableJack) [
"-Djack=disabled" # unclear whether Jack works on Darwin
- ]
- ++ optionals (!stdenv.isLinux) [
- "-Dv4l2-gudev=disabled"
+ ] ++ optionals (!stdenv.isLinux) [
+ "-Ddv1394=disabled" # Linux only
+ "-Doss4=disabled" # Linux only
+ "-Doss=disabled" # Linux only
+ "-Dpulse=disabled" # TODO check if we can keep this enabled
+ "-Dv4l2-gudev=disabled" # Linux-only
+ "-Dv4l2=disabled" # Linux-only
+ "-Dximagesrc=disabled" # Linux-only
+ "-Dpulse=disabled" # TODO check if we can keep this enabled
+ ];
+
+
+ NIX_LDFLAGS = [
+ # linking error on Darwin
+ # https://github.com/NixOS/nixpkgs/pull/70690#issuecomment-553694896
+ "-lncurses"
];
# fails 1 tests with "Unexpected critical/warning: g_object_set_is_valid_property: object class 'GstRtpStorage' has no property named ''"
doCheck = false;
+ meta = with stdenv.lib; {
+ description = "GStreamer Good Plugins";
+ homepage = "https://gstreamer.freedesktop.org";
+ longDescription = ''
+ a set of plug-ins that we consider to have good quality code,
+ correct functionality, our preferred license (LGPL for the plug-in
+ code, LGPL or LGPL-compatible for the supporting library).
+ '';
+ license = licenses.lgpl2Plus;
+ platforms = platforms.linux ++ platforms.darwin;
+ maintainers = with maintainers; [ matthewbauer ];
+ };
}
diff --git a/pkgs/development/libraries/gstreamer/legacy/gst-plugins-base/default.nix b/pkgs/development/libraries/gstreamer/legacy/gst-plugins-base/default.nix
index 5a942b49cc0..eed9d423fdb 100644
--- a/pkgs/development/libraries/gstreamer/legacy/gst-plugins-base/default.nix
+++ b/pkgs/development/libraries/gstreamer/legacy/gst-plugins-base/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, pkgconfig, gstreamer, xorg, alsaLib, cdparanoia
+{ fetchurl, fetchpatch, stdenv, pkgconfig, gstreamer, xorg, alsaLib, cdparanoia
, libogg, libtheora, libvorbis, freetype, pango, liboil, glib, cairo, orc
, libintl
, ApplicationServices
@@ -20,10 +20,10 @@ stdenv.mkDerivation rec {
patches = [
./gcc-4.9.patch
- (fetchurl {
+ (fetchpatch {
url = "https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/commit/f672277509705c4034bc92a141eefee4524d15aa.patch";
name = "CVE-2019-9928.patch";
- sha256 = "0hz3lsq3ppmaf329sbyi05y1qniqfj9vlp2f3z918383pvrcms4i";
+ sha256 = "1dlamsmyr7chrb6vqqmwikqvvqcx5l7k72p98448qm6k59ndnimc";
})
];
diff --git a/pkgs/development/libraries/gstreamer/legacy/gstreamer/setup-hook.sh b/pkgs/development/libraries/gstreamer/legacy/gstreamer/setup-hook.sh
index 65ce2611251..636e20b732b 100644
--- a/pkgs/development/libraries/gstreamer/legacy/gstreamer/setup-hook.sh
+++ b/pkgs/development/libraries/gstreamer/legacy/gstreamer/setup-hook.sh
@@ -1,7 +1,7 @@
addGstreamerLibPath () {
if test -d "$1/lib/gstreamer-0.10"
then
- export GST_PLUGIN_SYSTEM_PATH="${GST_PLUGIN_SYSTEM_PATH}${GST_PLUGIN_SYSTEM_PATH:+:}$1/lib/gstreamer-0.10"
+ export GST_PLUGIN_SYSTEM_PATH="${GST_PLUGIN_SYSTEM_PATH-}${GST_PLUGIN_SYSTEM_PATH:+:}$1/lib/gstreamer-0.10"
fi
}
diff --git a/pkgs/development/libraries/gstreamer/libav/default.nix b/pkgs/development/libraries/gstreamer/libav/default.nix
index 1847b8d0c12..5319de255e7 100644
--- a/pkgs/development/libraries/gstreamer/libav/default.nix
+++ b/pkgs/development/libraries/gstreamer/libav/default.nix
@@ -1,43 +1,46 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig
-, python, yasm, gst-plugins-base, orc, bzip2
-, gettext, withSystemLibav ? true, libav ? null
+{ stdenv
+, lib
+, fetchurl
+, meson
+, ninja
+, pkgconfig
+, python3
+, gst-plugins-base
+, gettext
+, libav
}:
# Note that since gst-libav-1.6, libav is actually ffmpeg. See
# https://gstreamer.freedesktop.org/releases/1.6/ for more info.
-assert withSystemLibav -> libav != null;
-
stdenv.mkDerivation rec {
pname = "gst-libav";
- version = "1.16.0";
-
- meta = {
- homepage = https://gstreamer.freedesktop.org;
- license = stdenv.lib.licenses.lgpl2Plus;
- platforms = stdenv.lib.platforms.unix;
- };
+ version = "1.16.1";
src = fetchurl {
- url = "${meta.homepage}/src/gst-libav/${pname}-${version}.tar.xz";
- sha256 = "16ixqpfrr7plaaz14n3vagr2q5xbfkv7gpmcsyndrkx98f813b6z";
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "1i31ra0l77cfahb6k5xpx45zwvpskzm848aijsbbx9x4x65799g8";
};
outputs = [ "out" "dev" ];
- nativeBuildInputs = with stdenv.lib;
- [ meson ninja gettext pkgconfig python ]
- ++ optional (!withSystemLibav) yasm
- ;
-
- buildInputs = with stdenv.lib;
- [ gst-plugins-base orc bzip2 ]
- ++ optional withSystemLibav libav
- ;
-
- mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
+ nativeBuildInputs = [
+ meson
+ ninja
+ gettext
+ pkgconfig
+ python3
];
+ buildInputs = [
+ gst-plugins-base
+ libav
+ ];
+
+ meta = with lib; {
+ description = "FFmpeg/libav plugin for GStreamer";
+ homepage = "https://gstreamer.freedesktop.org";
+ license = licenses.lgpl2Plus;
+ platforms = platforms.unix;
+ };
}
diff --git a/pkgs/development/libraries/gstreamer/rtsp-server/default.nix b/pkgs/development/libraries/gstreamer/rtsp-server/default.nix
index 5c571fa4a1e..e602a96291e 100644
--- a/pkgs/development/libraries/gstreamer/rtsp-server/default.nix
+++ b/pkgs/development/libraries/gstreamer/rtsp-server/default.nix
@@ -1,38 +1,50 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig
-, gettext, gobject-introspection
+{ stdenv
+, fetchurl
+, meson
+, ninja
+, pkgconfig
+, gettext
+, gobject-introspection
, gst-plugins-base
, gst-plugins-bad
}:
stdenv.mkDerivation rec {
pname = "gst-rtsp-server";
- version = "1.16.0";
-
- meta = with stdenv.lib; {
- description = "Gstreamer RTSP server";
- homepage = "https://gstreamer.freedesktop.org";
- longDescription = ''
- a library on top of GStreamer for building an RTSP server.
- '';
- license = licenses.lgpl2Plus;
- platforms = platforms.linux ++ platforms.darwin;
- maintainers = with maintainers; [ bkchr ];
- };
+ version = "1.16.1";
src = fetchurl {
- url = "${meta.homepage}/src/gst-rtsp-server/${pname}-${version}.tar.xz";
- sha256 = "069zy159izy50blci9fli1i2r8jh91qkmgrz1n0xqciy3bn9x3hr";
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "0i01f1nr0921z6z4nrh8icz76s2n7i228aqxg1ihvxl65ynsraxh";
};
outputs = [ "out" "dev" ];
- nativeBuildInputs = [ meson ninja gettext gobject-introspection pkgconfig ];
+ nativeBuildInputs = [
+ meson
+ ninja
+ gettext
+ gobject-introspection
+ pkgconfig
+ ];
- buildInputs = [ gst-plugins-base gst-plugins-bad ];
+ buildInputs = [
+ gst-plugins-base
+ gst-plugins-bad
+ ];
mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
"-Dexamples=disabled" # requires many dependencies and probably not useful for our users
];
+
+ meta = with stdenv.lib; {
+ description = "GStreamer RTSP server";
+ homepage = "https://gstreamer.freedesktop.org";
+ longDescription = ''
+ A library on top of GStreamer for building an RTSP server.
+ '';
+ license = licenses.lgpl2Plus;
+ platforms = platforms.unix;
+ maintainers = with maintainers; [ bkchr ];
+ };
}
diff --git a/pkgs/development/libraries/gstreamer/ugly/default.nix b/pkgs/development/libraries/gstreamer/ugly/default.nix
index 552ab1ec292..a117190a9e1 100644
--- a/pkgs/development/libraries/gstreamer/ugly/default.nix
+++ b/pkgs/development/libraries/gstreamer/ugly/default.nix
@@ -1,53 +1,76 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, python
-, gst-plugins-base, orc, gettext
-, a52dec, libcdio, libdvdread
-, libmad, libmpeg2, x264, libintl, lib
+{ stdenv
+, fetchurl
+, meson
+, ninja
+, pkgconfig
+, python
+, gst-plugins-base
+, orc
+, gettext
+, a52dec
+, libcdio
+, libdvdread
+, libmad
+, libmpeg2
+, x264
+, libintl
+, lib
, opencore-amr
, darwin
}:
stdenv.mkDerivation rec {
pname = "gst-plugins-ugly";
- version = "1.16.0";
+ version = "1.16.1";
+
+ outputs = [ "out" "dev" ];
+
+ src = fetchurl {
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "07cajqjs8pqchpf2sm87hljx4ibwvkiavqxmacxsr5airar17yab";
+ };
+
+ nativeBuildInputs = [
+ meson
+ ninja
+ gettext
+ pkgconfig
+ python
+ ];
+
+ buildInputs = [
+ gst-plugins-base
+ orc
+ a52dec
+ libcdio
+ libdvdread
+ libmad
+ libmpeg2
+ x264
+ libintl
+ opencore-amr
+ ] ++ lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [
+ IOKit
+ CoreFoundation
+ DiskArbitration
+ ]);
+
+ mesonFlags = [
+ "-Dexamples=disabled" # requires many dependencies and probably not useful for our users
+ "-Dsidplay=disabled" # sidplay / sidplay/player.h isn't packaged in nixpkgs as of writing
+ ];
meta = with lib; {
description = "Gstreamer Ugly Plugins";
- homepage = "https://gstreamer.freedesktop.org";
+ homepage = "https://gstreamer.freedesktop.org";
longDescription = ''
a set of plug-ins that have good quality and correct functionality,
but distributing them might pose problems. The license on either
the plug-ins or the supporting libraries might not be how we'd
like. The code might be widely known to present patent problems.
'';
- license = licenses.lgpl2Plus;
- platforms = platforms.unix;
+ license = licenses.lgpl2Plus;
+ platforms = platforms.unix;
maintainers = with maintainers; [ matthewbauer ];
};
-
- src = fetchurl {
- url = "${meta.homepage}/src/gst-plugins-ugly/${pname}-${version}.tar.xz";
- sha256 = "1hm46c1fy9vl1wfwipsj41zp79cm7in1fpmjw24j5hriy32n82g3";
- };
-
- outputs = [ "out" "dev" ];
-
- nativeBuildInputs = [ meson ninja gettext pkgconfig python ];
-
- buildInputs = [
- gst-plugins-base orc
- a52dec libcdio libdvdread
- libmad libmpeg2 x264
- libintl
- opencore-amr
- ] ++ lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks;
- [ IOKit CoreFoundation DiskArbitration ]);
-
- mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
- "-Dexamples=disabled" # requires many dependencies and probably not useful for our users
- "-Dsidplay=disabled" # sidplay / sidplay/player.h isn't packaged in nixpkgs as of writing
- ];
-
- NIX_LDFLAGS = [ "-lm" ];
}
diff --git a/pkgs/development/libraries/gstreamer/vaapi/default.nix b/pkgs/development/libraries/gstreamer/vaapi/default.nix
index adb495689e3..bfa5abc7b53 100644
--- a/pkgs/development/libraries/gstreamer/vaapi/default.nix
+++ b/pkgs/development/libraries/gstreamer/vaapi/default.nix
@@ -1,49 +1,70 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, gst-plugins-base, bzip2, libva, wayland
-, libdrm, udev, xorg, libGLU_combined, gstreamer, gst-plugins-bad, nasm
-, libvpx, python, fetchpatch
+{ stdenv
+, fetchurl
+, meson
+, ninja
+, pkgconfig
+, gst-plugins-base
+, bzip2
+, libva
+, wayland
+, libdrm
+, udev
+, xorg
+, libGLU_combined
+, gstreamer
+, gst-plugins-bad
+, nasm
+, libvpx
+, python
}:
stdenv.mkDerivation rec {
- pname = "gst-vaapi";
- version = "1.16.0";
+ pname = "gstreamer-vaapi";
+ version = "1.16.1";
src = fetchurl {
- url = "${meta.homepage}/src/gstreamer-vaapi/gstreamer-vaapi-${version}.tar.xz";
- sha256 = "07qpynamiz0lniqajcaijh3n7ixs4lfk9a5mfk50sng0dricwzsf";
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "0fk0nymvbfc04fv63fj2r6q9vvi431svhkrwpr7kdjvq3rphymyb";
};
- patches = [
- # See: https://mail.gnome.org/archives/distributor-list/2019-September/msg00000.html
- # Note that the patch has now been actually accepted upstream.
- (fetchpatch {
- url = "https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/commit/a90daabb84f983d2fa05ff3159f7ad59aa648b55.patch";
- sha256 = "0p2qygq6b5h6nxjdfnlzbsyih43hjq5c94ag8sbyyb8pmnids9rb";
- })
- ];
-
outputs = [ "out" "dev" ];
- nativeBuildInputs = [ meson ninja pkgconfig bzip2 ];
-
- buildInputs = [
- gstreamer gst-plugins-base gst-plugins-bad libva wayland libdrm udev
- xorg.libX11 xorg.libXext xorg.libXv xorg.libXrandr xorg.libSM
- xorg.libICE libGLU_combined nasm libvpx python
+ nativeBuildInputs = [
+ meson
+ ninja
+ pkgconfig
+ bzip2
];
- preConfigure = ''
- export GST_PLUGIN_PATH_1_0=$out/lib/gstreamer-1.0
- mkdir -p $GST_PLUGIN_PATH_1_0
- '';
+ buildInputs = [
+ gstreamer
+ gst-plugins-base
+ gst-plugins-bad
+ libva
+ wayland
+ libdrm
+ udev
+ xorg.libX11
+ xorg.libXext
+ xorg.libXv
+ xorg.libXrandr
+ xorg.libSM
+ xorg.libICE
+ libGLU_combined
+ nasm
+ libvpx
+ python
+ ];
mesonFlags = [
"-Dexamples=disabled" # requires many dependencies and probably not useful for our users
];
- meta = {
- homepage = https://gstreamer.freedesktop.org;
- license = stdenv.lib.licenses.lgpl21Plus;
- platforms = stdenv.lib.platforms.linux;
- maintainers = with stdenv.lib.maintainers; [ tstrobel ];
+ meta = with stdenv.lib; {
+ description = "Set of VAAPI GStreamer Plug-ins";
+ homepage = "https://gstreamer.freedesktop.org";
+ license = licenses.lgpl21Plus;
+ maintainers = with maintainers; [ tstrobel ];
+ platforms = platforms.linux;
};
}
diff --git a/pkgs/development/libraries/gstreamer/validate/default.nix b/pkgs/development/libraries/gstreamer/validate/default.nix
index ad013d1570e..ad424641b81 100644
--- a/pkgs/development/libraries/gstreamer/validate/default.nix
+++ b/pkgs/development/libraries/gstreamer/validate/default.nix
@@ -1,39 +1,43 @@
-{ stdenv, fetchurl, pkgconfig, gstreamer, gst-plugins-base
-, python, gobject-introspection, json-glib
+{ stdenv
+, fetchurl
+, pkgconfig
+, gstreamer
+, gst-plugins-base
+, python
+, gobject-introspection
+, json-glib
}:
stdenv.mkDerivation rec {
pname = "gst-validate";
- version = "1.16.0";
-
- meta = {
- description = "Integration testing infrastructure for the GStreamer framework";
- homepage = https://gstreamer.freedesktop.org;
- license = stdenv.lib.licenses.lgpl2Plus;
- platforms = stdenv.lib.platforms.unix;
- };
+ version = "1.16.1";
src = fetchurl {
- url = "${meta.homepage}/src/gst-validate/${pname}-${version}.tar.xz";
- sha256 = "1jfnd0g9hmdbqfxsx96yc9vpf1w6m33hqwrr6lj4i83kl54awcck";
+ url = "${meta.homepage}/src/${pname}/${pname}-${version}.tar.xz";
+ sha256 = "1698arvmpb0cvyi8ll1brvs51vs7i3f3fw19iswh8xhj5adrn1vz";
};
outputs = [ "out" "dev" ];
nativeBuildInputs = [
- pkgconfig gobject-introspection
+ pkgconfig
+ gobject-introspection
];
buildInputs = [
- python json-glib
+ python
+ json-glib
];
- propagatedBuildInputs = [ gstreamer gst-plugins-base ];
-
- enableParallelBuilding = true;
-
- mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
+ propagatedBuildInputs = [
+ gstreamer
+ gst-plugins-base
];
+
+ meta = with stdenv.lib; {
+ description = "Integration testing infrastructure for the GStreamer framework";
+ homepage = "https://gstreamer.freedesktop.org";
+ license = licenses.lgpl2Plus;
+ platforms = platforms.unix;
+ };
}
diff --git a/pkgs/development/libraries/gtk/hooks/drop-icon-theme-cache.sh b/pkgs/development/libraries/gtk/hooks/drop-icon-theme-cache.sh
index 8f2cb8a334a..f28a856c4f5 100644
--- a/pkgs/development/libraries/gtk/hooks/drop-icon-theme-cache.sh
+++ b/pkgs/development/libraries/gtk/hooks/drop-icon-theme-cache.sh
@@ -16,4 +16,4 @@ dropIconThemeCache() {
fi
}
-preFixupPhases="$preFixupPhases dropIconThemeCache"
+preFixupPhases="${preFixupPhases-} dropIconThemeCache"
diff --git a/pkgs/development/libraries/icu/base.nix b/pkgs/development/libraries/icu/base.nix
index 0a8cb7d4684..47ca63fca99 100644
--- a/pkgs/development/libraries/icu/base.nix
+++ b/pkgs/development/libraries/icu/base.nix
@@ -63,10 +63,16 @@ let
# remove dependency on bootstrap-tools in early stdenv build
postInstall = stdenv.lib.optionalString stdenv.isDarwin ''
sed -i 's/INSTALL_CMD=.*install/INSTALL_CMD=install/' $out/lib/icu/${version}/pkgdata.inc
- '' + ''
+ '' + (let
+ replacements = [
+ { from = "\${prefix}/include"; to = "${placeholder "dev"}/include"; } # --cppflags-searchpath
+ { from = "\${pkglibdir}/Makefile.inc"; to = "${placeholder "dev"}/lib/icu/Makefile.inc"; } # --incfile
+ { from = "\${pkglibdir}/pkgdata.inc"; to = "${placeholder "dev"}/lib/icu/pkgdata.inc"; } # --incpkgdatafile
+ ];
+ in ''
substituteInPlace "$dev/bin/icu-config" \
- --replace \''${pkglibdir}/Makefile.inc "$dev/lib/icu/Makefile.inc"
- '';
+ ${lib.concatMapStringsSep " " (r: "--replace '${r.from}' '${r.to}'") replacements}
+ '');
postFixup = ''moveToOutput lib/icu "$dev" '';
};
diff --git a/pkgs/development/libraries/leptonica/default.nix b/pkgs/development/libraries/leptonica/default.nix
index 62c01e4f356..e26f4f6022a 100644
--- a/pkgs/development/libraries/leptonica/default.nix
+++ b/pkgs/development/libraries/leptonica/default.nix
@@ -16,7 +16,9 @@ stdenv.mkDerivation rec {
enableParallelBuilding = true;
checkInputs = [ which gnuplot ];
- doCheck = !stdenv.isDarwin;
+
+ # Fails on pngio_reg for unknown reason
+ doCheck = false; # !stdenv.isDarwin;
meta = {
description = "Image processing and analysis library";
diff --git a/pkgs/development/libraries/libglvnd/default.nix b/pkgs/development/libraries/libglvnd/default.nix
index 30b27d9329a..5df1246a0eb 100644
--- a/pkgs/development/libraries/libglvnd/default.nix
+++ b/pkgs/development/libraries/libglvnd/default.nix
@@ -14,6 +14,22 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ autoreconfHook pkgconfig python2 addOpenGLRunpath ];
buildInputs = [ libX11 libXext xorgproto ];
+ # The following 3 patches should be removed once libglvnd >1.2.0 is released
+ patches = [
+ (fetchpatch {
+ url = "https://github.com/NVIDIA/libglvnd/commit/6f52473dac08c44b081b792874b4ce73122096da.patch";
+ sha256 = "0rd9ihl8n33cm0rya5a7ki0hn31fh52r0gaj5d4w80jrsah2ayij";
+ })
+ (fetchpatch {
+ url = "https://github.com/NVIDIA/libglvnd/commit/51233cc52cbcbe25f8461830913c06f5b5bc9508.patch";
+ sha256 = "1qx3nw8vq5xcrixmi7xw1vpy4gbf7kmx38rx8wg8x046g4mv8ijj";
+ })
+ (fetchpatch {
+ url = "https://github.com/NVIDIA/libglvnd/commit/5dfdc5a6dc60a3bdc63cd4510dabacba388da13a.patch";
+ sha256 = "0gmb3619yz3z7n22afjh8p2y13bmsky4r0z0csm14is3wvdi64ya";
+ })
+ ];
+
postPatch = lib.optionalString stdenv.isDarwin ''
substituteInPlace src/GLX/Makefile.am \
--replace "-Wl,-Bsymbolic " ""
diff --git a/pkgs/development/libraries/libiconv/setup-hook.sh b/pkgs/development/libraries/libiconv/setup-hook.sh
index f89361a6299..120cf06c61b 100644
--- a/pkgs/development/libraries/libiconv/setup-hook.sh
+++ b/pkgs/development/libraries/libiconv/setup-hook.sh
@@ -2,7 +2,7 @@
# it doesn't hurt to have it in Glibc either though
# See pkgs/build-support/setup-hooks/role.bash
-if [ -z "$dontAddExtraLibs" ]; then
+if [ -z "${dontAddExtraLibs-}" ]; then
getHostRole
export NIX_${role_pre}LDFLAGS+=" -liconv"
fi
diff --git a/pkgs/development/libraries/libmad/001-mips_removal_h_constraint.patch b/pkgs/development/libraries/libmad/001-mips_removal_h_constraint.patch
deleted file mode 100644
index 1d8b385e0c5..00000000000
--- a/pkgs/development/libraries/libmad/001-mips_removal_h_constraint.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-Taken from openwrt:
-https://dev.openwrt.org/browser/packages/libs/libmad/patches/001-mips_removal_h_constraint.patch?rev=18548
-
-diff -ur libmad-0.15.1b-orig/fixed.h libmad-0.15.1b/fixed.h
---- libmad-0.15.1b-orig/fixed.h 2004-02-17 12:32:03.000000000 +1030
-+++ libmad-0.15.1b/fixed.h 2009-08-05 10:46:30.000000000 +0930
-@@ -299,6 +299,23 @@
-
- # elif defined(FPM_MIPS)
-
-+/* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */
-+#if defined (__GNUC__) && defined (__GNUC_MINOR__)
-+#define __GNUC_PREREQ(maj, min) \
-+ ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
-+#else
-+#define __GNUC_PREREQ(maj, min) 0
-+#endif
-+
-+#if __GNUC_PREREQ(4,4)
-+ typedef unsigned int u64_di_t __attribute__ ((mode (DI)));
-+# define MAD_F_MLX(hi, lo, x, y) \
-+ do { \
-+ u64_di_t __ll = (u64_di_t) (x) * (y); \
-+ hi = __ll >> 32; \
-+ lo = __ll; \
-+ } while (0)
-+#else
- /*
- * This MIPS version is fast and accurate; the disposition of the least
- * significant bit depends on OPT_ACCURACY via mad_f_scale64().
-@@ -328,6 +345,7 @@
- : "%r" ((x) >> 12), "r" ((y) >> 16))
- # define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo))
- # endif
-+#endif /* __GNU_PREREQ(4,4) */
-
- # if defined(OPT_SPEED)
- # define mad_f_scale64(hi, lo) \
-diff -ur libmad-0.15.1b-orig/mad.h libmad-0.15.1b/mad.h
---- libmad-0.15.1b-orig/mad.h 2004-02-17 13:25:44.000000000 +1030
-+++ libmad-0.15.1b/mad.h 2009-08-05 10:42:40.000000000 +0930
-@@ -344,6 +344,23 @@
-
- # elif defined(FPM_MIPS)
-
-+/* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */
-+#if defined (__GNUC__) && defined (__GNUC_MINOR__)
-+#define __GNUC_PREREQ(maj, min) \
-+ ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
-+#else
-+#define __GNUC_PREREQ(maj, min) 0
-+#endif
-+
-+#if __GNUC_PREREQ(4,4)
-+ typedef unsigned int u64_di_t __attribute__ ((mode (DI)));
-+# define MAD_F_MLX(hi, lo, x, y) \
-+ do { \
-+ u64_di_t __ll = (u64_di_t) (x) * (y); \
-+ hi = __ll >> 32; \
-+ lo = __ll; \
-+ } while (0)
-+#else
- /*
- * This MIPS version is fast and accurate; the disposition of the least
- * significant bit depends on OPT_ACCURACY via mad_f_scale64().
-@@ -373,6 +390,7 @@
- : "%r" ((x) >> 12), "r" ((y) >> 16))
- # define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo))
- # endif
-+#endif /* __GNU_PREREQ(4,4) */
-
- # if defined(OPT_SPEED)
- # define mad_f_scale64(hi, lo) \
diff --git a/pkgs/development/libraries/libmad/default.nix b/pkgs/development/libraries/libmad/default.nix
index f6df090e8b5..40d90f46288 100644
--- a/pkgs/development/libraries/libmad/default.nix
+++ b/pkgs/development/libraries/libmad/default.nix
@@ -1,27 +1,57 @@
-{stdenv, fetchurl, autoconf}:
+{ stdenv, fetchurl, fetchpatch, autoconf }:
stdenv.mkDerivation rec {
- name = "libmad-0.15.1b";
-
+ pname = "libmad";
+ version = "0.15.1b";
+
src = fetchurl {
- url = "mirror://sourceforge/mad/${name}.tar.gz";
- sha256 = "bbfac3ed6bfbc2823d3775ebb931087371e142bb0e9bb1bee51a76a6e0078690";
+ url = "mirror://sourceforge/mad/${pname}-${version}.tar.gz";
+ sha256 = "14460zhacxhswnzb36qfpd1f2wbk10qvksvm6wyq5hpvdgnw7ymv";
};
- patches = [ ./001-mips_removal_h_constraint.patch ./pkgconfig.patch ]
+ patches = [
+ (fetchpatch {
+ url = "https://github.com/openwrt/packages/raw/openwrt-19.07/libs/libmad/patches/001-mips_removal_h_constraint.patch";
+ sha256 = "0layswr6qg6axf4vyz6xrv73jwga34mkma3ifk9w9vrk41454hr5";
+ })
+ (fetchpatch {
+ url = "https://github.com/KaOSx/main/raw/1270b8080f37fb6cca562829a521991800b0a497/libmad/libmad.patch";
+ sha256 = "0rysq0sn3dfdz6pa6bfqkmk4ymc4rzk5ym7p16dyk37sldg1pbzs";
+ })
+ (fetchpatch {
+ url = "https://github.com/KaOSx/main/raw/1270b8080f37fb6cca562829a521991800b0a497/libmad/amd64-64bit.diff";
+ sha256 = "0mx56dmkbvw3zxnqd2hjng48q0d7q7473pns4n0ksdam29b0c5ar";
+ })
+ (fetchpatch {
+ name = "CVE-2017-8372-CVE-2017-8373.patch";
+ url = "https://github.com/openwrt/packages/raw/openwrt-19.07/libs/libmad/patches/102-CVE-2017-8373-CVE-2017-8372-md-size.patch";
+ sha256 = "0p6mkpn66h1ds8jvww28q4vlr58jwm58m9vb7pkvvyvy764agqnk";
+ })
+ (fetchpatch {
+ name = "CVE-2017-8374.patch";
+ url = "https://github.com/openwrt/packages/raw/openwrt-19.07/libs/libmad/patches/101-CVE-2017-8374-length-check.patch";
+ sha256 = "1j1ssxwmx9nfahzl62frbzck93xrjc2v3w30c12vmk29iflf1890";
+ })
+ ]
# optimize.diff is taken from https://projects.archlinux.org/svntogit/packages.git/tree/trunk/optimize.diff?h=packages/libmad
# It is included here in order to fix a build failure in Clang
# But it may be useful to fix other, currently unknown problems as well
- ++ stdenv.lib.optional stdenv.cc.isClang [ ./optimize.diff ];
+ ++ stdenv.lib.optionals stdenv.cc.isClang [
+ (fetchpatch {
+ url = "https://github.com/KaOSx/main/raw/1270b8080f37fb6cca562829a521991800b0a497/libmad/optimize.diff";
+ sha256 = "0ciyaj1acg08g8hpzqx6whayq206fvf4whksz2pjgxlv207lqgjh";
+ })
+ ];
+
+ # The -fforce-mem flag has been removed in GCC 4.3.
+ postPatch = ''
+ substituteInPlace configure.ac --replace "-fforce-mem" ""
+ substituteInPlace configure.ac --replace "arch=\"-march=i486\"" ""
+ '';
nativeBuildInputs = [ autoconf ];
- # The -fforce-mem flag has been removed in GCC 4.3.
- preConfigure = ''
- autoconf
- substituteInPlace configure --replace "-fforce-mem" ""
- substituteInPlace configure --replace "arch=\"-march=i486\"" ""
- '';
+ preConfigure = "autoconf";
meta = with stdenv.lib; {
homepage = https://sourceforge.net/projects/mad/;
diff --git a/pkgs/development/libraries/libmad/optimize.diff b/pkgs/development/libraries/libmad/optimize.diff
deleted file mode 100644
index 1418dc92707..00000000000
--- a/pkgs/development/libraries/libmad/optimize.diff
+++ /dev/null
@@ -1,77 +0,0 @@
-Index: libmad-0.15.1b/configure.ac
-===================================================================
---- libmad-0.15.1b.orig/configure.ac 2008-03-07 20:31:23.000000000 +0000
-+++ libmad-0.15.1b/configure.ac 2008-03-07 20:34:26.000000000 +0000
-@@ -124,71 +124,7 @@
-
- if test "$GCC" = yes
- then
-- if test -z "$arch"
-- then
-- case "$host" in
-- i386-*) ;;
-- i?86-*) arch="-march=i486" ;;
-- arm*-empeg-*) arch="-march=armv4 -mtune=strongarm1100" ;;
-- armv4*-*) arch="-march=armv4 -mtune=strongarm" ;;
-- powerpc-*) ;;
-- mips*-agenda-*) arch="-mcpu=vr4100" ;;
-- mips*-luxsonor-*) arch="-mips1 -mcpu=r3000 -Wa,-m4010" ;;
-- esac
-- fi
--
-- case "$optimize" in
-- -O|"-O "*)
-- optimize="-O"
-- optimize="$optimize -fforce-mem"
-- optimize="$optimize -fforce-addr"
-- : #x optimize="$optimize -finline-functions"
-- : #- optimize="$optimize -fstrength-reduce"
-- optimize="$optimize -fthread-jumps"
-- optimize="$optimize -fcse-follow-jumps"
-- optimize="$optimize -fcse-skip-blocks"
-- : #x optimize="$optimize -frerun-cse-after-loop"
-- : #x optimize="$optimize -frerun-loop-opt"
-- : #x optimize="$optimize -fgcse"
-- optimize="$optimize -fexpensive-optimizations"
-- optimize="$optimize -fregmove"
-- : #* optimize="$optimize -fdelayed-branch"
-- : #x optimize="$optimize -fschedule-insns"
-- optimize="$optimize -fschedule-insns2"
-- : #? optimize="$optimize -ffunction-sections"
-- : #? optimize="$optimize -fcaller-saves"
-- : #> optimize="$optimize -funroll-loops"
-- : #> optimize="$optimize -funroll-all-loops"
-- : #x optimize="$optimize -fmove-all-movables"
-- : #x optimize="$optimize -freduce-all-givs"
-- : #? optimize="$optimize -fstrict-aliasing"
-- : #* optimize="$optimize -fstructure-noalias"
--
-- case "$host" in
-- arm*-*)
-- optimize="$optimize -fstrength-reduce"
-- ;;
-- mips*-*)
-- optimize="$optimize -fstrength-reduce"
-- optimize="$optimize -finline-functions"
-- ;;
-- i?86-*)
-- optimize="$optimize -fstrength-reduce"
-- ;;
-- powerpc-apple-*)
-- # this triggers an internal compiler error with gcc2
-- : #optimize="$optimize -fstrength-reduce"
--
-- # this is really only beneficial with gcc3
-- : #optimize="$optimize -finline-functions"
-- ;;
-- *)
-- # this sometimes provokes bugs in gcc 2.95.2
-- : #optimize="$optimize -fstrength-reduce"
-- ;;
-- esac
-- ;;
-- esac
-+ optimize="-O2"
- fi
-
- case "$host" in
diff --git a/pkgs/development/libraries/libmad/pkgconfig.patch b/pkgs/development/libraries/libmad/pkgconfig.patch
deleted file mode 100644
index 0ac88acb841..00000000000
--- a/pkgs/development/libraries/libmad/pkgconfig.patch
+++ /dev/null
@@ -1,117 +0,0 @@
-diff -ruN libmad-0.15.1b.orig/Makefile.am libmad-0.15.1b/Makefile.am
---- libmad-0.15.1b.orig/Makefile.am 2004-02-17 02:02:03.000000000 +0000
-+++ libmad-0.15.1b/Makefile.am 2005-08-25 12:08:04.000000000 +0000
-@@ -33,9 +33,12 @@
- minimad_INCLUDES =
- minimad_LDADD = libmad.la
-
--EXTRA_DIST = mad.h.sed \
-+EXTRA_DIST = mad.h.sed mad.pc.in \
- CHANGES COPYRIGHT CREDITS README TODO VERSION
-
-+pkgconfigdir = $(libdir)/pkgconfig
-+pkgconfig_DATA= mad.pc
-+
- exported_headers = version.h fixed.h bit.h timer.h stream.h frame.h \
- synth.h decoder.h
-
-diff -ruN libmad-0.15.1b.orig/Makefile.in libmad-0.15.1b/Makefile.in
---- libmad-0.15.1b.orig/Makefile.in 2004-02-17 02:33:23.000000000 +0000
-+++ libmad-0.15.1b/Makefile.in 2005-08-25 12:09:34.000000000 +0000
-@@ -14,6 +14,8 @@
-
- @SET_MAKE@
-
-+pkgconfigdir = $(libdir)/pkgconfig
-+pkgconfig_DATA = mad.pc
-
- SOURCES = $(libmad_la_SOURCES) $(EXTRA_libmad_la_SOURCES) $(minimad_SOURCES)
-
-@@ -43,7 +45,7 @@
- $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
- $(srcdir)/config.h.in $(srcdir)/libmad.list.in \
- $(top_srcdir)/configure COPYING INSTALL TODO config.guess \
-- config.sub depcomp install-sh ltmain.sh missing mkinstalldirs
-+ config.sub depcomp install-sh ltmain.sh missing mkinstalldirs mad.pc.in
- subdir = .
- ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
- am__aclocal_m4_deps = $(top_srcdir)/configure.ac
-@@ -53,7 +55,7 @@
- configure.lineno configure.status.lineno
- mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
- CONFIG_HEADER = config.h
--CONFIG_CLEAN_FILES = libmad.list
-+CONFIG_CLEAN_FILES = libmad.list mad.pc
- am__installdirs = $(DESTDIR)$(libdir) $(DESTDIR)$(includedir)
- libLTLIBRARIES_INSTALL = $(INSTALL)
- LTLIBRARIES = $(lib_LTLIBRARIES)
-@@ -218,7 +220,7 @@
- minimad_SOURCES = minimad.c
- minimad_INCLUDES =
- minimad_LDADD = libmad.la
--EXTRA_DIST = mad.h.sed \
-+EXTRA_DIST = mad.h.sed mad.pc.in \
- CHANGES COPYRIGHT CREDITS README TODO VERSION
-
- exported_headers = version.h fixed.h bit.h timer.h stream.h frame.h \
-@@ -298,6 +300,28 @@
- rm -f stamp-h1
- touch $@
-
-+mad.pc: $(top_builddir)/config.status mad.pc.in
-+ cd $(top_builddir) && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
-+
-+install-pkgconfigDATA: $(pkgconfig_DATA)
-+ @$(NORMAL_INSTALL)
-+ $(mkinstalldirs) $(DESTDIR)$(pkgconfigdir)
-+ @list='$(pkgconfig_DATA)'; for p in $$list; do \
-+ if test -f $(srcdir)/$$p; then \
-+ echo " $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(pkgconfigdir)/$$p"; \
-+ $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(pkgconfigdir)/$$p; \
-+ else if test -f $$p; then \
-+ echo " $(INSTALL_DATA) $$p $(DESTDIR)$(pkgconfigdir)/$$p"; \
-+ $(INSTALL_DATA) $$p $(DESTDIR)$(pkgconfigdir)/$$p; \
-+ fi; fi; \
-+ done
-+
-+uninstall-pkgconfigDATA:
-+ @$(NORMAL_UNINSTALL)
-+ list='$(pkgconfig_DATA)'; for p in $$list; do \
-+ rm -f $(DESTDIR)$(pkgconfigdir)/$$p; \
-+ done
-+
- distclean-hdr:
- -rm -f config.h stamp-h1
- libmad.list: $(top_builddir)/config.status $(srcdir)/libmad.list.in
-@@ -726,7 +750,7 @@
-
- info-am:
-
--install-data-am: install-includeHEADERS
-+install-data-am: install-includeHEADERS install-pkgconfigDATA
-
- install-exec-am: install-libLTLIBRARIES
-
-@@ -757,7 +781,7 @@
- ps-am:
-
- uninstall-am: uninstall-includeHEADERS uninstall-info-am \
-- uninstall-libLTLIBRARIES
-+ uninstall-libLTLIBRARIES install-pkgconfigDATA
-
- uninstall-info: uninstall-info-recursive
-
-diff -ruN libmad-0.15.1b.orig/mad.pc.in libmad-0.15.1b/mad.pc.in
---- libmad-0.15.1b.orig/mad.pc.in 1970-01-01 00:00:00.000000000 +0000
-+++ libmad-0.15.1b/mad.pc.in 2005-08-25 12:08:04.000000000 +0000
-@@ -0,0 +1,10 @@
-+prefix=@prefix@
-+exec_prefix=@exec_prefix@
-+libdir=@libdir@
-+includedir=@includedir@
-+
-+Name: MAD
-+Description: libmad - MPEG audio decoder library
-+Version: @VERSION@
-+Libs: -L${libdir} -lmad
-+Cflags:
diff --git a/pkgs/development/libraries/libnice/default.nix b/pkgs/development/libraries/libnice/default.nix
index f4ce1f6eea0..90bdb06bb7f 100644
--- a/pkgs/development/libraries/libnice/default.nix
+++ b/pkgs/development/libraries/libnice/default.nix
@@ -1,4 +1,19 @@
-{ stdenv, fetchurl, fetchpatch, meson, ninja, pkgconfig, python3, gobject-introspection, gtk-doc, docbook_xsl, docbook_xml_dtd_412, glib, gupnp-igd, gst_all_1, gnutls }:
+{ stdenv
+, fetchurl
+, fetchpatch
+, meson
+, ninja
+, pkgconfig
+, python3
+, gobject-introspection
+, gtk-doc
+, docbook_xsl
+, docbook_xml_dtd_412
+, glib
+, gupnp-igd
+, gst_all_1
+, gnutls
+}:
stdenv.mkDerivation rec {
name = "libnice-0.1.16";
@@ -21,27 +36,40 @@ stdenv.mkDerivation rec {
];
nativeBuildInputs = [
- meson ninja pkgconfig python3 gobject-introspection
+ meson
+ ninja
+ pkgconfig
+ python3
+ gobject-introspection
+
+ # documentation
gtk-doc
- # Without these, enabling the 'gtk_doc' gives us `FAILED: meson-install`
- docbook_xsl docbook_xml_dtd_412
+ docbook_xsl
+ docbook_xml_dtd_412
+ ];
+
+ buildInputs = [
+ gst_all_1.gstreamer
+ gst_all_1.gst-plugins-base
+ gnutls
+ gupnp-igd
+ ];
+
+ propagatedBuildInputs = [
+ glib
];
- buildInputs = [ gst_all_1.gstreamer gst_all_1.gst-plugins-base gnutls ];
- propagatedBuildInputs = [ glib gupnp-igd ];
mesonFlags = [
- # Enables all features, so that we know when new dependencies are necessary.
- "-Dauto_features=enabled"
"-Dgtk_doc=enabled" # Disabled by default as of libnice-0.1.15
"-Dexamples=disabled" # requires many dependencies and probably not useful for our users
];
- # TODO; see #53293 etc.
- #doCheck = true;
+ # Tests are flaky
+ # see https://github.com/NixOS/nixpkgs/pull/53293#issuecomment-453739295
+ doCheck = false;
meta = with stdenv.lib; {
- homepage = https://nice.freedesktop.org/wiki/;
- description = "The GLib ICE implementation";
+ description = "GLib ICE implementation";
longDescription = ''
Libnice is an implementation of the IETF's Interactice Connectivity
Establishment (ICE) standard (RFC 5245) and the Session Traversal
@@ -49,6 +77,7 @@ stdenv.mkDerivation rec {
It provides a GLib-based library, libnice and a Glib-free library,
libstun as well as GStreamer elements.'';
+ homepage = "https://nice.freedesktop.org/wiki/";
platforms = platforms.linux;
license = with licenses; [ lgpl21 mpl11 ];
};
diff --git a/pkgs/development/libraries/libpsl/default.nix b/pkgs/development/libraries/libpsl/default.nix
index 15aa7c9e22d..d2012760dcf 100644
--- a/pkgs/development/libraries/libpsl/default.nix
+++ b/pkgs/development/libraries/libpsl/default.nix
@@ -1,5 +1,16 @@
-{ stdenv, fetchurl, autoreconfHook, docbook_xsl, docbook_xml_dtd_43, gtk-doc, lzip
-, libidn2, libunistring, libxslt, pkgconfig, python3, valgrind
+{ stdenv
+, fetchurl
+, autoreconfHook
+, docbook_xsl
+, docbook_xml_dtd_43
+, gtk-doc
+, lzip
+, libidn2
+, libunistring
+, libxslt
+, pkgconfig
+, python3
+, valgrind
, publicsuffix-list
}:
@@ -12,9 +23,26 @@ stdenv.mkDerivation rec {
sha256 = "183hadbira0d2zvv8272lspy31dgm9x26z35c61s5axcd5wd9g9i";
};
- nativeBuildInputs = [ autoreconfHook docbook_xsl docbook_xml_dtd_43 gtk-doc lzip pkgconfig python3 valgrind ];
- buildInputs = [ libidn2 libunistring libxslt ];
- propagatedBuildInputs = [ publicsuffix-list ];
+ nativeBuildInputs = [
+ autoreconfHook
+ docbook_xsl
+ docbook_xml_dtd_43
+ gtk-doc
+ lzip
+ pkgconfig
+ python3
+ valgrind
+ ];
+
+ buildInputs = [
+ libidn2
+ libunistring
+ libxslt
+ ];
+
+ propagatedBuildInputs = [
+ publicsuffix-list
+ ];
postPatch = ''
patchShebangs src/psl-make-dafsa
@@ -25,7 +53,7 @@ stdenv.mkDerivation rec {
'';
configureFlags = [
-# "--enable-gtk-doc"
+ # "--enable-gtk-doc"
"--enable-man"
"--enable-valgrind-tests"
"--with-psl-distfile=${publicsuffix-list}/share/publicsuffix/public_suffix_list.dat"
@@ -35,7 +63,7 @@ stdenv.mkDerivation rec {
enableParallelBuilding = true;
- doCheck = true;
+ doCheck = !stdenv.isDarwin;
meta = with stdenv.lib; {
description = "C library for the Publix Suffix List";
diff --git a/pkgs/development/libraries/libtiff/CVE-2019-14973.patch b/pkgs/development/libraries/libtiff/CVE-2019-14973.patch
deleted file mode 100644
index 1dc75246902..00000000000
--- a/pkgs/development/libraries/libtiff/CVE-2019-14973.patch
+++ /dev/null
@@ -1,384 +0,0 @@
-diff -ru tiff-4.0.10-orig/libtiff/tif_aux.c tiff-4.0.10/libtiff/tif_aux.c
---- tiff-4.0.10-orig/libtiff/tif_aux.c 2017-12-02 16:21:47.305709555 +0100
-+++ tiff-4.0.10/libtiff/tif_aux.c 2019-10-02 22:35:17.392184463 +0200
-@@ -57,18 +57,57 @@
- return bytes;
- }
-
-+tmsize_t
-+_TIFFMultiplySSize(TIFF* tif, tmsize_t first, tmsize_t second, const char* where)
-+{
-+ if( first <= 0 || second <= 0 )
-+ {
-+ if( tif != NULL && where != NULL )
-+ {
-+ TIFFErrorExt(tif->tif_clientdata, where,
-+ "Invalid argument to _TIFFMultiplySSize() in %s", where);
-+ }
-+ return 0;
-+ }
-+
-+ if( first > TIFF_TMSIZE_T_MAX / second )
-+ {
-+ if( tif != NULL && where != NULL )
-+ {
-+ TIFFErrorExt(tif->tif_clientdata, where,
-+ "Integer overflow in %s", where);
-+ }
-+ return 0;
-+ }
-+ return first * second;
-+}
-+
-+tmsize_t _TIFFCastUInt64ToSSize(TIFF* tif, uint64 val, const char* module)
-+{
-+ if( val > (uint64)TIFF_TMSIZE_T_MAX )
-+ {
-+ if( tif != NULL && module != NULL )
-+ {
-+ TIFFErrorExt(tif->tif_clientdata,module,"Integer overflow");
-+ }
-+ return 0;
-+ }
-+ return (tmsize_t)val;
-+}
-+
- void*
- _TIFFCheckRealloc(TIFF* tif, void* buffer,
- tmsize_t nmemb, tmsize_t elem_size, const char* what)
- {
- void* cp = NULL;
-- tmsize_t bytes = nmemb * elem_size;
--
-+ tmsize_t count = _TIFFMultiplySSize(tif, nmemb, elem_size, NULL);
- /*
-- * XXX: Check for integer overflow.
-+ * Check for integer overflow.
- */
-- if (nmemb && elem_size && bytes / elem_size == nmemb)
-- cp = _TIFFrealloc(buffer, bytes);
-+ if (count != 0)
-+ {
-+ cp = _TIFFrealloc(buffer, count);
-+ }
-
- if (cp == NULL) {
- TIFFErrorExt(tif->tif_clientdata, tif->tif_name,
-diff -ru tiff-4.0.10-orig/libtiff/tiffiop.h tiff-4.0.10/libtiff/tiffiop.h
---- tiff-4.0.10-orig/libtiff/tiffiop.h 2018-11-03 15:28:37.748910968 +0100
-+++ tiff-4.0.10/libtiff/tiffiop.h 2019-10-02 22:35:17.396184535 +0200
-@@ -77,6 +77,9 @@
- #define FALSE 0
- #endif
-
-+#define TIFF_SIZE_T_MAX ((size_t) ~ ((size_t)0))
-+#define TIFF_TMSIZE_T_MAX (tmsize_t)(TIFF_SIZE_T_MAX >> 1)
-+
- typedef struct client_info {
- struct client_info *next;
- void *data;
-@@ -258,7 +261,7 @@
- #define TIFFhowmany8_64(x) (((x)&0x07)?((uint64)(x)>>3)+1:(uint64)(x)>>3)
- #define TIFFroundup_64(x, y) (TIFFhowmany_64(x,y)*(y))
-
--/* Safe multiply which returns zero if there is an integer overflow */
-+/* Safe multiply which returns zero if there is an *unsigned* integer overflow. This macro is not safe for *signed* integer types */
- #define TIFFSafeMultiply(t,v,m) ((((t)(m) != (t)0) && (((t)(((v)*(m))/(m))) == (t)(v))) ? (t)((v)*(m)) : (t)0)
-
- #define TIFFmax(A,B) ((A)>(B)?(A):(B))
-@@ -368,6 +371,8 @@
-
- extern uint32 _TIFFMultiply32(TIFF*, uint32, uint32, const char*);
- extern uint64 _TIFFMultiply64(TIFF*, uint64, uint64, const char*);
-+extern tmsize_t _TIFFMultiplySSize(TIFF*, tmsize_t, tmsize_t, const char*);
-+extern tmsize_t _TIFFCastUInt64ToSSize(TIFF*, uint64, const char*);
- extern void* _TIFFCheckMalloc(TIFF*, tmsize_t, tmsize_t, const char*);
- extern void* _TIFFCheckRealloc(TIFF*, void*, tmsize_t, tmsize_t, const char*);
-
-diff -ru tiff-4.0.10-orig/libtiff/tif_getimage.c tiff-4.0.10/libtiff/tif_getimage.c
---- tiff-4.0.10-orig/libtiff/tif_getimage.c 2017-12-02 16:21:47.654716127 +0100
-+++ tiff-4.0.10/libtiff/tif_getimage.c 2019-10-02 22:35:17.393184481 +0200
-@@ -755,9 +755,8 @@
- uint32 leftmost_tw;
-
- tilesize = TIFFTileSize(tif);
-- bufsize = TIFFSafeMultiply(tmsize_t,alpha?4:3,tilesize);
-+ bufsize = _TIFFMultiplySSize(tif, alpha?4:3,tilesize, "gtTileSeparate");
- if (bufsize == 0) {
-- TIFFErrorExt(tif->tif_clientdata, TIFFFileName(tif), "Integer overflow in %s", "gtTileSeparate");
- return (0);
- }
-
-@@ -1019,9 +1018,8 @@
- uint16 colorchannels;
-
- stripsize = TIFFStripSize(tif);
-- bufsize = TIFFSafeMultiply(tmsize_t,alpha?4:3,stripsize);
-+ bufsize = _TIFFMultiplySSize(tif,alpha?4:3,stripsize, "gtStripSeparate");
- if (bufsize == 0) {
-- TIFFErrorExt(tif->tif_clientdata, TIFFFileName(tif), "Integer overflow in %s", "gtStripSeparate");
- return (0);
- }
-
-diff -ru tiff-4.0.10-orig/libtiff/tif_luv.c tiff-4.0.10/libtiff/tif_luv.c
---- tiff-4.0.10-orig/libtiff/tif_luv.c 2018-05-05 15:50:35.884596907 +0200
-+++ tiff-4.0.10/libtiff/tif_luv.c 2019-10-02 22:35:17.393184481 +0200
-@@ -1264,16 +1264,10 @@
- return (SGILOGDATAFMT_UNKNOWN);
- }
-
--
--#define TIFF_SIZE_T_MAX ((size_t) ~ ((size_t)0))
--#define TIFF_TMSIZE_T_MAX (tmsize_t)(TIFF_SIZE_T_MAX >> 1)
--
- static tmsize_t
- multiply_ms(tmsize_t m1, tmsize_t m2)
- {
-- if( m1 == 0 || m2 > TIFF_TMSIZE_T_MAX / m1 )
-- return 0;
-- return m1 * m2;
-+ return _TIFFMultiplySSize(NULL, m1, m2, NULL);
- }
-
- static int
-diff -ru tiff-4.0.10-orig/libtiff/tif_pixarlog.c tiff-4.0.10/libtiff/tif_pixarlog.c
---- tiff-4.0.10-orig/libtiff/tif_pixarlog.c 2017-12-02 16:21:47.841162432 +0100
-+++ tiff-4.0.10/libtiff/tif_pixarlog.c 2019-10-02 22:36:01.223970118 +0200
-@@ -634,15 +634,10 @@
- return guess;
- }
-
--#define TIFF_SIZE_T_MAX ((size_t) ~ ((size_t)0))
--#define TIFF_TMSIZE_T_MAX (tmsize_t)(TIFF_SIZE_T_MAX >> 1)
--
- static tmsize_t
- multiply_ms(tmsize_t m1, tmsize_t m2)
- {
-- if( m1 == 0 || m2 > TIFF_TMSIZE_T_MAX / m1 )
-- return 0;
-- return m1 * m2;
-+ return _TIFFMultiplySSize(NULL, m1, m2, NULL);
- }
-
- static tmsize_t
-diff -ru tiff-4.0.10-orig/libtiff/tif_read.c tiff-4.0.10/libtiff/tif_read.c
---- tiff-4.0.10-orig/libtiff/tif_read.c 2018-10-14 21:15:27.551093695 +0200
-+++ tiff-4.0.10/libtiff/tif_read.c 2019-10-02 22:41:09.387290927 +0200
-@@ -29,9 +29,6 @@
- #include "tiffiop.h"
- #include
-
--#define TIFF_SIZE_T_MAX ((size_t) ~ ((size_t)0))
--#define TIFF_TMSIZE_T_MAX (tmsize_t)(TIFF_SIZE_T_MAX >> 1)
--
- int TIFFFillStrip(TIFF* tif, uint32 strip);
- int TIFFFillTile(TIFF* tif, uint32 tile);
- static int TIFFStartStrip(TIFF* tif, uint32 strip);
-@@ -49,6 +46,8 @@
- #define THRESHOLD_MULTIPLIER 10
- #define MAX_THRESHOLD (THRESHOLD_MULTIPLIER * THRESHOLD_MULTIPLIER * THRESHOLD_MULTIPLIER * INITIAL_THRESHOLD)
-
-+#define TIFF_INT64_MAX ((((int64)0x7FFFFFFF) << 32) | 0xFFFFFFFF)
-+
- /* Read 'size' bytes in tif_rawdata buffer starting at offset 'rawdata_offset'
- * Returns 1 in case of success, 0 otherwise. */
- static int TIFFReadAndRealloc( TIFF* tif, tmsize_t size,
-@@ -734,23 +733,8 @@
- return ((tmsize_t)(-1));
- }
- bytecount = td->td_stripbytecount[strip];
-- if ((int64)bytecount <= 0) {
--#if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
-- TIFFErrorExt(tif->tif_clientdata, module,
-- "%I64u: Invalid strip byte count, strip %lu",
-- (unsigned __int64) bytecount,
-- (unsigned long) strip);
--#else
-- TIFFErrorExt(tif->tif_clientdata, module,
-- "%llu: Invalid strip byte count, strip %lu",
-- (unsigned long long) bytecount,
-- (unsigned long) strip);
--#endif
-- return ((tmsize_t)(-1));
-- }
-- bytecountm = (tmsize_t)bytecount;
-- if ((uint64)bytecountm!=bytecount) {
-- TIFFErrorExt(tif->tif_clientdata, module, "Integer overflow");
-+ bytecountm = _TIFFCastUInt64ToSSize(tif, bytecount, module);
-+ if (bytecountm == 0) {
- return ((tmsize_t)(-1));
- }
- if (size != (tmsize_t)(-1) && size < bytecountm)
-@@ -774,7 +758,7 @@
- if ((tif->tif_flags&TIFF_NOREADRAW)==0)
- {
- uint64 bytecount = td->td_stripbytecount[strip];
-- if ((int64)bytecount <= 0) {
-+ if( bytecount == 0 || bytecount > (uint64)TIFF_INT64_MAX ) {
- #if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
- TIFFErrorExt(tif->tif_clientdata, module,
- "Invalid strip byte count %I64u, strip %lu",
-@@ -801,7 +785,7 @@
- (bytecount - 4096) / 10 > (uint64)stripsize )
- {
- uint64 newbytecount = (uint64)stripsize * 10 + 4096;
-- if( (int64)newbytecount >= 0 )
-+ if( newbytecount == 0 || newbytecount > (uint64)TIFF_INT64_MAX )
- {
- #if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
- TIFFWarningExt(tif->tif_clientdata, module,
-@@ -1196,10 +1180,8 @@
- bytecount64 = td->td_stripbytecount[tile];
- if (size != (tmsize_t)(-1) && (uint64)size < bytecount64)
- bytecount64 = (uint64)size;
-- bytecountm = (tmsize_t)bytecount64;
-- if ((uint64)bytecountm!=bytecount64)
-- {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer overflow");
-+ bytecountm = _TIFFCastUInt64ToSSize(tif, bytecount64, module);
-+ if( bytecountm == 0 ) {
- return ((tmsize_t)(-1));
- }
- return (TIFFReadRawTile1(tif, tile, buf, bytecountm, module));
-@@ -1221,7 +1203,7 @@
- if ((tif->tif_flags&TIFF_NOREADRAW)==0)
- {
- uint64 bytecount = td->td_stripbytecount[tile];
-- if ((int64)bytecount <= 0) {
-+ if( bytecount == 0 || bytecount > (uint64)TIFF_INT64_MAX ) {
- #if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
- TIFFErrorExt(tif->tif_clientdata, module,
- "%I64u: Invalid tile byte count, tile %lu",
-@@ -1248,7 +1230,7 @@
- (bytecount - 4096) / 10 > (uint64)stripsize )
- {
- uint64 newbytecount = (uint64)stripsize * 10 + 4096;
-- if( (int64)newbytecount >= 0 )
-+ if( newbytecount == 0 || newbytecount > (uint64)TIFF_INT64_MAX )
- {
- #if defined(__WIN32__) && (defined(_MSC_VER) || defined(__MINGW32__))
- TIFFWarningExt(tif->tif_clientdata, module,
-diff -ru tiff-4.0.10-orig/libtiff/tif_strip.c tiff-4.0.10/libtiff/tif_strip.c
---- tiff-4.0.10-orig/libtiff/tif_strip.c 2017-12-02 16:21:47.947867167 +0100
-+++ tiff-4.0.10/libtiff/tif_strip.c 2019-10-02 22:35:17.395184517 +0200
-@@ -129,15 +129,8 @@
- {
- static const char module[] = "TIFFVStripSize";
- uint64 m;
-- tmsize_t n;
- m=TIFFVStripSize64(tif,nrows);
-- n=(tmsize_t)m;
-- if ((uint64)n!=m)
-- {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer overflow");
-- n=0;
-- }
-- return(n);
-+ return _TIFFCastUInt64ToSSize(tif, m, module);
- }
-
- /*
-@@ -211,15 +204,8 @@
- {
- static const char module[] = "TIFFStripSize";
- uint64 m;
-- tmsize_t n;
- m=TIFFStripSize64(tif);
-- n=(tmsize_t)m;
-- if ((uint64)n!=m)
-- {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer overflow");
-- n=0;
-- }
-- return(n);
-+ return _TIFFCastUInt64ToSSize(tif, m, module);
- }
-
- /*
-@@ -330,14 +316,8 @@
- {
- static const char module[] = "TIFFScanlineSize";
- uint64 m;
-- tmsize_t n;
- m=TIFFScanlineSize64(tif);
-- n=(tmsize_t)m;
-- if ((uint64)n!=m) {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer arithmetic overflow");
-- n=0;
-- }
-- return(n);
-+ return _TIFFCastUInt64ToSSize(tif, m, module);
- }
-
- /*
-@@ -366,15 +346,8 @@
- {
- static const char module[] = "TIFFRasterScanlineSize";
- uint64 m;
-- tmsize_t n;
- m=TIFFRasterScanlineSize64(tif);
-- n=(tmsize_t)m;
-- if ((uint64)n!=m)
-- {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer arithmetic overflow");
-- n=0;
-- }
-- return(n);
-+ return _TIFFCastUInt64ToSSize(tif, m, module);
- }
-
- /* vim: set ts=8 sts=8 sw=8 noet: */
-diff -ru tiff-4.0.10-orig/libtiff/tif_tile.c tiff-4.0.10/libtiff/tif_tile.c
---- tiff-4.0.10-orig/libtiff/tif_tile.c 2017-12-02 16:21:47.993972977 +0100
-+++ tiff-4.0.10/libtiff/tif_tile.c 2019-10-02 22:35:17.395184517 +0200
-@@ -181,15 +181,8 @@
- {
- static const char module[] = "TIFFTileRowSize";
- uint64 m;
-- tmsize_t n;
- m=TIFFTileRowSize64(tif);
-- n=(tmsize_t)m;
-- if ((uint64)n!=m)
-- {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer overflow");
-- n=0;
-- }
-- return(n);
-+ return _TIFFCastUInt64ToSSize(tif, m, module);
- }
-
- /*
-@@ -248,15 +241,8 @@
- {
- static const char module[] = "TIFFVTileSize";
- uint64 m;
-- tmsize_t n;
- m=TIFFVTileSize64(tif,nrows);
-- n=(tmsize_t)m;
-- if ((uint64)n!=m)
-- {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer overflow");
-- n=0;
-- }
-- return(n);
-+ return _TIFFCastUInt64ToSSize(tif, m, module);
- }
-
- /*
-@@ -272,15 +258,8 @@
- {
- static const char module[] = "TIFFTileSize";
- uint64 m;
-- tmsize_t n;
- m=TIFFTileSize64(tif);
-- n=(tmsize_t)m;
-- if ((uint64)n!=m)
-- {
-- TIFFErrorExt(tif->tif_clientdata,module,"Integer overflow");
-- n=0;
-- }
-- return(n);
-+ return _TIFFCastUInt64ToSSize(tif, m, module);
- }
-
- /*
diff --git a/pkgs/development/libraries/libtiff/default.nix b/pkgs/development/libraries/libtiff/default.nix
index c35923071b0..795ed439093 100644
--- a/pkgs/development/libraries/libtiff/default.nix
+++ b/pkgs/development/libraries/libtiff/default.nix
@@ -9,24 +9,14 @@
}:
stdenv.mkDerivation rec {
- version = "4.0.10";
+ version = "4.1.0";
pname = "libtiff";
src = fetchurl {
url = "https://download.osgeo.org/libtiff/tiff-${version}.tar.gz";
- sha256 = "1r4np635gr6zlc0bic38dzvxia6iqzcrary4n1ylarzpr8fd2lic";
+ sha256 = "0d46bdvxdiv59lxnb0xz9ywm8arsr6xsapi5s6y6vnys2wjz6aax";
};
- patches = [
- (fetchurl {
- url = "https://gitlab.com/libtiff/libtiff/commit/0c74a9f49b8d7a36b17b54a7428b3526d20f88a8.patch";
- name = "CVE-2019-6128.patch";
- sha256 = "03yvsfq6dxjd3v8ypfwz6cpz2iymqwcbawqqlmkh40dayi7fgizr";
- })
- # Manual backport of https://gitlab.com/libtiff/libtiff/commit/1b5e3b6a23827c33acf19ad50ce5ce78f12b3773.patch
- ./CVE-2019-14973.patch
- ];
-
outputs = [ "bin" "dev" "out" "man" "doc" ];
nativeBuildInputs = [ pkgconfig ];
diff --git a/pkgs/development/libraries/libtxc_dxtn/default.nix b/pkgs/development/libraries/libtxc_dxtn/default.nix
index 5ac456a60f6..600b1fb510a 100644
--- a/pkgs/development/libraries/libtxc_dxtn/default.nix
+++ b/pkgs/development/libraries/libtxc_dxtn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, libGLU_combined }:
+{ stdenv, fetchurl, autoreconfHook, libGL, libGLU }:
let version = "1.0.1"; in
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
};
nativeBuildInputs = [ autoreconfHook ];
- buildInputs = [ libGLU_combined ];
+ buildInputs = [ libGL libGLU ];
meta = with stdenv.lib; {
homepage = http://dri.freedesktop.org/wiki/S3TC;
diff --git a/pkgs/development/libraries/libtxc_dxtn_s2tc/default.nix b/pkgs/development/libraries/libtxc_dxtn_s2tc/default.nix
index 4959674f0ad..f9f44f5a653 100644
--- a/pkgs/development/libraries/libtxc_dxtn_s2tc/default.nix
+++ b/pkgs/development/libraries/libtxc_dxtn_s2tc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, libGLU_combined }:
+{ stdenv, fetchurl, autoreconfHook, libGL, libGLU }:
let version = "1.0"; in
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
};
nativeBuildInputs = [ autoreconfHook ];
- buildInputs = [ libGLU_combined ];
+ buildInputs = [ libGL libGLU ];
meta = {
description = "A patent-free S3TC compatible implementation";
diff --git a/pkgs/development/libraries/libxml2/default.nix b/pkgs/development/libraries/libxml2/default.nix
index 7ed50f61224..f5dcb3357f7 100644
--- a/pkgs/development/libraries/libxml2/default.nix
+++ b/pkgs/development/libraries/libxml2/default.nix
@@ -8,11 +8,11 @@
stdenv.mkDerivation rec {
pname = "libxml2";
- version = "2.9.9";
+ version = "2.9.10";
src = fetchurl {
url = "http://xmlsoft.org/sources/${pname}-${version}.tar.gz";
- sha256 = "0wd881jzvqayx0ihzba29jl80k06xj9ywp16kxacdqs3064p1ywl";
+ sha256 = "07xynh8hcxb2yb1fs051xrgszjvj37wnxvxgsj10rzmqzy9y3zma";
};
patches = [
# Upstream bugs:
@@ -53,6 +53,12 @@ stdenv.mkDerivation rec {
enableParallelBuilding = true;
+ # disable test that's problematic with newer pythons: see
+ # https://mail.gnome.org/archives/xml/2017-August/msg00014.html
+ preCheck = lib.optionalString (pythonSupport && !(python?pythonOlder && python.pythonOlder "3.5")) ''
+ echo "" > python/tests/tstLastError.py
+ '';
+
doCheck = (stdenv.hostPlatform == stdenv.buildPlatform) && !stdenv.isDarwin &&
stdenv.hostPlatform.libc != "musl";
diff --git a/pkgs/development/libraries/libxslt/default.nix b/pkgs/development/libraries/libxslt/default.nix
index ed77a1873a8..6d12329a7f5 100644
--- a/pkgs/development/libraries/libxslt/default.nix
+++ b/pkgs/development/libraries/libxslt/default.nix
@@ -10,31 +10,13 @@ with stdenv.lib;
stdenv.mkDerivation rec {
pname = "libxslt";
- version = "1.1.33";
+ version = "1.1.34";
src = fetchurl {
url = "http://xmlsoft.org/sources/${pname}-${version}.tar.gz";
- sha256 = "1j1q1swnsy8jgi9x7mclvkrqhfgn09886gdlr9wzk7a08i8n0dlf";
+ sha256 = "0zrzz6kjdyavspzik6fbkpvfpbd25r2qg6py5nnjaabrsr3bvccq";
};
- patches = [
- (fetchpatch {
- name = "CVE-2019-11068.patch";
- url = "https://gitlab.gnome.org/GNOME/libxslt/commit/e03553605b45c88f0b4b2980adfbbb8f6fca2fd6.patch";
- sha256 = "0pkpb4837km15zgg6h57bncp66d5lwrlvkr73h0lanywq7zrwhj8";
- })
- (fetchpatch {
- url = "https://gitlab.gnome.org/GNOME/libxslt/commit/c5eb6cf3aba0af048596106ed839b4ae17ecbcb1.patch";
- name = "CVE-2019-13117.patch";
- sha256 = "0ynfq8y5h623cypj1426iiz7796n3mqbjqa24ndvh2am6rl5lw15";
- })
- (fetchpatch {
- url = "https://gitlab.gnome.org/GNOME/libxslt/commit/6ce8de69330783977dd14f6569419489875fb71b.patch";
- name = "CVE-2019-13118.patch";
- sha256 = "0bglz9m9sh2vi50qxcm06iqrazw3h45ycgxnp15iankq95z283iq";
- })
- ];
-
outputs = [ "bin" "dev" "out" "man" "doc" ] ++ stdenv.lib.optional pythonSupport "py";
buildInputs = [ libxml2.dev ]
diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix
index caeb8dba8a6..ca73f3bdeb6 100644
--- a/pkgs/development/libraries/mesa/default.nix
+++ b/pkgs/development/libraries/mesa/default.nix
@@ -27,7 +27,7 @@
with stdenv.lib;
let
- version = "19.2.1";
+ version = "19.2.4";
branch = versions.major version;
in
@@ -42,7 +42,7 @@ stdenv.mkDerivation {
"ftp://ftp.freedesktop.org/pub/mesa/older-versions/${branch}.x/${version}/mesa-${version}.tar.xz"
"https://mesa.freedesktop.org/archive/mesa-${version}.tar.xz"
];
- sha256 = "4cc53ca1a8d12c6ff0e5ea44a5213c05c88447ab50d7e28bb350cd29199f01e9";
+ sha256 = "03z393jrd1cnh68k5h3mm5yap3hi1jzz3a417ccjxn5vgl7hl009";
};
prePatch = "patchShebangs .";
diff --git a/pkgs/development/libraries/mesa/stubs.nix b/pkgs/development/libraries/mesa/stubs.nix
index 5cb6ac3d4d1..a53f2dc28e7 100644
--- a/pkgs/development/libraries/mesa/stubs.nix
+++ b/pkgs/development/libraries/mesa/stubs.nix
@@ -51,7 +51,7 @@ stdenv.mkDerivation {
ln -s ${libglvnd.out}/lib $out/lib
mkdir -p $dev/{,lib/pkgconfig,nix-support}
- echo "$out" > $dev/nix-support/propagated-build-inputs
+ echo "$out ${libglvnd} ${libglvnd.dev}" > $dev/nix-support/propagated-build-inputs
ln -s ${mesa.dev}/include $dev/include
genPkgConfig() {
@@ -63,7 +63,7 @@ stdenv.mkDerivation {
Description: $lib library
Version: ${mesa.version}
Libs: -L${libglvnd.out}/lib -l$lib
- Cflags: -I${mesa.dev}/include
+ Cflags: -I${mesa.dev}/include -I${libglvnd.dev}/include
EOF
}
diff --git a/pkgs/development/libraries/ncurses/default.nix b/pkgs/development/libraries/ncurses/default.nix
index 708ba46b42e..540ea71abfb 100644
--- a/pkgs/development/libraries/ncurses/default.nix
+++ b/pkgs/development/libraries/ncurses/default.nix
@@ -141,6 +141,7 @@ stdenv.mkDerivation rec {
moveToOutput "bin/tset" "$out"
moveToOutput "bin/captoinfo" "$out"
moveToOutput "bin/infotocap" "$out"
+ moveToOutput "bin/infocmp" "$out"
'';
preFixup = lib.optionalString (!stdenv.hostPlatform.isCygwin && !enableStatic) ''
diff --git a/pkgs/development/libraries/openscenegraph/default.nix b/pkgs/development/libraries/openscenegraph/default.nix
index 1398e829dd5..9be5018dc29 100644
--- a/pkgs/development/libraries/openscenegraph/default.nix
+++ b/pkgs/development/libraries/openscenegraph/default.nix
@@ -1,5 +1,5 @@
{ stdenv, lib, fetchFromGitHub, cmake, pkgconfig, doxygen,
- libX11, libXinerama, libXrandr, libGLU_combined,
+ libX11, libXinerama, libXrandr, libGLU, libGL,
glib, ilmbase, libxml2, pcre, zlib,
jpegSupport ? true, libjpeg,
jasperSupport ? true, jasper,
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ pkgconfig cmake doxygen ];
buildInputs = [
- libX11 libXinerama libXrandr libGLU_combined
+ libX11 libXinerama libXrandr libGLU libGL
glib ilmbase libxml2 pcre zlib
] ++ lib.optional jpegSupport libjpeg
++ lib.optional jasperSupport jasper
diff --git a/pkgs/development/libraries/p11-kit/default.nix b/pkgs/development/libraries/p11-kit/default.nix
index 9ca329c6761..f13ae141a81 100644
--- a/pkgs/development/libraries/p11-kit/default.nix
+++ b/pkgs/development/libraries/p11-kit/default.nix
@@ -4,13 +4,13 @@
stdenv.mkDerivation rec {
pname = "p11-kit";
- version = "0.23.16.1";
+ version = "0.23.18.1";
src = fetchFromGitHub {
owner = "p11-glue";
repo = pname;
rev = version;
- sha256 = "0jr62qkbqxp3iawgksk1qc3gp8p6x09sg5v7xac80ghyfxil15wy";
+ sha256 = "0l4ndipcbikblfjz729zkscvni5lzdzvbvsar2538pylw556rx73";
};
outputs = [ "out" "dev"];
diff --git a/pkgs/development/libraries/phonon/default.nix b/pkgs/development/libraries/phonon/default.nix
index dc32c4ebfb0..dd163571a1b 100644
--- a/pkgs/development/libraries/phonon/default.nix
+++ b/pkgs/development/libraries/phonon/default.nix
@@ -6,7 +6,7 @@
with lib;
let
- v = "4.10.3";
+ v = "4.11.1";
soname = if withQt5 then "phonon4qt5" else "phonon";
buildsystemdir = "share/cmake/${soname}";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
src = fetchurl {
url = "mirror://kde/stable/phonon/${v}/phonon-${v}.tar.xz";
- sha256 = "15f2vndpqfcivifzl1s07r0wkavpfrjln1p46cwfk85gd5b192rf";
+ sha256 = "0bfy8iqmjhlg3ma3iqd3kxjc2zkzpjgashbpf5x17y0dc2i1whxl";
};
buildInputs =
diff --git a/pkgs/development/libraries/qt-5/5.12/default.nix b/pkgs/development/libraries/qt-5/5.12/default.nix
index 9b6534c01b2..0a37b1ce39a 100644
--- a/pkgs/development/libraries/qt-5/5.12/default.nix
+++ b/pkgs/development/libraries/qt-5/5.12/default.nix
@@ -54,6 +54,7 @@ let
optionals stdenv.isDarwin [
./qtbase.patch.d/0001-qtbase-mkspecs-mac.patch
./qtbase.patch.d/0002-qtbase-mac.patch
+ ./qtbase.patch.d/0013-define-kiosurfacesuccess.patch
]
++ [
./qtbase.patch.d/0003-qtbase-mkspecs.patch
diff --git a/pkgs/development/libraries/qt-5/5.12/qtbase.patch.d/0013-define-kiosurfacesuccess.patch b/pkgs/development/libraries/qt-5/5.12/qtbase.patch.d/0013-define-kiosurfacesuccess.patch
new file mode 100644
index 00000000000..a43a46d8a69
--- /dev/null
+++ b/pkgs/development/libraries/qt-5/5.12/qtbase.patch.d/0013-define-kiosurfacesuccess.patch
@@ -0,0 +1,16 @@
+diff --git a/src/plugins/platforms/cocoa/qiosurfacegraphicsbuffer.mm b/src/plugins/platforms/cocoa/qiosurfacegraphicsbuffer.mm
+index a367487e..c3aeca1d 100644
+--- a/src/plugins/platforms/cocoa/qiosurfacegraphicsbuffer.mm
++++ b/src/plugins/platforms/cocoa/qiosurfacegraphicsbuffer.mm
+@@ -49,6 +49,11 @@
+ // but was only added in the 10.14 SDK, so declare it just in case.
+ extern "C" CFPropertyListRef CGColorSpaceCopyPropertyList(CGColorSpaceRef space);
+
++// Introduced in 10.13: http://codeworkshop.net/objc-diff/sdkdiffs/macos/10.13/IOSurface.html
++#if !defined(kIOSurfaceSuccess)
++#define kIOSurfaceSuccess KERN_SUCCESS
++#endif
++
+ QT_BEGIN_NAMESPACE
+
+ Q_LOGGING_CATEGORY(lcQpaIOSurface, "qt.qpa.backingstore.iosurface");
diff --git a/pkgs/development/libraries/qt-5/hooks/qmake-hook.sh b/pkgs/development/libraries/qt-5/hooks/qmake-hook.sh
index c3373983e32..7f6ddb76ad5 100644
--- a/pkgs/development/libraries/qt-5/hooks/qmake-hook.sh
+++ b/pkgs/development/libraries/qt-5/hooks/qmake-hook.sh
@@ -1,6 +1,6 @@
. @fix_qmake_libtool@
-qmakeFlags=( $qmakeFlags )
+qmakeFlags=( ${qmakeFlags-} )
qmakePrePhase() {
qmakeFlags=( \
@@ -31,6 +31,6 @@ qmakeConfigurePhase() {
runHook postConfigure
}
-if [ -z "$dontUseQmakeConfigure" -a -z "$configurePhase" ]; then
+if [ -z "${dontUseQmakeConfigure-}" -a -z "${configurePhase-}" ]; then
configurePhase=qmakeConfigurePhase
fi
diff --git a/pkgs/development/libraries/qt-5/hooks/qtbase-setup-hook.sh b/pkgs/development/libraries/qt-5/hooks/qtbase-setup-hook.sh
index 436c2e1d032..9f2a9f06f1a 100644
--- a/pkgs/development/libraries/qt-5/hooks/qtbase-setup-hook.sh
+++ b/pkgs/development/libraries/qt-5/hooks/qtbase-setup-hook.sh
@@ -61,6 +61,6 @@ postPatchMkspecs() {
fixQtBuiltinPaths "$dev/mkspecs" '*.pr?'
fi
}
-if [ -z "$dontPatchMkspecs" ]; then
- postPhases="${postPhases}${postPhases:+ }postPatchMkspecs"
+if [ -z "${dontPatchMkspecs-}" ]; then
+ postPhases="${postPhases-}${postPhases:+ }postPatchMkspecs"
fi
diff --git a/pkgs/development/libraries/qt-5/hooks/wrap-qt-apps-hook.sh b/pkgs/development/libraries/qt-5/hooks/wrap-qt-apps-hook.sh
index d2aadbd956a..d9e5880289d 100644
--- a/pkgs/development/libraries/qt-5/hooks/wrap-qt-apps-hook.sh
+++ b/pkgs/development/libraries/qt-5/hooks/wrap-qt-apps-hook.sh
@@ -64,10 +64,10 @@ qtOwnPathsHook() {
preFixupPhases+=" qtOwnPathsHook"
-# Note: $qtWrapperArgs still gets defined even if $dontWrapQtApps is set.
+# Note: $qtWrapperArgs still gets defined even if ${dontWrapQtApps-} is set.
wrapQtAppsHook() {
# skip this hook when requested
- [ -z "$dontWrapQtApps" ] || return 0
+ [ -z "${dontWrapQtApps-}" ] || return 0
# guard against running multiple times (e.g. due to propagation)
[ -z "$wrapQtAppsHookHasRun" ] || return 0
diff --git a/pkgs/development/libraries/qt-5/modules/qtbase.nix b/pkgs/development/libraries/qt-5/modules/qtbase.nix
index d1ec209c95d..3dbdb2a9770 100644
--- a/pkgs/development/libraries/qt-5/modules/qtbase.nix
+++ b/pkgs/development/libraries/qt-5/modules/qtbase.nix
@@ -58,7 +58,7 @@ stdenv.mkDerivation {
# TODO: move to buildInputs, this should not be propagated.
AGL AppKit ApplicationServices Carbon Cocoa CoreAudio CoreBluetooth
CoreLocation CoreServices DiskArbitration Foundation OpenGL
- darwin.libobjc libiconv MetalKit
+ darwin.libobjc libiconv MetalKit IOKit
]
else
[
diff --git a/pkgs/development/libraries/vtk/default.nix b/pkgs/development/libraries/vtk/default.nix
index 3cb8998485a..482d691fc7c 100644
--- a/pkgs/development/libraries/vtk/default.nix
+++ b/pkgs/development/libraries/vtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, libGLU_combined, libX11, xorgproto, libXt, libtiff
+{ stdenv, fetchurl, cmake, libGLU, libGL, libX11, xorgproto, libXt, libtiff
, qtLib ? null
# Darwin support
, Cocoa, CoreServices, DiskArbitration, IOKit, CFNetwork, Security, GLUT, OpenGL
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
buildInputs = [ libtiff ]
++ optional (qtLib != null) qtLib
- ++ optionals stdenv.isLinux [ libGLU_combined libX11 xorgproto libXt ]
+ ++ optionals stdenv.isLinux [ libGLU libGL libX11 xorgproto libXt ]
++ optionals stdenv.isDarwin [ xpc Cocoa CoreServices DiskArbitration IOKit
CFNetwork Security ApplicationServices CoreText
IOSurface ImageIO OpenGL GLUT ];
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
# built and requiring one of the shared objects.
# At least, we use -fPIC for other packages to be able to use this in shared
# objects.
- cmakeFlags = [ "-DCMAKE_C_FLAGS=-fPIC" "-DCMAKE_CXX_FLAGS=-fPIC" "-DVTK_USE_SYSTEM_TIFF=1" ]
+ cmakeFlags = [ "-DCMAKE_C_FLAGS=-fPIC" "-DCMAKE_CXX_FLAGS=-fPIC" "-DVTK_USE_SYSTEM_TIFF=1" "-DOPENGL_INCLUDE_DIR=${libGL}/include" ]
++ optional (qtLib != null) [ "-DVTK_USE_QT:BOOL=ON" ]
++ optional stdenv.isDarwin "-DOPENGL_INCLUDE_DIR=${OpenGL}/Library/Frameworks";
diff --git a/pkgs/development/libraries/webkitgtk/default.nix b/pkgs/development/libraries/webkitgtk/default.nix
index f20d12359c9..e8fe798476c 100644
--- a/pkgs/development/libraries/webkitgtk/default.nix
+++ b/pkgs/development/libraries/webkitgtk/default.nix
@@ -2,7 +2,7 @@
, pkgconfig, gettext, gobject-introspection, libnotify, gnutls, libgcrypt
, gtk3, wayland, libwebp, enchant2, xorg, libxkbcommon, epoxy, at-spi2-core
, libxml2, libsoup, libsecret, libxslt, harfbuzz, libpthreadstubs, pcre, nettle, libtasn1, p11-kit
-, libidn, libedit, readline, libGLU_combined, libintl, openjpeg
+, libidn, libedit, readline, libGL, libGLU, libintl, openjpeg
, enableGeoLocation ? true, geoclue2, sqlite
, enableGtk2Plugins ? false, gtk2 ? null
, gst-plugins-base, gst-plugins-bad, woff2
@@ -37,6 +37,7 @@ stdenv.mkDerivation rec {
src = ./fix-bubblewrap-paths.patch;
inherit (builtins) storeDir;
})
+ ./libglvnd-headers.patch
];
postPatch = ''
@@ -74,10 +75,11 @@ stdenv.mkDerivation rec {
libintl libwebp enchant2 libnotify gnutls pcre nettle libidn libgcrypt woff2
libxml2 libsecret libxslt harfbuzz libpthreadstubs libtasn1 p11-kit openjpeg
sqlite gst-plugins-base gst-plugins-bad libxkbcommon epoxy at-spi2-core
+ libGL libGLU
] ++ optional enableGeoLocation geoclue2
++ optional enableGtk2Plugins gtk2
++ (with xorg; [ libXdmcp libXt libXtst libXdamage ])
- ++ optionals stdenv.isDarwin [ libedit readline libGLU_combined ]
+ ++ optionals stdenv.isDarwin [ libedit readline ]
++ optionals stdenv.isLinux [
wayland bubblewrap libseccomp xdg-dbus-proxy
];
diff --git a/pkgs/development/libraries/webkitgtk/libglvnd-headers.patch b/pkgs/development/libraries/webkitgtk/libglvnd-headers.patch
new file mode 100644
index 00000000000..17264f3b588
--- /dev/null
+++ b/pkgs/development/libraries/webkitgtk/libglvnd-headers.patch
@@ -0,0 +1,586 @@
+diff --git a/Source/ThirdParty/ANGLE/scripts/generate_loader.py b/Source/ThirdParty/ANGLE/scripts/generate_loader.py
+index a408dac4..92ddca90 100644
+--- a/Source/ThirdParty/ANGLE/scripts/generate_loader.py
++++ b/Source/ThirdParty/ANGLE/scripts/generate_loader.py
+@@ -201,6 +201,8 @@ def main():
+
+ libegl_preamble = """#include
+ #include
++#include
++#include
+ """
+
+ util_gles_preamble = """#if defined(GL_GLES_PROTOTYPES) && GL_GLES_PROTOTYPES
+@@ -215,6 +217,8 @@ util_egl_preamble = """#include "util/util_export.h"
+
+ #include
+ #include
++#include
++#include
+ """
+
+ util_wgl_preamble = """
+diff --git a/Source/ThirdParty/ANGLE/src/common/PackedEGLEnums_autogen.h b/Source/ThirdParty/ANGLE/src/common/PackedEGLEnums_autogen.h
+index 68c65d8b..0dc9c8e3 100644
+--- a/Source/ThirdParty/ANGLE/src/common/PackedEGLEnums_autogen.h
++++ b/Source/ThirdParty/ANGLE/src/common/PackedEGLEnums_autogen.h
+@@ -14,6 +14,7 @@
+
+ #include
+ #include
++#include
+ #include
+
+ #include
+diff --git a/Source/ThirdParty/ANGLE/src/common/PackedGLEnums_autogen.h b/Source/ThirdParty/ANGLE/src/common/PackedGLEnums_autogen.h
+index cd651150..17719bc2 100644
+--- a/Source/ThirdParty/ANGLE/src/common/PackedGLEnums_autogen.h
++++ b/Source/ThirdParty/ANGLE/src/common/PackedGLEnums_autogen.h
+@@ -14,6 +14,7 @@
+
+ #include
+ #include
++#include
+ #include
+
+ #include
+diff --git a/Source/ThirdParty/ANGLE/src/common/gen_packed_gl_enums.py b/Source/ThirdParty/ANGLE/src/common/gen_packed_gl_enums.py
+index 2f77e725..5ea54f1f 100644
+--- a/Source/ThirdParty/ANGLE/src/common/gen_packed_gl_enums.py
++++ b/Source/ThirdParty/ANGLE/src/common/gen_packed_gl_enums.py
+@@ -71,6 +71,7 @@ header_template = """// GENERATED FILE - DO NOT EDIT.
+ #include
+ #include
+ #include
++#include
+
+ #include
+
+diff --git a/Source/ThirdParty/ANGLE/src/common/utilities.h b/Source/ThirdParty/ANGLE/src/common/utilities.h
+index 7a1429a4..dd20bcca 100644
+--- a/Source/ThirdParty/ANGLE/src/common/utilities.h
++++ b/Source/ThirdParty/ANGLE/src/common/utilities.h
+@@ -11,6 +11,7 @@
+
+ #include
+ #include
++#include
+
+ #include
+ #include
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Config.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/Config.cpp
+index 4134226d..5dd1065f 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/Config.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Config.cpp
+@@ -15,6 +15,7 @@
+ #include
+
+ #include
++#include
+ #include "angle_gl.h"
+
+ #include "common/debug.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Device.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/Device.cpp
+index 13ae4e61..b964b755 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/Device.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Device.cpp
+@@ -12,6 +12,7 @@
+ #include
+
+ #include
++#include
+ #include
+
+ #include "common/debug.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp
+index 21064073..a46628bd 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Display.cpp
+@@ -17,6 +17,7 @@
+ #include
+
+ #include
++#include
+ #include
+
+ #include "common/debug.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Error.h b/Source/ThirdParty/ANGLE/src/libANGLE/Error.h
+index 37df5b0c..b2e3885b 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/Error.h
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Error.h
+@@ -11,6 +11,7 @@
+
+ #include
+ #include
++#include
+ #include "angle_gl.h"
+ #include "common/angleutils.h"
+ #include "common/debug.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Stream.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/Stream.cpp
+index b7bc84c8..538cb3e0 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/Stream.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Stream.cpp
+@@ -10,6 +10,7 @@
+ #include "libANGLE/Stream.h"
+
+ #include
++#include
+ #include
+
+ #include "common/debug.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Stream.h b/Source/ThirdParty/ANGLE/src/libANGLE/Stream.h
+index 9157aa51..d8e58f2d 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/Stream.h
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Stream.h
+@@ -14,6 +14,7 @@
+
+ #include
+ #include
++#include
+
+ #include "common/angleutils.h"
+ #include "libANGLE/AttributeMap.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/Surface.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/Surface.cpp
+index 6daec4f6..941f34ca 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/Surface.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/Surface.cpp
+@@ -11,6 +11,7 @@
+ #include "libANGLE/Surface.h"
+
+ #include
++#include
+
+ #include "libANGLE/Config.h"
+ #include "libANGLE/Context.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/SurfaceImpl.h b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/SurfaceImpl.h
+index ea1a0510..db7cf0c8 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/SurfaceImpl.h
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/SurfaceImpl.h
+@@ -11,6 +11,7 @@
+
+ #include
+ #include
++#include
+
+ #include "common/angleutils.h"
+ #include "libANGLE/Error.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DeviceD3D.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DeviceD3D.cpp
+index ba5cf532..43304da5 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DeviceD3D.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DeviceD3D.cpp
+@@ -13,6 +13,7 @@
+ #include "libANGLE/Display.h"
+
+ #include
++#include
+
+ namespace rx
+ {
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DisplayD3D.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DisplayD3D.cpp
+index de60dfff..93b5bdf8 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DisplayD3D.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/DisplayD3D.cpp
+@@ -9,6 +9,7 @@
+ #include "libANGLE/renderer/d3d/DisplayD3D.h"
+
+ #include
++#include
+
+ #include "libANGLE/Config.h"
+ #include "libANGLE/Context.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/EGLImageD3D.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/EGLImageD3D.cpp
+index a7255d0d..a7e37777 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/EGLImageD3D.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/EGLImageD3D.cpp
+@@ -20,6 +20,7 @@
+ #include "libANGLE/renderer/d3d/TextureStorage.h"
+
+ #include
++#include
+
+ namespace rx
+ {
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SurfaceD3D.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SurfaceD3D.cpp
+index 61dc8ffa..87276514 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SurfaceD3D.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SurfaceD3D.cpp
+@@ -19,6 +19,7 @@
+ #include "libANGLE/renderer/d3d/d3d11/formatutils11.h"
+
+ #include
++#include
+ #include
+ #include
+
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SwapChainD3D.h b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SwapChainD3D.h
+index 443cadd6..e64bdfc4 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SwapChainD3D.h
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/SwapChainD3D.h
+@@ -12,6 +12,7 @@
+
+ #include
+ #include
++#include
+ #include
+
+ #include "common/angleutils.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
+index 33dfa6b0..eb3393d2 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/Renderer11.cpp
+@@ -9,6 +9,7 @@
+ #include "libANGLE/renderer/d3d/d3d11/Renderer11.h"
+
+ #include
++#include
+ #include
+ #include
+
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/SwapChain11.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/SwapChain11.cpp
+index fe4def6e..2550b52c 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/SwapChain11.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d11/SwapChain11.cpp
+@@ -9,6 +9,7 @@
+ #include "libANGLE/renderer/d3d/d3d11/SwapChain11.h"
+
+ #include
++#include
+
+ #include "libANGLE/features.h"
+ #include "libANGLE/renderer/d3d/DisplayD3D.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
+index f4a4ce43..0cad5540 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/d3d/d3d9/Renderer9.cpp
+@@ -9,6 +9,7 @@
+ #include "libANGLE/renderer/d3d/d3d9/Renderer9.h"
+
+ #include
++#include
+ #include
+
+ #include "common/utilities.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/DisplayGL.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/DisplayGL.cpp
+index a89e1365..0fe4fa98 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/DisplayGL.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/DisplayGL.cpp
+@@ -18,6 +18,7 @@
+ #include "libANGLE/renderer/gl/SurfaceGL.h"
+
+ #include
++#include
+
+ namespace rx
+ {
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/RendererGL.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/RendererGL.cpp
+index 10b15594..7ae1ac6b 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/RendererGL.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/RendererGL.cpp
+@@ -9,6 +9,7 @@
+ #include "libANGLE/renderer/gl/RendererGL.h"
+
+ #include
++#include
+
+ #include "common/debug.h"
+ #include "libANGLE/AttributeMap.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/FunctionsEGL.h b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/FunctionsEGL.h
+index 115a7afb..abb200e6 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/FunctionsEGL.h
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/FunctionsEGL.h
+@@ -11,6 +11,7 @@
+
+ #include
+ #include
++#include
+
+ #include
+ #include
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/ozone/DisplayOzone.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/ozone/DisplayOzone.cpp
+index 47ed6ce0..9d11560c 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/ozone/DisplayOzone.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/egl/ozone/DisplayOzone.cpp
+@@ -14,6 +14,7 @@
+ #include
+
+ #include
++#include
+
+ #include
+ #include
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/glx/DisplayGLX.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/glx/DisplayGLX.cpp
+index 23b4a5c5..daeb5789 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/glx/DisplayGLX.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/glx/DisplayGLX.cpp
+@@ -9,6 +9,7 @@
+ #include "libANGLE/renderer/gl/glx/DisplayGLX.h"
+
+ #include
++#include
+ #include
+ #include
+ #include
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/renderergl_utils.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/renderergl_utils.cpp
+index 698b51e2..32e6126f 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/renderergl_utils.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/renderergl_utils.cpp
+@@ -27,6 +27,7 @@
+ #include "libANGLE/renderer/gl/formatutilsgl.h"
+
+ #include
++#include
+ #include
+ #include
+
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DXGISwapChainWindowSurfaceWGL.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DXGISwapChainWindowSurfaceWGL.cpp
+index 5b686321..16ae890f 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DXGISwapChainWindowSurfaceWGL.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DXGISwapChainWindowSurfaceWGL.cpp
+@@ -18,6 +18,7 @@
+ #include "libANGLE/renderer/gl/wgl/FunctionsWGL.h"
+
+ #include
++#include
+
+ namespace rx
+ {
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DisplayWGL.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DisplayWGL.cpp
+index 12679ba7..93503812 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DisplayWGL.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/gl/wgl/DisplayWGL.cpp
+@@ -28,6 +28,7 @@
+ #include "platform/Platform.h"
+
+ #include
++#include
+ #include
+ #include
+
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/RendererVk.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/RendererVk.cpp
+index df900f4d..4385be88 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/RendererVk.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/renderer/vulkan/RendererVk.cpp
+@@ -13,6 +13,7 @@
+ #include "libANGLE/renderer/vulkan/vk_utils.h"
+
+ #include
++#include
+
+ #include "common/debug.h"
+ #include "common/platform.h"
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.cpp b/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.cpp
+index 1c0b25f4..64e96f73 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.cpp
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.cpp
+@@ -22,6 +22,7 @@
+ #include "libANGLE/formatutils.h"
+
+ #include
++#include
+
+ namespace egl
+ {
+diff --git a/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.h b/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.h
+index a671bb0d..248f0ae8 100644
+--- a/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.h
++++ b/Source/ThirdParty/ANGLE/src/libANGLE/validationEGL.h
+@@ -15,6 +15,7 @@
+
+ #include
+ #include
++#include
+
+ namespace gl
+ {
+diff --git a/Source/ThirdParty/ANGLE/src/libEGL/egl_loader_autogen.h b/Source/ThirdParty/ANGLE/src/libEGL/egl_loader_autogen.h
+index ae4a427c..a802b65d 100644
+--- a/Source/ThirdParty/ANGLE/src/libEGL/egl_loader_autogen.h
++++ b/Source/ThirdParty/ANGLE/src/libEGL/egl_loader_autogen.h
+@@ -13,6 +13,7 @@
+
+ #include
+ #include
++#include
+
+ extern PFNEGLCHOOSECONFIGPROC EGL_ChooseConfig;
+ extern PFNEGLCOPYBUFFERSPROC EGL_CopyBuffers;
+diff --git a/Source/ThirdParty/ANGLE/src/libGLESv2/entry_points_egl_ext.h b/Source/ThirdParty/ANGLE/src/libGLESv2/entry_points_egl_ext.h
+index 3c64b290..96201b31 100644
+--- a/Source/ThirdParty/ANGLE/src/libGLESv2/entry_points_egl_ext.h
++++ b/Source/ThirdParty/ANGLE/src/libGLESv2/entry_points_egl_ext.h
+@@ -11,6 +11,7 @@
+
+ #include
+ #include
++#include
+ #include
+
+ extern "C" {
+diff --git a/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLENativeDisplayFactory.cpp b/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLENativeDisplayFactory.cpp
+index 777b09e1..dbb0bd2f 100644
+--- a/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLENativeDisplayFactory.cpp
++++ b/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLENativeDisplayFactory.cpp
+@@ -24,6 +24,7 @@
+
+ #include
+ #include
++#include
+
+ #include "deClock.h"
+ #include "deMemory.h"
+diff --git a/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLEPlatform.cpp b/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLEPlatform.cpp
+index 6b4a25bf..1c4ac864 100644
+--- a/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLEPlatform.cpp
++++ b/Source/ThirdParty/ANGLE/src/tests/deqp_support/tcuANGLEPlatform.cpp
+@@ -22,6 +22,7 @@
+
+ #include
+ #include
++#include
+
+ #include "egluGLContextFactory.hpp"
+ #include "tcuANGLENativeDisplayFactory.h"
+diff --git a/Source/ThirdParty/ANGLE/src/tests/egl_tests/EGLX11VisualTest.cpp b/Source/ThirdParty/ANGLE/src/tests/egl_tests/EGLX11VisualTest.cpp
+index 90abb931..aea4e153 100644
+--- a/Source/ThirdParty/ANGLE/src/tests/egl_tests/EGLX11VisualTest.cpp
++++ b/Source/ThirdParty/ANGLE/src/tests/egl_tests/EGLX11VisualTest.cpp
+@@ -10,6 +10,7 @@
+
+ #include
+ #include
++#include
+ #include
+
+ #include "test_utils/ANGLETest.h"
+diff --git a/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests.h b/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests.h
+index e888a239..71606b8c 100644
+--- a/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests.h
++++ b/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests.h
+@@ -11,6 +11,7 @@
+
+ #include
+ #include
++#include
+
+ #include
+
+diff --git a/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests_main.cpp b/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests_main.cpp
+index 7fdddcc6..e40b8905 100644
+--- a/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests_main.cpp
++++ b/Source/ThirdParty/ANGLE/src/tests/gles_conformance_tests/gles_conformance_tests_main.cpp
+@@ -10,6 +10,7 @@
+
+ #include
+ #include
++#include
+
+ #include