Merge staging-next into staging

This commit is contained in:
github-actions[bot] 2022-12-19 18:01:41 +00:00 committed by GitHub
commit 141c0ed100
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
22 changed files with 244 additions and 99 deletions

View File

@ -209,6 +209,16 @@
<link linkend="opt-services.opensnitch.rules">services.opensnitch.rules</link>
</para>
</listitem>
<listitem>
<para>
The module <literal>usbmuxd</literal> now has the ability to
change the package used by the daemon. In case youre
experiencing issues with <literal>usbmuxd</literal> you can
try an alternative program like <literal>usbmuxd2</literal>.
Available as
<link linkend="opt-services.usbmuxd.package">services.usbmuxd.package</link>
</para>
</listitem>
<listitem>
<para>
<literal>services.mastodon</literal> gained a tootctl wrapped

View File

@ -61,6 +61,8 @@ In addition to numerous new and upgraded packages, this release has the followin
- The module for the application firewall `opensnitch` got the ability to configure rules. Available as [services.opensnitch.rules](#opt-services.opensnitch.rules)
- The module `usbmuxd` now has the ability to change the package used by the daemon. In case you're experiencing issues with `usbmuxd` you can try an alternative program like `usbmuxd2`. Available as [services.usbmuxd.package](#opt-services.usbmuxd.package)
- `services.mastodon` gained a tootctl wrapped named `mastodon-tootctl` similar to `nextcloud-occ` which can be executed from any user and switches to the configured mastodon user with sudo and sources the environment variables.
- The `dnsmasq` service now takes configuration via the

View File

@ -52,13 +52,11 @@ in
environment.systemPackages = [ cfg.package ];
environment.etc."man_db.conf".text =
let
mandbForBuild = if pkgs.stdenv.hostPlatform == pkgs.stdenv.buildPlatform then
cfg.package
else
pkgs.buildPackages.man-db;
manualCache = pkgs.runCommand "man-cache" { } ''
manualCache = pkgs.runCommand "man-cache" {
nativeBuildInputs = [ cfg.package ];
} ''
echo "MANDB_MAP ${cfg.manualPages}/share/man $out" > man.conf
${mandbForBuild}/bin/mandb -C man.conf -psc >/dev/null 2>&1
mandb -C man.conf -psc >/dev/null 2>&1
'';
in
''

View File

@ -1,10 +1,68 @@
{ pkgs, lib, config, ... }:
let
cfg = config.programs.nix-ld;
# TODO make glibc here configureable?
nix-ld-so = pkgs.runCommand "ld.so" {} ''
ln -s "$(cat '${pkgs.stdenv.cc}/nix-support/dynamic-linker')" $out
'';
nix-ld-libraries = pkgs.buildEnv {
name = "lb-library-path";
pathsToLink = [ "/lib" ];
paths = map lib.getLib cfg.libraries;
extraPrefix = "/share/nix-ld";
ignoreCollisions = true;
};
# We currently take all libraries from systemd and nix as the default.
# Is there a better list?
baseLibraries = with pkgs; [
zlib
zstd
stdenv.cc.cc
curl
openssl
attr
libssh
bzip2
libxml2
acl
libsodium
util-linux
xz
systemd
];
in
{
meta.maintainers = [ lib.maintainers.mic92 ];
options = {
programs.nix-ld.enable = lib.mkEnableOption (lib.mdDoc ''nix-ld, Documentation: <https://github.com/Mic92/nix-ld>'');
programs.nix-ld = {
enable = lib.mkEnableOption (lib.mdDoc ''nix-ld, Documentation: <https://github.com/Mic92/nix-ld>'');
package = lib.mkOption {
type = lib.types.package;
description = lib.mdDoc "Which package to use for the nix-ld.";
default = pkgs.nix-ld;
defaultText = lib.mdDoc "pkgs.nix-ld";
};
libraries = lib.mkOption {
type = lib.types.listOf lib.types.package;
description = lib.mdDoc "Libraries that automatically become available to all programs. The default set includes common libraries.";
default = baseLibraries;
defaultText = lib.mdDoc "baseLibraries";
};
};
};
config = lib.mkIf config.programs.nix-ld.enable {
systemd.tmpfiles.packages = [ pkgs.nix-ld ];
systemd.tmpfiles.packages = [ cfg.package ];
environment.systemPackages = [ nix-ld-libraries ];
environment.pathsToLink = [ "/share/nix-ld" ];
environment.variables = {
NIX_LD = toString nix-ld-so;
NIX_LD_LIBRARY_PATH = "/run/current-system/sw/share/nix-ld/lib";
};
};
}

View File

@ -13,6 +13,7 @@ in
{
options.services.usbmuxd = {
enable = mkOption {
type = types.bool;
default = false;
@ -39,6 +40,15 @@ in
The group usbmuxd should use to run after startup.
'';
};
package = mkOption {
type = types.package;
default = pkgs.usbmuxd;
defaultText = literalExpression "pkgs.usbmuxd";
description = lib.mdDoc "Which package to use for the usbmuxd daemon.";
relatedPackages = [ "usbmuxd" "usbmuxd2" ];
};
};
config = mkIf cfg.enable {
@ -68,7 +78,7 @@ in
# Trigger the udev rule manually. This doesn't require replugging the
# device when first enabling the option to get it to work
ExecStartPre = "${pkgs.udev}/bin/udevadm trigger -s usb -a idVendor=${apple}";
ExecStart = "${pkgs.usbmuxd}/bin/usbmuxd -U ${cfg.user} -f";
ExecStart = "${cfg.package}/bin/usbmuxd -U ${cfg.user} -v";
};
};

View File

@ -12,9 +12,6 @@ import ./make-test-python.nix ({ lib, pkgs, ...} :
};
testScript = ''
start_all()
path = "${pkgs.stdenv.cc}/nix-support/dynamic-linker"
with open(path) as f:
real_ld = f.read().strip()
machine.succeed(f"NIX_LD={real_ld} hello")
machine.succeed("hello")
'';
})

View File

@ -34,6 +34,7 @@
, pango
, pipewire
, systemd
, wayland
, xdg-utils
, xorg
}:
@ -121,6 +122,7 @@ let
pipewire
stdenv.cc.cc
systemd
wayland
xorg.libX11
xorg.libXScrnSaver
xorg.libXcomposite

View File

@ -12,11 +12,11 @@
stdenv.mkDerivation rec {
pname = "terminology";
version = "1.12.1";
version = "1.13.0";
src = fetchurl {
url = "https://download.enlightenment.org/rel/apps/${pname}/${pname}-${version}.tar.xz";
sha256 = "1aasddf2343qj798b5s8qwif3lxj4pyjax6fa9sfi6if9icdkkpq";
sha256 = "FqN/7Ne71j7J3j7GwK8zHO531t/ag4obFXPW8phHTaU=";
};
nativeBuildInputs = [

View File

@ -54,14 +54,14 @@
stdenv.mkDerivation (finalAttrs: {
pname = "flatpak";
version = "1.14.0";
version = "1.14.1";
# TODO: split out lib once we figure out what to do with triggerdir
outputs = [ "out" "dev" "man" "doc" "devdoc" "installedTests" ];
src = fetchurl {
url = "https://github.com/flatpak/flatpak/releases/download/${finalAttrs.version}/flatpak-${finalAttrs.version}.tar.xz";
sha256 = "sha256-jidpc3cOok3fJZetSuzTa5g5PmvekeSOF0OqymfyeBU="; # Taken from https://github.com/flatpak/flatpak/releases/
sha256 = "sha256-CjyCM0MBjMWJhrbIJUVgnIzb8Pul8B2IMHvRSstd058="; # Taken from https://github.com/flatpak/flatpak/releases/
};
patches = [
@ -89,10 +89,6 @@ stdenv.mkDerivation (finalAttrs: {
# https://github.com/NixOS/nixpkgs/issues/53441
./unset-env-vars.patch
# Do not clear XDG_DATA_DIRS in fish shell
# https://github.com/flatpak/flatpak/pull/5123
./no-breaking-fish.patch
# The icon validator needs to access the gdk-pixbuf loaders in the Nix store
# and cannot bind FHS paths since those are not available on NixOS.
finalAttrs.passthru.icon-validator-patch

View File

@ -1,11 +0,0 @@
--- a/profile/flatpak.fish
+++ b/profile/flatpak.fish
@@ -1,7 +1,7 @@
if type -q flatpak
# Set XDG_DATA_DIRS to include Flatpak installations
- set -x --path XDG_DATA_DIRS
+ set -x --path XDG_DATA_DIRS $XDG_DATA_DIRS
set -q XDG_DATA_DIRS[1]; or set XDG_DATA_DIRS /usr/local/share /usr/share
set -q XDG_DATA_HOME; or set -l XDG_DATA_HOME $HOME/.local/share

View File

@ -27,7 +27,7 @@
stdenv.mkDerivation (finalAttrs: {
pname = "xdg-desktop-portal";
version = "1.15.0";
version = "1.16.0";
outputs = [ "out" "installedTests" ];
@ -35,7 +35,7 @@ stdenv.mkDerivation (finalAttrs: {
owner = "flatpak";
repo = "xdg-desktop-portal";
rev = finalAttrs.version;
sha256 = "sha256-Kw3zJeGwPfw1fDo8HsgYmrpgCk/PUvWZPRloKJNAJVc=";
sha256 = "sha256-5VNauinTvZrSaQzyP/quL/3p2RPcTJUDLscEQMJpvYA=";
};
patches = [

View File

@ -5,45 +5,49 @@
, jinja2
, pytestCheckHook
, railroad-diagrams
, pyparsing
}:
let
pyparsing = buildPythonPackage rec {
pname = "pyparsing";
version = "3.0.9";
format = "pyproject";
buildPythonPackage rec {
pname = "pyparsing";
version = "3.0.9";
format = "pyproject";
src = fetchFromGitHub {
owner = "pyparsing";
repo = pname;
rev = "pyparsing_${version}";
sha256 = "sha256-aCRyJQyLf8qQ6NO41q+HC856TjIHzIt0vyVBLV+3teE=";
};
nativeBuildInputs = [
flit-core
];
# circular dependencies with pytest if enabled by default
doCheck = false;
checkInputs = [
jinja2
pytestCheckHook
railroad-diagrams
];
pythonImportsCheck = [ "pyparsing" ];
passthru.tests = {
check = pyparsing.overridePythonAttrs (_: { doCheck = true; });
};
meta = with lib; {
homepage = "https://github.com/pyparsing/pyparsing";
description = "An alternative approach to creating and executing simple grammars, vs. the traditional lex/yacc approach, or the use of regular expressions";
license = licenses.mit;
maintainers = with maintainers; [ kamadorueda ];
};
src = fetchFromGitHub {
owner = "pyparsing";
repo = pname;
rev = "pyparsing_${version}";
sha256 = "sha256-aCRyJQyLf8qQ6NO41q+HC856TjIHzIt0vyVBLV+3teE=";
};
in
pyparsing
nativeBuildInputs = [
flit-core
];
# circular dependencies with pytest if enabled by default
doCheck = false;
checkInputs = [
jinja2
pytestCheckHook
railroad-diagrams
];
pythonImportsCheck = [ "pyparsing" ];
passthru.tests = {
check = pyparsing.overridePythonAttrs (_: { doCheck = true; });
};
meta = with lib; {
homepage = "https://github.com/pyparsing/pyparsing";
description = "Python library for creating PEG parsers";
longDescription = ''
The pyparsing module is an alternative approach to creating and executing
simple grammars, vs. the traditional lex/yacc approach, or the use of
regular expressions. The pyparsing module provides a library of classes
that client code uses to construct the grammar directly in Python code.
'';
license = licenses.mit;
maintainers = with maintainers; [ kamadorueda ];
};
}

View File

@ -3,14 +3,14 @@
stdenv.mkDerivation rec {
pname = "sbt-extras";
rev = "14623b935766e11a0a3f6ab1f686bb1c5d244b21";
version = "2022-10-17";
rev = "5eeee846642c8226931263ed758ef80f077cadaf";
version = "2022-11-11";
src = fetchFromGitHub {
owner = "paulp";
repo = "sbt-extras";
inherit rev;
sha256 = "nwhNevyLOzkYdpm1AK5I4ByJ7VdnlgwcSjXV11pzZkw=";
sha256 = "2eUGQa0SdfnENbnjy9ZDxd0lKhUrzmTyDLB4fupqVIs=";
};
dontBuild = true;

View File

@ -0,0 +1,43 @@
{ lib
, buildGoModule
, fetchFromGitHub
, installShellFiles
}:
buildGoModule rec {
pname = "supabase-cli";
version = "1.27.0";
src = fetchFromGitHub {
owner = "supabase";
repo = "cli";
rev = "v${version}";
sha256 = "sha256-gAfgqOeJ1cQ5Igxcut0FXkzhK38Q/mUTXfFaZE0dNCs=";
};
vendorSha256 = "sha256-RO9dZP236Kt8SSpZFF7KRksrjgwiEkPxE5DIMUK69Kw=";
ldflags = [ "-s" "-w" "-X" "github.com/supabase/cli/cmd.version=${version}" ];
doCheck = false; # tests are trying to connect to localhost
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
rm $out/bin/{codegen,docgen,listdep}
mv $out/bin/{cli,supabase}
installShellCompletion --cmd supabase \
--bash <($out/bin/supabase completion bash) \
--fish <($out/bin/supabase completion fish) \
--zsh <($out/bin/supabase completion zsh)
'';
meta = with lib; {
description = "A CLI for interacting with supabase";
homepage = "https://github.com/supabase/cli";
license = licenses.mit;
maintainers = with maintainers; [ gerschtli ];
mainProgram = "supabase";
};
}

View File

@ -11,14 +11,14 @@
rustPlatform.buildRustPackage rec {
pname = "uniffi-bindgen";
version = "0.21.0";
version = "0.22.0";
src = fetchCrate {
inherit pname version;
sha256 = "sha256-yVpxyYaFkX1HuFi4xcj45rsMbMIcdTHs9zfGvtcFdH8=";
sha256 = "sha256-cUJsfAlzdoGMeFcdXwdPU0JcruneY60pssJPkJtb5gs=";
};
cargoSha256 = "sha256-qn27aRVdD+/EWmCSF2t+CdMhtOknDCVnG9uDa2Rwf0A=";
cargoSha256 = "sha256-k5uIR5rO4T1Xsu50vdLxCgSsVkNcxXHT4MitnMZkY6g=";
nativeBuildInputs = [ makeWrapper ];

View File

@ -12,30 +12,58 @@
, libXrandr
, libXi
, libXcursor
, udev
, alsa-lib
, stdenv
, libxcb
, pkg-config
, makeWrapper
, writeShellScript
, patchelf
}:
rustPlatform.buildRustPackage rec {
let
version = "0.10.0";
# Patch for airshipper to install veloren
patch = let
runtimeLibs = [
udev
alsa-lib
stdenv.cc.cc.lib
libxkbcommon
libxcb
libX11
libXcursor
libXrandr
libXi
vulkan-loader
libGL
];
in
writeShellScript "patch" ''
echo "making binaries executable"
chmod +x {veloren-voxygen,veloren-server-cli}
echo "patching dynamic linkers"
${patchelf}/bin/patchelf \
--set-interpreter "${stdenv.cc.bintools.dynamicLinker}" \
veloren-server-cli
${patchelf}/bin/patchelf \
--set-interpreter "${stdenv.cc.bintools.dynamicLinker}" \
--set-rpath "${lib.makeLibraryPath runtimeLibs}" \
veloren-voxygen
'';
in
rustPlatform.buildRustPackage {
pname = "airshipper";
version = "0.7.0";
inherit version;
src = fetchFromGitLab {
owner = "Veloren";
repo = "airshipper";
rev = "v${version}";
sha256 = "sha256-nOE9ZNHxLEAnMkuBSpxmeq3DxkRIlcoase6AxU+eFug=";
sha256 = "sha256-5zP1Ye1fJNQp8eWKwdxLqBr4qzBfWEEBsJ9s7+8idL4=";
};
patches = [
# this *should* be merged in time for the release following 0.7.0
(fetchpatch {
url = "https://github.com/veloren/Airshipper/commit/97fc986ab4cbf59f2c764f647710f19db86031b4.patch";
hash = "sha256-Sg5et+yP6Z44wV/t9zqKLpg1C0cq6rV+3WrzAH4Za3U=";
})
];
cargoSha256 = "sha256-s3seKVEhXyOVlt3a8cubzRWoB4SVQpdCmq12y0FpDUw=";
cargoSha256 = "sha256-oksJYuuHdfP5mMQ+zYHH5SgD6YUK+zE3+AY90ZzHRUU=";
buildInputs = [
openssl
@ -49,9 +77,11 @@ rustPlatform.buildRustPackage rec {
];
nativeBuildInputs = [ pkg-config makeWrapper ];
RUSTC_BOOTSTRAP = 1; # We need rust unstable features
postInstall = ''
install -Dm444 -t "$out/share/applications" "client/assets/net.veloren.airshipper.desktop"
install -Dm444 "client/assets/logo.ico" "$out/share/icons/net.veloren.airshipper.ico"
install -Dm444 "client/assets/net.veloren.airshipper.png" "$out/share/icons/net.veloren.airshipper.png"
'';
postFixup =
@ -70,6 +100,7 @@ rustPlatform.buildRustPackage rec {
in
''
patchelf --set-rpath "${libPath}" "$out/bin/airshipper"
wrapProgram "$out/bin/airshipper" --set VELOREN_PATCHER "${patch}"
'';
doCheck = false;

View File

@ -12,13 +12,13 @@ let
in
stdenv.mkDerivation rec {
pname = "nix-ld";
version = "1.0.2";
version = "1.0.3";
src = fetchFromGitHub {
owner = "mic92";
repo = "nix-ld";
rev = version;
sha256 = "sha256-DlWU5i/MykqWgB9vstYbECy3e+XagXWCxi+XDJNey0s=";
sha256 = "sha256-KmnT8YfU/KI4VxBlFMUltlAVLNvF7fTEQEsp41ZUHlA=";
};
doCheck = true;

View File

@ -6,7 +6,7 @@ in
{
pulumi-aws-native = callPackage' ./pulumi-aws-native.nix { };
pulumi-azure-native = callPackage' ./pulumi-azure-native.nix { };
pulumi-language-python = callPackage ./pulumi-language-python.nix { };
pulumi-language-nodejs = callPackage ./pulumi-language-nodejs.nix { };
pulumi-language-python = callPackage ./pulumi-language-python.nix { };
pulumi-random = callPackage' ./pulumi-random.nix { };
}

View File

@ -4,13 +4,13 @@
, nodejs
}:
buildGoModule rec {
inherit (pulumi) version src;
inherit (pulumi) version src sdkVendorHash;
pname = "pulumi-language-nodejs";
sourceRoot = "${src.name}/sdk";
vendorHash = "sha256-IZIdLmNGMFjRdkLPoE9UyON3pX/GBIgz/rv108v8iLY=";
vendorHash = sdkVendorHash;
subPackages = [
"nodejs/cmd/pulumi-language-nodejs"

View File

@ -4,13 +4,13 @@
, python3
}:
buildGoModule rec {
inherit (pulumi) version src;
inherit (pulumi) version src sdkVendorHash;
pname = "pulumi-language-python";
sourceRoot = "${src.name}/sdk";
vendorHash = "sha256-gM3VpX6r/BScUyvk/XefAfbx0qYzdzSBGaWZN+89BS8=";
vendorHash = sdkVendorHash;
postPatch = ''
# Requires network

View File

@ -16,6 +16,9 @@ buildGoModule rec {
pname = "pulumi";
version = "3.49.0";
# Used in pulumi-language packages, which inherit this prop
sdkVendorHash = "sha256-gM3VpX6r/BScUyvk/XefAfbx0qYzdzSBGaWZN+89BS8=";
src = fetchFromGitHub {
owner = pname;
repo = pname;

View File

@ -18119,6 +18119,8 @@ with pkgs;
summon = callPackage ../development/tools/summon { };
supabase-cli = callPackage ../development/tools/supabase-cli { };
svlint = callPackage ../development/tools/analysis/svlint { };
svls = callPackage ../development/tools/misc/svls { };