diff --git a/default.nix b/default.nix --- a/default.nix +++ b/default.nix @@ -16,11 +16,19 @@ let pkgs = pkgs_.overridePackages (self: super: { # Override subversion derivation to # - activate python bindings - subversion = super.subversion.override { - httpSupport = true; - pythonBindings = true; - python = self.python27Packages.python; - }; + subversion = let + subversionWithPython = super.subversion.override { + httpSupport = true; + pythonBindings = true; + python = self.python27Packages.python; + }; + in pkgs.lib.overrideDerivation subversionWithPython (oldAttrs: { + patches = oldAttrs.patches ++ + pkgs.lib.optionals pkgs.stdenv.isDarwin [ + # johbo: "import svn.client" fails on darwin currently. + ./pkgs/subversion-1.9.4-darwin.patch + ]; + }); }); inherit (pkgs.lib) fix extends; diff --git a/pkgs/subversion-1.9.4-darwin.patch b/pkgs/subversion-1.9.4-darwin.patch new file mode 100644 --- /dev/null +++ b/pkgs/subversion-1.9.4-darwin.patch @@ -0,0 +1,63 @@ +diff -rup subversion-1.9.4-orig/subversion/include/svn_auth.h subversion-1.9.4/subversion/include/svn_auth.h +--- subversion-1.9.4-orig/subversion/include/svn_auth.h 2015-02-13 12:17:40.000000000 +0100 ++++ subversion-1.9.4/subversion/include/svn_auth.h 2016-09-21 12:55:27.000000000 +0200 +@@ -943,7 +943,7 @@ svn_auth_get_windows_ssl_server_trust_pr + + #endif /* WIN32 && !__MINGW32__ || DOXYGEN */ + +-#if defined(DARWIN) || defined(DOXYGEN) ++#if defined(SVN_HAVE_KEYCHAIN_SERVICES) || defined(DOXYGEN) + /** + * Set @a *provider to an authentication provider of type @c + * svn_auth_cred_simple_t that gets/sets information from the user's +@@ -984,7 +984,7 @@ void + svn_auth_get_keychain_ssl_client_cert_pw_provider( + svn_auth_provider_object_t **provider, + apr_pool_t *pool); +-#endif /* DARWIN || DOXYGEN */ ++#endif /* SVN_HAVE_KEYCHAIN_SERVICES || DOXYGEN */ + + /* Note that the gnome keyring unlock prompt related items below must be + * declared for all platforms in order to allow SWIG interfaces to be +diff -rup subversion-1.9.4-orig/subversion/libsvn_subr/auth.h subversion-1.9.4/subversion/libsvn_subr/auth.h +--- subversion-1.9.4-orig/subversion/libsvn_subr/auth.h 2015-08-27 06:00:31.000000000 +0200 ++++ subversion-1.9.4/subversion/libsvn_subr/auth.h 2016-09-21 12:56:20.000000000 +0200 +@@ -103,7 +103,7 @@ svn_auth__get_windows_ssl_server_trust_p + apr_pool_t *pool); + #endif /* WIN32 && !__MINGW32__ || DOXYGEN */ + +-#if defined(DARWIN) || defined(DOXYGEN) ++#if defined(SVN_HAVE_KEYCHAIN_SERVICES) || defined(DOXYGEN) + /** + * Set @a *provider to an authentication provider of type @c + * svn_auth_cred_simple_t that gets/sets information from the user's +@@ -134,7 +134,7 @@ void + svn_auth__get_keychain_ssl_client_cert_pw_provider( + svn_auth_provider_object_t **provider, + apr_pool_t *pool); +-#endif /* DARWIN || DOXYGEN */ ++#endif /* SVN_HAVE_KEYCHAIN_SERVICES || DOXYGEN */ + + #if !defined(WIN32) || defined(DOXYGEN) + /** +diff -rup subversion-1.9.4-orig/subversion/libsvn_subr/deprecated.c subversion-1.9.4/subversion/libsvn_subr/deprecated.c +--- subversion-1.9.4-orig/subversion/libsvn_subr/deprecated.c 2015-08-27 06:00:31.000000000 +0200 ++++ subversion-1.9.4/subversion/libsvn_subr/deprecated.c 2016-09-21 12:57:08.000000000 +0200 +@@ -1479,7 +1479,7 @@ svn_auth_get_windows_ssl_server_trust_pr + #endif /* WIN32 && !__MINGW32__ */ + + /*** From macos_keychain.c ***/ +-#if defined(DARWIN) ++#if defined(SVN_HAVE_KEYCHAIN_SERVICES) + void + svn_auth_get_keychain_simple_provider(svn_auth_provider_object_t **provider, + apr_pool_t *pool) +@@ -1494,7 +1494,7 @@ svn_auth_get_keychain_ssl_client_cert_pw + { + svn_auth__get_keychain_ssl_client_cert_pw_provider(provider, pool); + } +-#endif /* DARWIN */ ++#endif /* SVN_HAVE_KEYCHAIN_SERVICES */ + + #if !defined(WIN32) + void