Skip to content

Commit

Permalink
staging-next 2024-11-07 - the last one for 24.11 (#354201)
Browse files Browse the repository at this point in the history
  • Loading branch information
vcunat committed Nov 14, 2024
2 parents 3400d5e + 3a06a0e commit 7f2d3d2
Show file tree
Hide file tree
Showing 369 changed files with 4,129 additions and 5,052 deletions.
4 changes: 2 additions & 2 deletions ci/OWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,8 @@ nixos/modules/installer/tools/nix-fallback-paths.nix @NixOS/nix-team @raitobeza

# Python-related code and docs
/doc/languages-frameworks/python.section.md @mweinelt @natsukium
/maintainers/scripts/update-python-libraries @natsukium
/pkgs/development/interpreters/python @natsukium
/maintainers/scripts/update-python-libraries @mweinelt @natsukium
/pkgs/development/interpreters/python @mweinelt @natsukium
/pkgs/top-level/python-packages.nix @natsukium
/pkgs/top-level/release-python.nix @natsukium

Expand Down
10 changes: 10 additions & 0 deletions doc/hooks/meson.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,16 @@ setup hook registering ninja-based build and install phases.

Controls the flags passed to `meson setup` during configure phase.

#### `mesonBuildDir` {#meson-build-dir}

Directory where Meson will put intermediate files.

Setting this can be useful for debugging multiple Meson builds while in the same source directory, for example, when building for different platforms.
Different values for each build will prevent build artefacts from interefering with each other.
This setting has no tangible effect when running the build in a sandboxed derivation.

The default value is `build`.

#### `mesonWrapMode` {#meson-wrap-mode}

Which value is passed as
Expand Down
4 changes: 2 additions & 2 deletions doc/languages-frameworks/haskell.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ Available compilers are collected under `haskell.compiler`.
Each of those compiler versions has a corresponding attribute set `packages` built with
it. However, the non-standard package sets are not tested regularly and, as a
result, contain fewer working packages. The corresponding package set for GHC
9.4.5 is `haskell.packages.ghc945`. In fact `haskellPackages` is just an alias
for `haskell.packages.ghc964`:
9.4.5 is `haskell.packages.ghc945`. In fact `haskellPackages` (at the time of writing) is just an alias
for `haskell.packages.ghc966`:

Every package set also re-exposes the GHC used to build its packages as `haskell.packages.*.ghc`.

Expand Down
1 change: 1 addition & 0 deletions doc/languages-frameworks/python.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ sets are
* `pkgs.python311Packages`
* `pkgs.python312Packages`
* `pkgs.python313Packages`
* `pkgs.python314Packages`
* `pkgs.pypy27Packages`
* `pkgs.pypy39Packages`
* `pkgs.pypy310Packages`
Expand Down
8 changes: 5 additions & 3 deletions doc/languages-frameworks/qt.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,14 @@ stdenv.mkDerivation {

The same goes for Qt 5 where libraries and tools are under `libsForQt5`.

Any Qt package should include `wrapQtAppsHook` in `nativeBuildInputs`, or explicitly set `dontWrapQtApps` to bypass generating the wrappers.
Any Qt package should include `wrapQtAppsHook` or `wrapQtAppsNoGuiHook` in `nativeBuildInputs`, or explicitly set `dontWrapQtApps` to bypass generating the wrappers.

::: {.note}
Qt 6 graphical applications should also include `qtwayland` in `buildInputs` on Linux (but not on platforms e.g. Darwin, where `qtwayland` is not available), to ensure the Wayland platform plugin is available.

This may become default in the future, see [NixOS/nixpkgs#269674](https://github.com/NixOS/nixpkgs/pull/269674).
`wrapQtAppsHook` propagates plugins and QML components from `qtwayland` on platforms that support it, to allow applications to act as native Wayland clients. It should be used for all graphical applications.

`wrapQtAppsNoGuiHook` does not propagate `qtwayland` to reduce closure size for purely command-line applications.

:::

## Packages supporting multiple Qt versions {#qt-versions}
Expand Down
5 changes: 5 additions & 0 deletions lib/licenses.nix
Original file line number Diff line number Diff line change
Expand Up @@ -895,6 +895,11 @@ lib.mapAttrs mkLicense ({
fullName = "MIT License";
};

mit-cmu = {
spdxId = "MIT-CMU";
fullName = "CMU License";
};

mit-feh = {
spdxId = "MIT-feh";
fullName = "feh License";
Expand Down
39 changes: 28 additions & 11 deletions pkgs/applications/audio/cdparanoia/default.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{ lib, stdenv, fetchurl, fetchpatch
, updateAutotoolsGnuConfigScriptsHook, autoreconfHook
, IOKit, Carbon
}:

stdenv.mkDerivation rec {
Expand All @@ -14,36 +13,54 @@ stdenv.mkDerivation rec {

patches = lib.optionals stdenv.hostPlatform.isDarwin [
(fetchpatch {
url = "https://trac.macports.org/export/70964/trunk/dports/audio/cdparanoia/files/osx_interface.patch";
sha256 = "0hq3lvfr0h1m3p0r33jij0s1aspiqlpy533rwv19zrfllb39qvr8";
url = "https://github.com/macports/macports-ports/raw/c8e15973bc3c1e1ab371bc0ee2de14209e639f17/audio/cdparanoia/files/osx_interface.patch";
hash = "sha256-9p4+9dRvqLHkpR0RWLQcNL1m7fb7L6r+c9Q2tt4jh0U=";
# Our configure patch will subsume it, but we want our configure
# patch to be used on all platforms so we cannot just start where
# this leaves off.
excludes = [ "configure.in" ];
})
(fetchurl {
url = "https://trac.macports.org/export/70964/trunk/dports/audio/cdparanoia/files/patch-paranoia_paranoia.c.10.4.diff";
sha256 = "17l2qhn8sh4jy6ryy5si6ll6dndcm0r537rlmk4a6a8vkn852vad";
hash = "sha256-TW1RkJ0bKaPIrDSfUTKorNlmKDVRF++z8ZJAjSzEgp4=";
})
# add missing include files needed for function prototypes
(fetchpatch {
url = "https://github.com/macports/macports-ports/raw/f210a6061bc53c746730a37922399c6de6d69cb7/audio/cdparanoia/files/fixing-include.patch";
hash = "sha256-6a/u4b8/H/4XjyFup23xySgyAI9SMVMom4PLvH8KzhE=";
})
] ++ [
# Has to come after darwin patches
./fix_private_keyword.patch
# Order does not matter
./configure.patch
# labs for long
(fetchpatch {
url = "https://github.com/macports/macports-ports/raw/f210a6061bc53c746730a37922399c6de6d69cb7/audio/cdparanoia/files/fixing-labs.patch";
hash = "sha256-BMMQ5bbPP3eevuwWUVjQCtRBiWbkAHD+O0C0fp+BPaw=";
})
# use "%s" for passing a buffer to fprintf
(fetchpatch {
url = "https://github.com/macports/macports-ports/raw/f210a6061bc53c746730a37922399c6de6d69cb7/audio/cdparanoia/files/fixing-fprintf.patch";
hash = "sha256-2dJl16p+f5l3wxVOJhsuLiQ9a4prq7jsRZP8/ygEae4=";
})
# add support for IDE4-9
(fetchpatch {
url = "https://salsa.debian.org/optical-media-team/cdparanoia/-/raw/bbf353721834b3784ccc0fd54a36a6b25181f5a4/debian/patches/02-ide-devices.patch";
hash = "sha256-S6OzftUIPPq9JHsoAE2K51ltsI1WkVaQrpgCjgm5AG4=";
})
# check buffer is non-null before dereferencing
(fetchpatch {
url = "https://salsa.debian.org/optical-media-team/cdparanoia/-/raw/f7bab3024c5576da1fdb7497abbd6abc8959a98c/debian/patches/04-endian.patch";
hash = "sha256-krfprwls0L3hsNfoj2j69J5k1RTKEQtzE0fLYG9EJKo=";
})
] ++ lib.optional stdenv.hostPlatform.isMusl ./utils.patch;

nativeBuildInputs = [
updateAutotoolsGnuConfigScriptsHook
autoreconfHook
];

propagatedBuildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
Carbon
IOKit
];

hardeningDisable = [ "format" ];

# Build system reuses the same object file names for shared and static
# library. Occasionally fails in the middle:
# gcc -O2 -fsigned-char -g -O2 -c scan_devices.c
Expand Down
4 changes: 2 additions & 2 deletions pkgs/applications/audio/mpg123/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ assert withConplay -> !libOnly;

stdenv.mkDerivation rec {
pname = "${lib.optionalString libOnly "lib"}mpg123";
version = "1.32.7";
version = "1.32.8";

src = fetchurl {
url = "mirror://sourceforge/mpg123/mpg123-${version}.tar.bz2";
hash = "sha256-PIkZJDcHlRysDjw5u/KGU7yv/EPJj/FoAaJzUNuPDyE=";
hash = "sha256-/u4TdMeVQODkBd8LxF/eIK1nARQlw2GidZ4hRolKJ6c=";
};

outputs = [ "out" "dev" "man" ] ++ lib.optional withConplay "conplay";
Expand Down
22 changes: 4 additions & 18 deletions pkgs/applications/audio/musescore/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31,24 +31,10 @@
, qtnetworkauth
, qttools
, nixosTests
, darwin
, apple-sdk_11
}:

let
stdenv' = if stdenv.hostPlatform.isDarwin then darwin.apple_sdk_11_0.stdenv else stdenv;
# portaudio propagates Darwin frameworks. Rebuild it using the 11.0 stdenv
# from Qt and the 11.0 SDK frameworks.
portaudio' = if stdenv.hostPlatform.isDarwin then portaudio.override {
stdenv = stdenv';
inherit (darwin.apple_sdk_11_0.frameworks)
AudioUnit
AudioToolbox
CoreAudio
CoreServices
Carbon
;
} else portaudio;
in stdenv'.mkDerivation (finalAttrs: {
stdenv.mkDerivation (finalAttrs: {
pname = "musescore";
version = "4.4.3";

Expand Down Expand Up @@ -116,7 +102,7 @@ in stdenv'.mkDerivation (finalAttrs: {
libpulseaudio
libsndfile
libvorbis
portaudio'
portaudio
portmidi
flac
libopusenc
Expand All @@ -132,7 +118,7 @@ in stdenv'.mkDerivation (finalAttrs: {
alsa-lib
qtwayland
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
darwin.apple_sdk_11_0.frameworks.Cocoa
apple-sdk_11
];

postInstall = ''
Expand Down
5 changes: 3 additions & 2 deletions pkgs/applications/editors/emacs/build-support/elpa2nix.el
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,10 @@ The file can either be a tar file or an Emacs Lisp file."

(let ((flag (getenv "turnCompilationWarningToError")))
(when (and flag
(not (string-empty-p flag)))
;; we do not use `string-empty-p' because it requires subr-x in Emacs <= 26
(not (string= flag "")))
(setq byte-compile-error-on-warn t)))

(let ((flag (getenv "ignoreCompilationError")))
(when (string-empty-p flag)
(when (string= flag "")
(setq byte-compile-debug t)))
4 changes: 2 additions & 2 deletions pkgs/applications/editors/vim/common.nix
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{ lib, fetchFromGitHub }:
rec {
version = "9.1.0765";
version = "9.1.0787";

outputs = [ "out" "xxd" ];

src = fetchFromGitHub {
owner = "vim";
repo = "vim";
rev = "v${version}";
hash = "sha256-LtEEMpdWXA6qyjAIjgsZoc4hNXXG2ZXxCsbWKC5aEPI=";
hash = "sha256-kV2SaIOUv+ZcDsqBibZZ38gCevVLhejcYtY0TCQVtig=";
};

enableParallelBuilding = true;
Expand Down
1 change: 0 additions & 1 deletion pkgs/applications/editors/vim/macvim.nix
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,6 @@ stdenv.mkDerivation (finalAttrs: {
# Xcode project or pass it as a flag to xcodebuild as well.
postConfigure = ''
substituteInPlace src/auto/config.mk \
--replace "PERL_CFLAGS${"\t"}=" "PERL_CFLAGS${"\t"}= -I${darwin.libutil}/include" \
--replace " -L${stdenv.cc.libc}/lib" "" \
--replace " -L${darwin.libobjc}/lib" "" \
--replace " -L${darwin.libunwind}/lib" "" \
Expand Down
28 changes: 28 additions & 0 deletions pkgs/applications/editors/yi/wrapper.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# To use this for hacking of your Yi config file, drop into a shell
# with env attribute.
{
lib,
stdenv,
makeWrapper,
haskellPackages,
extraPackages ? (s: [ ]),
}:
let
yiEnv = haskellPackages.ghcWithPackages (self: [ self.yi ] ++ extraPackages self);
in
stdenv.mkDerivation {
pname = "yi-custom";
dontUnpack = true;
nativeBuildInputs = [ makeWrapper ];

buildCommand = ''
mkdir -p $out/bin
makeWrapper ${haskellPackages.yi}/bin/yi $out/bin/yi \
--set NIX_GHC ${yiEnv}/bin/ghc
'';

# For hacking purposes
passthru.env = yiEnv;

inherit (haskellPackages.yi) meta version;
}
2 changes: 0 additions & 2 deletions pkgs/applications/graphics/pineapple-pictures/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
, stdenv
, fetchFromGitHub
, qtsvg
, qtwayland
, qttools
, exiv2
, wrapQtAppsHook
Expand All @@ -28,7 +27,6 @@ stdenv.mkDerivation (finalAttrs: {

buildInputs = [
qtsvg
qtwayland
exiv2
];

Expand Down
9 changes: 2 additions & 7 deletions pkgs/applications/version-management/fnc/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ lib, fetchurl, stdenv, zlib, ncurses, libiconv, darwin }:
{ lib, fetchurl, stdenv, zlib, ncurses, libiconv, apple-sdk_11, darwinMinVersionHook }:

stdenv.mkDerivation (finalAttrs: {
pname = "fnc";
Expand All @@ -9,18 +9,13 @@ stdenv.mkDerivation (finalAttrs: {
hash = "sha256-npS+sOxF0S/9TuFjtEFlev0HpIOsaP6zmcfopPNUehk=";
};

buildInputs = [ libiconv ncurses zlib ] ++ lib.optionals stdenv.hostPlatform.isDarwin [
darwin.libutil
];
buildInputs = [ libiconv ncurses zlib apple-sdk_11 (darwinMinVersionHook "11.0") ];

makeFlags = [ "PREFIX=$(out)" ];

env.NIX_CFLAGS_COMPILE = toString (lib.optionals stdenv.cc.isGNU [
# Needed with GCC 12
"-Wno-error=maybe-uninitialized"
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
# error: 'strtonum' is only available on macOS 11.0 or newer
"-Wno-error=unguarded-availability-new"
]);

preInstall = ''
Expand Down
15 changes: 9 additions & 6 deletions pkgs/applications/version-management/git/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -245,10 +245,11 @@ stdenv.mkDerivation (finalAttrs: {

+ (if svnSupport then ''
# wrap git-svn
wrapProgram $out/libexec/git-core/git-svn \
--set GITPERLLIB "$out/${perlPackages.perl.libPrefix}:${perlPackages.makePerlPath (perlLibs ++ [svn.out])}" \
--prefix PATH : "${svn.out}/bin" ''
else '' # replace git-svn by notification script
wrapProgram $out/libexec/git-core/git-svn \
--set GITPERLLIB "$out/${perlPackages.perl.libPrefix}:${perlPackages.makePerlPath (perlLibs ++ [svn.out])}" \
--prefix PATH : "${svn.out}/bin"
'' else ''
# replace git-svn by notification script
notSupported $out/libexec/git-core/git-svn
'')

Expand All @@ -261,9 +262,11 @@ stdenv.mkDerivation (finalAttrs: {
notSupported $out/libexec/git-core/git-send-email
'')

+ lib.optionalString withManual ''# Install man pages
+ lib.optionalString withManual ''
# Install man pages
make -j $NIX_BUILD_CORES PERL_PATH="${buildPackages.perl}/bin/perl" cmd-list.made install install-html \
-C Documentation ''
-C Documentation
''

+ (if guiSupport then ''
# Wrap Tcl/Tk programs
Expand Down
6 changes: 3 additions & 3 deletions pkgs/applications/version-management/mercurial/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ let

self = python3Packages.buildPythonApplication rec {
pname = "mercurial${lib.optionalString fullBuild "-full"}";
version = "6.8.1";
version = "6.8.2";

src = fetchurl {
url = "https://mercurial-scm.org/release/mercurial-${version}.tar.gz";
hash = "sha256-Aw6Kem1ZDk6utAPuJWdWFc2A0jbzq4oLVtzIQYEViwU=";
hash = "sha256-qsYYEGdorR7ZdsP+fIZZ/smebwtTN+pupVT66EkMT04=";
};

format = "other";
Expand All @@ -35,7 +35,7 @@ let
cargoDeps = if rustSupport then rustPlatform.fetchCargoTarball {
inherit src;
name = "mercurial-${version}";
hash = "sha256-i5AVyi9m7qLLubhV8fBhhZ6/RYOjMdwmv9Bek9pT/xo=";
hash = "sha256-/HjgGtjKfLLufEqyT7xHYIlC5xnVunYoA+H1xLS1bVw=";
sourceRoot = "mercurial-${version}/rust";
} else null;
cargoRoot = if rustSupport then "rust" else null;
Expand Down
16 changes: 0 additions & 16 deletions pkgs/build-support/bintools-wrapper/add-darwin-ldflags-before.sh
Original file line number Diff line number Diff line change
Expand Up @@ -79,19 +79,3 @@ if [ ! "$havePlatformVersionFlag" ]; then
extraBefore+=(-@darwinPlatform@_version_min "${@darwinMinVersionVariable@_@suffixSalt@:-@darwinMinVersion@}")
fi
fi

mangleVarSingle DEVELOPER_DIR ${role_suffixes[@]+"${role_suffixes[@]}"}

# Allow wrapped bintools to do something useful when no `DEVELOPER_DIR` is set, which can happen when
# the compiler is run outside of a stdenv or intentionally in an environment with no environment variables set.
DEVELOPER_DIR=${DEVELOPER_DIR_@suffixSalt@:-@fallback_sdk@}

# Darwin looks for frameworks in the SDK located at `DEVELOPER_DIR`.
extraBefore+=("-F$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks")
extraBefore+=("-L$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib")

# While the Swift wrapper should take care of this, anything that needs to link Swift auto-linked frameworks
# also needs these paths. Note: Test and conditionally add it because the path may not exist in older SDKs.
if [ -d "$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/swift" ]; then
extraBefore+=("-L$DEVELOPER_DIR/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/lib/swift")
fi
Loading

0 comments on commit 7f2d3d2

Please sign in to comment.