diff options
Diffstat (limited to 'pkgs/development')
13 files changed, 146 insertions, 48 deletions
diff --git a/pkgs/development/compilers/llvm/15/libcxx/default.nix b/pkgs/development/compilers/llvm/15/libcxx/default.nix index cc4e9bc83058..ed5f48e8c38f 100644 --- a/pkgs/development/compilers/llvm/15/libcxx/default.nix +++ b/pkgs/development/compilers/llvm/15/libcxx/default.nix @@ -1,5 +1,5 @@ { lib, stdenv, llvm_meta -, monorepoSrc, runCommand +, monorepoSrc, runCommand, fetchpatch , cmake, ninja, python3, fixDarwinDylibNames, version , cxxabi ? if stdenv.hostPlatform.isFreeBSD then libcxxrt else libcxxabi , libcxxabi, libcxxrt, libunwind @@ -47,6 +47,15 @@ stdenv.mkDerivation rec { patches = [ ./gnu-install-dirs.patch + # See: + # - https://reviews.llvm.org/D133566 + # - https://github.com/NixOS/nixpkgs/issues/214524#issuecomment-1429146432 + # !!! Drop in LLVM 16+ + (fetchpatch { + url = "https://github.com/llvm/llvm-project/commit/57c7bb3ec89565c68f858d316504668f9d214d59.patch"; + hash = "sha256-AaM9A6tQ4YAw7uDqCIV4VaiUyLZv+unwcOqbakwW9/k="; + relative = "libcxx"; + }) ] ++ lib.optionals stdenv.hostPlatform.isMusl [ ../../libcxx-0001-musl-hacks.patch ]; diff --git a/pkgs/development/interpreters/python/cpython/default.nix b/pkgs/development/interpreters/python/cpython/default.nix index 07fdb03a72be..6778dc460e05 100644 --- a/pkgs/development/interpreters/python/cpython/default.nix +++ b/pkgs/development/interpreters/python/cpython/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchurl, fetchpatch +{ lib, stdenv, fetchurl, fetchpatch, fetchgit , bzip2 , expat , libffi @@ -18,6 +18,7 @@ , self , configd , darwin +, windows , autoreconfHook , autoconf-archive , pkg-config @@ -44,6 +45,9 @@ , static ? stdenv.hostPlatform.isStatic , enableFramework ? false , enableOptimizations ? false +# these dont build for windows +, withGdbm ? !stdenv.hostPlatform.isWindows +, withReadline ? !stdenv.hostPlatform.isWindows # enableNoSemanticInterposition is a subset of the enableOptimizations flag that doesn't harm reproducibility. # clang starts supporting `-fno-sematic-interposition` with version 10 , enableNoSemanticInterposition ? (!stdenv.cc.isClang || (stdenv.cc.isClang && lib.versionAtLeast stdenv.cc.version "10")) @@ -128,12 +132,17 @@ let ]; buildInputs = filter (p: p != null) ([ - zlib bzip2 expat xz libffi libxcrypt gdbm sqlite readline ncurses openssl' ] + zlib bzip2 expat xz libffi libxcrypt ] + ++ optional withGdbm gdbm + ++ [ sqlite ] + ++ optional withReadline readline + ++ [ ncurses openssl' ] ++ optionals x11Support [ tcl tk libX11 xorgproto ] ++ optionals (bluezSupport && stdenv.isLinux) [ bluez ] ++ optionals stdenv.isDarwin [ configd ]) ++ optionals enableFramework [ Cocoa ] + ++ optionals stdenv.hostPlatform.isMinGW [ windows.mingw_w64_pthreads windows.dlfcn ] ++ optionals tzdataSupport [ tzdata ]; # `zoneinfo` module hasDistutilsCxxPatch = !(stdenv.cc.isGNU or false); @@ -160,6 +169,8 @@ let # are not documented, and must be derived from the configure script (see links # below). sysconfigdataHook = with stdenv.hostPlatform; with passthru; let + machdep = if isWindows then "win32" else parsed.kernel.name; # win32 is added by Fedora’s patch + # https://github.com/python/cpython/blob/e488e300f5c01289c10906c2e53a8e43d6de32d8/configure.ac#L428 # The configure script uses "arm" as the CPU name for all 32-bit ARM # variants when cross-compiling, but native builds include the version @@ -176,7 +187,7 @@ let powerpc64 = "ppc64"; powerpc64le = "ppc64le"; }.${parsed.cpu.name} or parsed.cpu.name; - in "${parsed.kernel.name}-${cpu}"; + in "${machdep}-${cpu}"; # https://github.com/python/cpython/blob/e488e300f5c01289c10906c2e53a8e43d6de32d8/configure.ac#L724 multiarchCpu = @@ -205,12 +216,13 @@ let else "gnu"; multiarch = if isDarwin then "darwin" - else "${multiarchCpu}-${parsed.kernel.name}-${pythonAbiName}"; + else if isWindows then "" + else "${multiarchCpu}-${machdep}-${pythonAbiName}"; abiFlags = optionalString isPy37 "m"; # https://github.com/python/cpython/blob/e488e300f5c01289c10906c2e53a8e43d6de32d8/configure.ac#L78 - pythonSysconfigdataName = "_sysconfigdata_${abiFlags}_${parsed.kernel.name}_${multiarch}"; + pythonSysconfigdataName = "_sysconfigdata_${abiFlags}_${machdep}_${multiarch}"; in '' sysconfigdataHook() { if [ "$1" = '${placeholder "out"}' ]; then @@ -222,12 +234,13 @@ let addEnvHooks "$hostOffset" sysconfigdataHook ''; + execSuffix = stdenv.hostPlatform.extensions.executable; in with passthru; stdenv.mkDerivation { pname = "python3"; inherit src version; inherit nativeBuildInputs; - buildInputs = [ bash ] ++ buildInputs; # bash is only for patchShebangs + buildInputs = lib.optionals (!stdenv.hostPlatform.isWindows) [ bash ] ++ buildInputs; # bash is only used for patchShebangs prePatch = optionalString stdenv.isDarwin '' @@ -295,9 +308,19 @@ in with passthru; stdenv.mkDerivation { ] ++ optionals stdenv.hostPlatform.isLoongArch64 [ # https://github.com/python/cpython/issues/90656 ./loongarch-support.patch - ]; + ] ++ optionals (stdenv.hostPlatform.isMinGW) (let + # https://src.fedoraproject.org/rpms/mingw-python3 + mingw-patch = fetchgit { + name = "mingw-python-patches"; + url = "https://src.fedoraproject.org/rpms/mingw-python3.git"; + rev = "45c45833ab9e5480ad0ae00778a05ebf35812ed4"; # for python 3.11.5 at the time of writing. + sha256 = "sha256-KIyNvO6MlYTrmSy9V/DbzXm5OsIuyT/BEpuo7Umm9DI="; + }; + in [ + "${mingw-patch}/*.patch" + ]); - postPatch = '' + postPatch = optionalString (!stdenv.hostPlatform.isWindows) '' substituteInPlace Lib/subprocess.py \ --replace "'/bin/sh'" "'${bash}/bin/sh'" '' + optionalString mimetypesSupport '' @@ -360,8 +383,9 @@ in with passthru; stdenv.mkDerivation { "ac_cv_have_long_long_format=yes" "ac_cv_have_size_t_format=yes" "ac_cv_computed_gotos=yes" - "ac_cv_file__dev_ptmx=yes" - "ac_cv_file__dev_ptc=yes" + # Both fail when building for windows, normally configure checks this by itself but on other platforms this is set to yes always. + "ac_cv_file__dev_ptmx=${if stdenv.hostPlatform.isWindows then "no" else "yes"}" + "ac_cv_file__dev_ptc=${if stdenv.hostPlatform.isWindows then "no" else "yes"}" ] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform && pythonAtLeast "3.11") [ "--with-build-python=${pythonForBuildInterpreter}" ] ++ optionals stdenv.hostPlatform.isLinux [ @@ -370,7 +394,8 @@ in with passthru; stdenv.mkDerivation { "ac_cv_func_lchmod=no" ] ++ optionals tzdataSupport [ "--with-tzpath=${tzdata}/share/zoneinfo" - ] ++ optional static "LDFLAGS=-static"; + ] ++ optional static "LDFLAGS=-static" + ++ optional (execSuffix != "") "--with-suffix=${execSuffix}"; preConfigure = optionalString (pythonOlder "3.12") '' for i in /usr /sw /opt /pkg; do # improve purity @@ -436,7 +461,7 @@ in with passthru; stdenv.mkDerivation { # Use Python3 as default python ln -s "$out/bin/idle3" "$out/bin/idle" ln -s "$out/bin/pydoc3" "$out/bin/pydoc" - ln -s "$out/bin/python3" "$out/bin/python" + ln -s "$out/bin/python3${execSuffix}" "$out/bin/python${execSuffix}" ln -s "$out/bin/python3-config" "$out/bin/python-config" ln -s "$out/lib/pkgconfig/python3.pc" "$out/lib/pkgconfig/python.pc" ln -sL "$out/share/man/man1/python3.1.gz" "$out/share/man/man1/python.1.gz" @@ -505,6 +530,14 @@ in with passthru; stdenv.mkDerivation { To use Python with Nix and nixpkgs, have a look at the online documentation: <https://nixos.org/manual/nixpkgs/stable/#python>. EXTERNALLY_MANAGED + '' + optionalString stdenv.hostPlatform.isWindows '' + # Shebang files that link against the build python. Shebang don’t work on windows + rm $out/bin/2to3* + rm $out/bin/idle* + rm $out/bin/pydoc* + + echo linking DLLs for python’s compiled librairies + linkDLLsInfolder $out/lib/python*/lib-dynload/ ''; preFixup = lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) '' @@ -574,7 +607,7 @@ in with passthru; stdenv.mkDerivation { high level dynamic data types. ''; license = licenses.psfl; - platforms = platforms.linux ++ platforms.darwin; + platforms = platforms.linux ++ platforms.darwin ++ platforms.windows; maintainers = with maintainers; [ fridh ]; mainProgram = executable; }; diff --git a/pkgs/development/libraries/libdeltachat/Cargo.lock b/pkgs/development/libraries/libdeltachat/Cargo.lock index 1f09a5f93eda..1e9b02504bd6 100644 --- a/pkgs/development/libraries/libdeltachat/Cargo.lock +++ b/pkgs/development/libraries/libdeltachat/Cargo.lock @@ -1103,7 +1103,7 @@ dependencies = [ [[package]] name = "deltachat" -version = "1.120.0" +version = "1.121.0" dependencies = [ "ansi_term", "anyhow", @@ -1179,7 +1179,7 @@ dependencies = [ [[package]] name = "deltachat-jsonrpc" -version = "1.120.0" +version = "1.121.0" dependencies = [ "anyhow", "async-channel", @@ -1203,7 +1203,7 @@ dependencies = [ [[package]] name = "deltachat-repl" -version = "1.120.0" +version = "1.121.0" dependencies = [ "ansi_term", "anyhow", @@ -1218,7 +1218,7 @@ dependencies = [ [[package]] name = "deltachat-rpc-server" -version = "1.120.0" +version = "1.121.0" dependencies = [ "anyhow", "deltachat", @@ -1243,7 +1243,7 @@ dependencies = [ [[package]] name = "deltachat_ffi" -version = "1.120.0" +version = "1.121.0" dependencies = [ "anyhow", "deltachat", diff --git a/pkgs/development/libraries/libdeltachat/default.nix b/pkgs/development/libraries/libdeltachat/default.nix index f99e76416da8..395764d955ec 100644 --- a/pkgs/development/libraries/libdeltachat/default.nix +++ b/pkgs/development/libraries/libdeltachat/default.nix @@ -19,13 +19,13 @@ stdenv.mkDerivation rec { pname = "libdeltachat"; - version = "1.120.0"; + version = "1.121.0"; src = fetchFromGitHub { owner = "deltachat"; repo = "deltachat-core-rust"; rev = "v${version}"; - hash = "sha256-q2Va0NbWwte8wZQWhXiORlYGoFDvuWmQShSRtlwbA6Y="; + hash = "sha256-QefBchXitDcbn1o7jgmvWdacLT8OP+W/dL32+pYsaEA="; }; patches = [ diff --git a/pkgs/development/python-modules/bellows/default.nix b/pkgs/development/python-modules/bellows/default.nix index 354b4a1f7248..effdf9d010f8 100644 --- a/pkgs/development/python-modules/bellows/default.nix +++ b/pkgs/development/python-modules/bellows/default.nix @@ -15,7 +15,7 @@ buildPythonPackage rec { pname = "bellows"; - version = "0.36.2"; + version = "0.36.3"; format = "setuptools"; disabled = pythonOlder "3.8"; @@ -24,7 +24,7 @@ buildPythonPackage rec { owner = "zigpy"; repo = "bellows"; rev = "refs/tags/${version}"; - hash = "sha256-UmyKX9vgIcOwJGNPadXwbwry6oJ56SPpDQnQHlqCLag="; + hash = "sha256-5s2I24gvHRXHm7ZTNZxc6ge9Kbe6UObcY29SvbIUWJg="; }; propagatedBuildInputs = [ diff --git a/pkgs/development/python-modules/djangorestframework-stubs/default.nix b/pkgs/development/python-modules/djangorestframework-stubs/default.nix new file mode 100644 index 000000000000..1d1d76ed3b68 --- /dev/null +++ b/pkgs/development/python-modules/djangorestframework-stubs/default.nix @@ -0,0 +1,54 @@ +{ lib +, buildPythonPackage +, django-stubs +, fetchFromGitHub +, mypy +, py +, pytest-mypy-plugins +, pytestCheckHook +, pythonOlder +, requests +, types-pyyaml +, types-requests +, typing-extensions +}: + +buildPythonPackage rec { + pname = "djangorestframework-stubs"; + version = "3.14.2"; + format = "setuptools"; + + disabled = pythonOlder "3.8"; + + src = fetchFromGitHub { + owner = "typeddjango"; + repo = "djangorestframework-stubs"; + rev = version; + hash = "sha256-T357ocJvDC+vt0I4VyAu0Q9YzY9cSK7shgp9fQ1qHyY="; + }; + + propagatedBuildInputs = [ + django-stubs + mypy + requests + types-pyyaml + types-requests + typing-extensions + ]; + + nativeCheckInputs = [ + mypy + py + pytest-mypy-plugins + pytestCheckHook + ]; + + meta = with lib; { + description = "PEP-484 stubs for Django REST Framework"; + homepage = "https://github.com/typeddjango/djangorestframework-stubs"; + changelog = "https://github.com/typeddjango/djangorestframework-stubs/releases/tag/${version}"; + license = licenses.mit; + maintainers = with maintainers; [ elohmeier ]; + }; +} + diff --git a/pkgs/development/python-modules/gspread/default.nix b/pkgs/development/python-modules/gspread/default.nix index 8201681996e1..fd01e1b1d815 100644 --- a/pkgs/development/python-modules/gspread/default.nix +++ b/pkgs/development/python-modules/gspread/default.nix @@ -12,7 +12,7 @@ buildPythonPackage rec { pname = "gspread"; - version = "5.11.0"; + version = "5.11.1"; format = "pyproject"; disabled = pythonOlder "3.7"; @@ -21,7 +21,7 @@ buildPythonPackage rec { owner = "burnash"; repo = "gspread"; rev = "refs/tags/v${version}"; - hash = "sha256-FgAdsHj6Iv08cl5GwdKyGgjVN3pylZUu/plRq/DxVbE="; + hash = "sha256-a8A47il9NrMdHkSX4YmQj4VIAYDXK5V+FUdwv+LGIfQ="; }; nativeBuildInputs = [ diff --git a/pkgs/development/python-modules/huggingface-hub/default.nix b/pkgs/development/python-modules/huggingface-hub/default.nix index 2f0374644d40..9fc7e657468d 100644 --- a/pkgs/development/python-modules/huggingface-hub/default.nix +++ b/pkgs/development/python-modules/huggingface-hub/default.nix @@ -4,7 +4,6 @@ , pythonOlder , filelock , fsspec -, importlib-metadata , packaging , pyyaml , requests @@ -14,16 +13,16 @@ buildPythonPackage rec { pname = "huggingface-hub"; - version = "0.15.1"; + version = "0.16.4"; format = "setuptools"; - disabled = pythonOlder "3.7"; + disabled = pythonOlder "3.8"; src = fetchFromGitHub { owner = "huggingface"; repo = "huggingface_hub"; rev = "refs/tags/v${version}"; - hash = "sha256-q30/oNP1NjyxiJuSfxyjFgciydImMUgPdGJ/tqVtwZk="; + hash = "sha256-fWvEvYiaLiVGmDdfibIHJAsu7nUX+eaE0QGolS3LHO8="; }; propagatedBuildInputs = [ @@ -34,8 +33,6 @@ buildPythonPackage rec { requests tqdm typing-extensions - ] ++ lib.optionals (pythonOlder "3.8") [ - importlib-metadata ]; # Tests require network access. @@ -45,7 +42,7 @@ buildPythonPackage rec { "huggingface_hub" ]; - meta = with lib; { + meta = with lib; { description = "Download and publish models and other files on the huggingface.co hub"; homepage = "https://github.com/huggingface/huggingface_hub"; changelog = "https://github.com/huggingface/huggingface_hub/releases/tag/v${version}"; diff --git a/pkgs/development/python-modules/pyvista/default.nix b/pkgs/development/python-modules/pyvista/default.nix index 252c3c87e606..4d40a650506c 100644 --- a/pkgs/development/python-modules/pyvista/default.nix +++ b/pkgs/development/python-modules/pyvista/default.nix @@ -12,14 +12,14 @@ buildPythonPackage rec { pname = "pyvista"; - version = "0.42.0"; + version = "0.42.1"; format = "setuptools"; src = fetchFromGitHub { owner = pname; repo = pname; rev = "v${version}"; - hash = "sha256-ujuDH+GK9Q6V8r/PgU5Lu3P7cmau/n7Rk/8a+v7/JRo="; + hash = "sha256-Bk2bw6WCLzMb3nLMCS9rRugNocA9eYju/aoE68TYu5c="; }; propagatedBuildInputs = [ diff --git a/pkgs/development/python-modules/seatconnect/default.nix b/pkgs/development/python-modules/seatconnect/default.nix index 7f5fb4718ff9..782a1d43ec5a 100644 --- a/pkgs/development/python-modules/seatconnect/default.nix +++ b/pkgs/development/python-modules/seatconnect/default.nix @@ -13,7 +13,7 @@ buildPythonPackage rec { pname = "seatconnect"; - version = "1.1.7"; + version = "1.1.9"; format = "setuptools"; disabled = pythonOlder "3.8"; @@ -21,8 +21,8 @@ buildPythonPackage rec { src = fetchFromGitHub { owner = "farfar"; repo = pname; - rev = version; - hash = "sha256-8QZtivHG+tf7S2hVlFaQ7yCeCCI7ft/EIr0D73mcURw="; + rev = "refs/tags/${version}"; + hash = "sha256-HITVrI0o94a61gy/TYSGFtLBYX4Rw/dK1o2/KsvHLTQ="; }; SETUPTOOLS_SCM_PRETEND_VERSION = version; diff --git a/pkgs/development/python-modules/ypy-websocket/default.nix b/pkgs/development/python-modules/ypy-websocket/default.nix index 796118abc25c..fb7a18c325bc 100644 --- a/pkgs/development/python-modules/ypy-websocket/default.nix +++ b/pkgs/development/python-modules/ypy-websocket/default.nix @@ -15,7 +15,7 @@ buildPythonPackage rec { pname = "ypy-websocket"; - version = "0.12.1"; + version = "0.12.2"; format = "pyproject"; disabled = pythonOlder "3.7"; @@ -24,7 +24,7 @@ buildPythonPackage rec { owner = "y-crdt"; repo = "ypy-websocket"; rev = "refs/tags/v${version}"; - hash = "sha256-JsSOh7CSHUnGJmNAP87fMMsRgdj6nNna1XVe15MYqoA="; + hash = "sha256-3ANuIwRxUoFo5SSdTvBhTHExrYR7timu7XkE0t+UyWk="; }; pythonRelaxDeps = [ diff --git a/pkgs/development/tools/pyenv/default.nix b/pkgs/development/tools/pyenv/default.nix index a60ca4eda3f3..4ccb71973cb1 100644 --- a/pkgs/development/tools/pyenv/default.nix +++ b/pkgs/development/tools/pyenv/default.nix @@ -6,13 +6,13 @@ stdenv.mkDerivation rec { pname = "pyenv"; - version = "2.3.25"; + version = "2.3.26"; src = fetchFromGitHub { owner = "pyenv"; repo = "pyenv"; rev = "refs/tags/v${version}"; - hash = "sha256-804bLieYrfwzUrKSvZtC6Td4+fFPw1WrhV1NE4n49Rw="; + hash = "sha256-3pLH8/k+9T8lDBw/qd9WcYE4o3SwG/WXGWR0sLGUWLE="; }; postPatch = '' diff --git a/pkgs/development/tools/rust/sqlx-cli/default.nix b/pkgs/development/tools/rust/sqlx-cli/default.nix index ef71a6528b0c..98898bcf9c31 100644 --- a/pkgs/development/tools/rust/sqlx-cli/default.nix +++ b/pkgs/development/tools/rust/sqlx-cli/default.nix @@ -4,6 +4,7 @@ , fetchFromGitHub , installShellFiles , pkg-config +, openssl , libiconv , testers , sqlx-cli @@ -26,19 +27,23 @@ rustPlatform.buildRustPackage rec { cargoHash = "sha256-X7fLbih1s3sxn8vb2kQeFUKDK2DlC+sjm9ZTwj3FD1Y="; doCheck = false; - cargoBuildFlags = [ "--package sqlx-cli --no-default-features --features rustls,postgres,sqlite,mysql,completions" ]; + cargoBuildFlags = [ "--package sqlx-cli --no-default-features --features native-tls,postgres,sqlite,mysql,completions" ]; nativeBuildInputs = [ installShellFiles pkg-config ]; - buildInputs = lib.optionals stdenv.isDarwin [ - CoreFoundation - Security - SystemConfiguration - libiconv - ]; + buildInputs = + lib.optionals stdenv.isLinux [ + openssl + ] ++ + lib.optionals stdenv.isDarwin [ + CoreFoundation + Security + SystemConfiguration + libiconv + ]; postInstall = '' for shell in bash fish zsh; do |