From 27830c70b1e2a5bfb7d95313807e396fc2c1a6ac Mon Sep 17 00:00:00 2001 From: fricklerhandwerk Date: Thu, 14 Jan 2021 09:25:06 +0100 Subject: [PATCH 1/3] wxmac: 3.0.4 -> 3.0.5.1 --- pkgs/development/libraries/wxwidgets/3.0/mac.nix | 6 +++--- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/development/libraries/wxwidgets/3.0/mac.nix b/pkgs/development/libraries/wxwidgets/3.0/mac.nix index 1b4c67024515..a6973f53de8f 100644 --- a/pkgs/development/libraries/wxwidgets/3.0/mac.nix +++ b/pkgs/development/libraries/wxwidgets/3.0/mac.nix @@ -1,11 +1,11 @@ { stdenv, fetchzip, expat, libiconv, libjpeg, libpng, libtiff, zlib # darwin only attributes , derez, rez, setfile -, AGL, Cocoa, Kernel +, AGL, Cocoa, Kernel, WebKit }: stdenv.mkDerivation rec { - version = "3.0.4"; + version = "3.0.5.1"; pname = "wxmac"; src = fetchzip { @@ -16,7 +16,7 @@ stdenv.mkDerivation rec { buildInputs = [ expat libiconv libjpeg libpng libtiff zlib derez rez setfile - AGL Cocoa Kernel + AGL Cocoa Kernel WebKit ]; postPatch = '' diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c565f77f3dde..c0aab40bbd6b 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -16883,7 +16883,7 @@ in }; wxmac = callPackage ../development/libraries/wxwidgets/3.0/mac.nix { - inherit (darwin.apple_sdk.frameworks) AGL Cocoa Kernel; + inherit (darwin.apple_sdk.frameworks) AGL Cocoa Kernel WebKit; inherit (darwin.stubs) setfile rez derez; }; From a0c29488618fbffaab5779e49551ce9c279fcb9e Mon Sep 17 00:00:00 2001 From: fricklerhandwerk Date: Thu, 14 Jan 2021 09:25:45 +0100 Subject: [PATCH 2/3] python3Packages.wxpython_4_0: fix darwin build --- .../python-modules/wxPython/4.0.nix | 24 +++++++++++++++---- pkgs/top-level/python-packages.nix | 1 + 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/wxPython/4.0.nix b/pkgs/development/python-modules/wxPython/4.0.nix index 406493362c46..a1cee317e345 100644 --- a/pkgs/development/python-modules/wxPython/4.0.nix +++ b/pkgs/development/python-modules/wxPython/4.0.nix @@ -9,10 +9,18 @@ , python , doxygen , ncurses -, wxGTK +, libintl , numpy , pillow , six +, wxGTK +, wxmac +, IOKit +, Carbon +, Cocoa +, AudioToolbox +, OpenGL +, CoreFoundation }: buildPythonPackage rec { @@ -26,8 +34,16 @@ buildPythonPackage rec { doCheck = false; - nativeBuildInputs = [ pkgconfig which doxygen wxGTK ]; - buildInputs = [ ncurses wxGTK.gtk ]; + nativeBuildInputs = [ pkgconfig which doxygen ] + ++ (if stdenv.isDarwin then [ wxmac ] else [ wxGTK ]); + + buildInputs = [ ncurses libintl ] + ++ (if stdenv.isDarwin + then + [ AudioToolbox Carbon Cocoa CoreFoundation IOKit OpenGL ] + else + [ wxGTK.gtk ] + ); DOXYGEN = "${doxygen}/bin/doxygen"; @@ -50,7 +66,7 @@ buildPythonPackage rec { ${python.interpreter} setup.py install --skip-build --prefix=$out ''; - passthru = { inherit wxGTK; }; + passthru = { wxWidgets = if stdenv.isDarwin then wxmac else wxGTK; }; meta = { diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 4fc535f60f4f..e6fdcace9517 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -8121,6 +8121,7 @@ in { wxPython_4_0 = callPackage ../development/python-modules/wxPython/4.0.nix { inherit (pkgs) pkgconfig; + inherit (pkgs.darwin.apple_sdk.frameworks) AudioToolbox Carbon Cocoa CoreFoundation IOKit OpenGL; wxGTK = pkgs.wxGTK30.override { withGtk2 = false; withWebKit = true; From bb2879d59391b8b2814ef1a8d165d5d65726e6ea Mon Sep 17 00:00:00 2001 From: fricklerhandwerk Date: Thu, 14 Jan 2021 09:24:21 +0100 Subject: [PATCH 3/3] mavproxy: fix darwin build --- .../science/robotics/mavproxy/default.nix | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/science/robotics/mavproxy/default.nix b/pkgs/applications/science/robotics/mavproxy/default.nix index 8e7c5bddd961..22a32f89bded 100644 --- a/pkgs/applications/science/robotics/mavproxy/default.nix +++ b/pkgs/applications/science/robotics/mavproxy/default.nix @@ -1,5 +1,5 @@ -{ lib, buildPythonApplication, fetchPypi, matplotlib, numpy, pymavlink, pyserial -, setuptools, wxPython_4_0 }: +{ stdenv, lib, buildPythonApplication, fetchPypi, matplotlib, numpy, pymavlink, pyserial +, setuptools, wxPython_4_0, billiard, gnureadline }: buildPythonApplication rec { pname = "MAVProxy"; @@ -10,6 +10,11 @@ buildPythonApplication rec { sha256 = "fe046481b793b592334749249620fce8a463f4c46b394ff744645975465d677b"; }; + postPatch = '' + substituteInPlace setup.py \ + --replace "opencv-python" "" + ''; + propagatedBuildInputs = [ matplotlib numpy @@ -17,7 +22,7 @@ buildPythonApplication rec { pyserial setuptools wxPython_4_0 - ]; + ] ++ lib.optionals stdenv.isDarwin [ billiard gnureadline ]; # No tests doCheck = false;