From 56ac9ae5da13d8276131f50e69edc32c2635fdf9 Mon Sep 17 00:00:00 2001 From: Daiderd Jordan Date: Thu, 27 Apr 2017 22:48:10 +0200 Subject: [PATCH] libplist: 1.12 -> 2.0.0 --- .../libraries/libplist/default.nix | 16 ++------ .../development/libraries/libplist/swig.patch | 37 ------------------- 2 files changed, 4 insertions(+), 49 deletions(-) delete mode 100644 pkgs/development/libraries/libplist/swig.patch diff --git a/pkgs/development/libraries/libplist/default.nix b/pkgs/development/libraries/libplist/default.nix index 7ff44db52a8b..7eb6759af984 100644 --- a/pkgs/development/libraries/libplist/default.nix +++ b/pkgs/development/libraries/libplist/default.nix @@ -3,11 +3,10 @@ let inherit (python2Packages) python cython; in stdenv.mkDerivation rec { - name = "libplist-1.12"; + name = "libplist-${version}"; + version = "2.0.0"; - nativeBuildInputs = [ pkgconfig swig2 python cython ]; - - #patches = [ ./swig.patch ]; + nativeBuildInputs = [ pkgconfig swig2 python cython ]; propagatedBuildInputs = [ libxml2 glib ]; @@ -21,19 +20,12 @@ in stdenv.mkDerivation rec { src = fetchurl { url = "http://www.libimobiledevice.org/downloads/${name}.tar.bz2"; - sha256 = "1gj4nv0bvdm5y2sqm2vj2rn44k67ahw3mh6q614qq4nyngfdxzqf"; + sha256 = "00pnh9zf3iwdji2faccns7vagbmbrwbj9a8zp9s53a6rqaa9czis"; }; meta = { homepage = http://github.com/JonathanBeck/libplist; platforms = stdenv.lib.platforms.all; maintainers = [ ]; - knownVulnerabilities = [ - "CVE-2017-5209: base64decode function in base64.c allows attackers to obtain sensitive information from process memory or cause a denial of service" - "CVE-2017-5545: attackers to obtain sensitive information from process memory or cause a denial of service" - "CVE-2017-5834: A heap-buffer overflow in parse_dict_node" - "CVE-2017-5835: A memory allocation error leading to DoS" - "CVE-2017-5836: A type inconsistency in bplist.c" - ]; }; } diff --git a/pkgs/development/libraries/libplist/swig.patch b/pkgs/development/libraries/libplist/swig.patch deleted file mode 100644 index 9686a7cbf515..000000000000 --- a/pkgs/development/libraries/libplist/swig.patch +++ /dev/null @@ -1,37 +0,0 @@ -commit ca6096bc29873d5a3c03d782b134253ac2e61beb -Author: Yury G. Kudryashov -Date: Fri Sep 24 17:16:40 2010 +0400 - - Install python bindings to libplist prefix, not to system directory. - - This allows one to install libplist to $HOME/prefix and adjust - PYTHONPATH. - -diff --git a/swig/CMakeLists.txt b/swig/CMakeLists.txt -index 379cb95..fcacde0 100644 ---- a/swig/CMakeLists.txt -+++ b/swig/CMakeLists.txt -@@ -9,16 +9,18 @@ SWIG_ADD_MODULE( plist python plist.i ) - SWIG_LINK_LIBRARIES( plist plist plist++ ${PYTHON_LIBRARIES} ) - - EXEC_PROGRAM("${PYTHON_EXECUTABLE}" -- ARGS "-c 'try:\n import distutils.sysconfig; print distutils.sysconfig.get_python_lib(plat_specific=1)\nexcept: pass\n'" -- OUTPUT_VARIABLE DISTUTILS_PYTHON_ILIBRARY_PATH -+ ARGS "-c 'import sys; print sys.version[:3];'" -+ OUTPUT_VARIABLE PYTHON_SHORT_VERSION - ) - -+SET(PYTHON_SITE_PACKAGES_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR}/python${PYTHON_SHORT_VERSION}/site-packages CACHE PATH "The directory where python modules will be installed to.") -+ - INSTALL( FILES ${CMAKE_CURRENT_BINARY_DIR}/_plist${CMAKE_SHARED_MODULE_SUFFIX} -- DESTINATION ${DISTUTILS_PYTHON_ILIBRARY_PATH}/plist/ ) -+ DESTINATION ${PYTHON_SITE_PACKAGES_INSTALL_DIR}/plist/ ) - INSTALL( FILES ${CMAKE_CURRENT_BINARY_DIR}/plist.py -- DESTINATION ${DISTUTILS_PYTHON_ILIBRARY_PATH}/plist/ ) -+ DESTINATION ${PYTHON_SITE_PACKAGES_INSTALL_DIR}/plist/ ) - INSTALL( FILES ${CMAKE_CURRENT_SOURCE_DIR}/__init__.py -- DESTINATION ${DISTUTILS_PYTHON_ILIBRARY_PATH}/plist/ ) -+ DESTINATION ${PYTHON_SITE_PACKAGES_INSTALL_DIR}/plist/ ) - INSTALL( FILES ${CMAKE_CURRENT_SOURCE_DIR}/plist.i - DESTINATION include/plist/swig COMPONENT dev) -