Merge master into staging-next

This commit is contained in:
github-actions[bot] 2022-03-02 18:05:41 +00:00 committed by GitHub
commit a97d52b348
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
35 changed files with 697 additions and 34 deletions

32
.git-blame-ignore-revs Normal file
View File

@ -0,0 +1,32 @@
# This file contains a list of commits that are not likely what you
# are looking for in a blame, such as mass reformatting or renaming.
# You can set this file as a default ignore file for blame by running
# the following command.
#
# $ git config blame.ignoreRevsFile .git-blame-ignore-revs
#
# To temporarily not use this file add
# --ignore-revs-file=""
# to your blame command.
#
# The ignoreRevsFile can't be set globally due to blame failing if the file isn't present.
# To not have to set the option in every repository it is needed in,
# save the following script in your path with the name "git-bblame"
# now you can run
# $ git bblame $FILE
# to use the .git-blame-ignore-revs file if it is present.
#
# #!/usr/bin/env bash
# repo_root=$(git rev-parse --show-toplevel)
# if [[ -e $repo_root/.git-blame-ignore-revs ]]; then
# git blame --ignore-revs-file="$repo_root/.git-blame-ignore-revs" $@
# else
# git blame $@
# fi
# nixos/modules/rename: Sort alphabetically
1f71224fe86605ef4cd23ed327b3da7882dad382
# nixos: fix module paths in rename.nix
d08ede042b74b8199dc748323768227b88efcf7c

View File

@ -151,8 +151,7 @@ rec {
};
_module.freeformType = mkOption {
# Disallow merging for now, but could be implemented nicely with a `types.optionType`
type = types.nullOr (types.uniq types.attrs);
type = types.nullOr types.optionType;
internal = true;
default = null;
description = ''

View File

@ -240,6 +240,11 @@ checkConfigOutput '^"24"$' config.foo ./freeform-attrsOf.nix ./freeform-str-dep-
checkConfigError 'infinite recursion encountered' config.foo ./freeform-attrsOf.nix ./freeform-unstr-dep-str.nix
checkConfigError 'The option .* is used but not defined' config.foo ./freeform-lazyAttrsOf.nix ./freeform-unstr-dep-str.nix
checkConfigOutput '^"24"$' config.foo ./freeform-lazyAttrsOf.nix ./freeform-unstr-dep-str.nix ./define-value-string.nix
# submodules in freeformTypes should have their locations annotated
checkConfigOutput '/freeform-submodules.nix"$' config.fooDeclarations.0 ./freeform-submodules.nix
# freeformTypes can get merged using `types.type`, including submodules
checkConfigOutput '^10$' config.free.xxx.foo ./freeform-submodules.nix
checkConfigOutput '^10$' config.free.yyy.bar ./freeform-submodules.nix
## types.anything
# Check that attribute sets are merged recursively
@ -299,6 +304,13 @@ checkConfigOutput "10" config.processedToplevel ./raw.nix
checkConfigError "The option .multiple. is defined multiple times" config.multiple ./raw.nix
checkConfigOutput "bar" config.priorities ./raw.nix
# Test that types.optionType merges types correctly
checkConfigOutput '^10$' config.theOption.int ./optionTypeMerging.nix
checkConfigOutput '^"hello"$' config.theOption.str ./optionTypeMerging.nix
# Test that types.optionType correctly annotates option locations
checkConfigError 'The option .theOption.nested. in .other.nix. is already declared in .optionTypeFile.nix.' config.theOption.nested ./optionTypeFile.nix
cat <<EOF
====== module tests ======
$pass Pass

View File

@ -0,0 +1,22 @@
{ lib, options, ... }: with lib.types; {
options.fooDeclarations = lib.mkOption {
default = (options.free.type.getSubOptions [])._freeformOptions.foo.declarations;
};
options.free = lib.mkOption {
type = submodule {
config._module.freeformType = lib.mkMerge [
(attrsOf (submodule {
options.foo = lib.mkOption {};
}))
(attrsOf (submodule {
options.bar = lib.mkOption {};
}))
];
};
};
config.free.xxx.foo = 10;
config.free.yyy.bar = 10;
}

View File

@ -0,0 +1,28 @@
{ config, lib, ... }: {
_file = "optionTypeFile.nix";
options.theType = lib.mkOption {
type = lib.types.optionType;
};
options.theOption = lib.mkOption {
type = config.theType;
default = {};
};
config.theType = lib.mkMerge [
(lib.types.submodule {
options.nested = lib.mkOption {
type = lib.types.int;
};
})
(lib.types.submodule {
_file = "other.nix";
options.nested = lib.mkOption {
type = lib.types.str;
};
})
];
}

View File

@ -0,0 +1,27 @@
{ config, lib, ... }: {
options.theType = lib.mkOption {
type = lib.types.optionType;
};
options.theOption = lib.mkOption {
type = config.theType;
};
config.theType = lib.mkMerge [
(lib.types.submodule {
options.int = lib.mkOption {
type = lib.types.int;
default = 10;
};
})
(lib.types.submodule {
options.str = lib.mkOption {
type = lib.types.str;
};
})
];
config.theOption.str = "hello";
}

View File

@ -61,7 +61,11 @@ let
boolToString
;
inherit (lib.modules) mergeDefinitions;
inherit (lib.modules)
mergeDefinitions
fixupOptionType
mergeOptionDecls
;
outer_types =
rec {
isType = type: x: (x._type or "") == type;
@ -525,6 +529,31 @@ rec {
modules = toList modules;
};
# The type of a type!
optionType = mkOptionType {
name = "optionType";
description = "optionType";
check = value: value._type or null == "option-type";
merge = loc: defs:
let
# Prepares the type definitions for mergeOptionDecls, which
# annotates submodules types with file locations
optionModules = map ({ value, file }:
{
_file = file;
# There's no way to merge types directly from the module system,
# but we can cheat a bit by just declaring an option with the type
options = lib.mkOption {
type = value;
};
}
) defs;
# Merges all the types into a single one, including submodule merging.
# This also propagates file information to all submodules
mergedOption = fixupOptionType loc (mergeOptionDecls loc optionModules);
in mergedOption.type;
};
submoduleWith =
{ modules
, specialArgs ? {}

View File

@ -2418,6 +2418,23 @@
githubId = 5510514;
name = "Conrad Mearns";
};
corbanr = {
email = "corban@raunco.co";
github = "CorbanR";
githubId = 1918683;
matrix = "@corbansolo:matrix.org";
name = "Corban Raun";
keys = [
{
longkeyid = "rsa4096/0xA697A56F1F151189";
fingerprint = "6607 0B24 8CE5 64ED 22CE 0950 A697 A56F 1F15 1189";
}
{
longkeyid = "ed25519/0x230F4AC153F90F29";
fingerprint = "D8CB 816A B678 A4E6 1EC7 5325 230F 4AC1 53F9 0F29";
}
];
};
couchemar = {
email = "couchemar@yandex.ru";
github = "couchemar";
@ -10276,6 +10293,13 @@
githubId = 6047658;
name = "Ryan Horiguchi";
};
rhysmdnz = {
email = "rhys@memes.nz";
matrix = "@rhys:memes.nz";
github = "rhysmdnz";
githubId = 2162021;
name = "Rhys Davies";
};
ribose-jeffreylau = {
name = "Jeffrey Lau";
email = "jeffrey.lau@ribose.com";

View File

@ -74,6 +74,13 @@ merging is handled.
should only be used when checking, merging and nested evaluation are not
desirable.
`types.optionType`
: The type of an option's type. Its merging operation ensures that nested
options have the correct file location annotated, and that if possible,
multiple option definitions are correctly merged together. The main use
case is as the type of the `_module.freeformType` option.
`types.attrs`
: A free-form attribute set.

View File

@ -111,6 +111,20 @@
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>types.optionType</literal>
</term>
<listitem>
<para>
The type of an options type. Its merging operation ensures
that nested options have the correct file location
annotated, and that if possible, multiple option definitions
are correctly merged together. The main use case is as the
type of the <literal>_module.freeformType</literal> option.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>types.attrs</literal>

View File

@ -83,6 +83,7 @@ in {
b43Firmware_5_1_138
b43Firmware_6_30_163_46
b43FirmwareCutter
xow_dongle-firmware
] ++ optional pkgs.stdenv.hostPlatform.isx86 facetimehd-firmware;
})
(mkIf cfg.wirelessRegulatoryDatabase {

View File

@ -0,0 +1,23 @@
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.hardware.xone;
in
{
options.hardware.xone = {
enable = mkEnableOption "the xone driver for Xbox One and Xbobx Series X|S accessories";
};
config = mkIf cfg.enable {
boot = {
blacklistedKernelModules = [ "xpad" "mt76x2u" ];
extraModulePackages = with config.boot.kernelPackages; [ xone ];
};
hardware.firmware = [ pkgs.xow_dongle-firmware ];
};
meta = {
maintainers = with maintainers; [ rhysmdnz ];
};
}

View File

@ -91,6 +91,7 @@
./hardware/video/switcheroo-control.nix
./hardware/video/uvcvideo/default.nix
./hardware/video/webcam/facetimehd.nix
./hardware/xone.nix
./hardware/xpadneo.nix
./i18n/input-method/default.nix
./i18n/input-method/fcitx.nix

View File

@ -1857,8 +1857,8 @@ let
mktplcRef = {
name = "code-spell-checker";
publisher = "streetsidesoftware";
version = "2.1.5";
sha256 = "sha256-nIR3PtbtnSbAU0rS+qVtPsj++Dbfp/k86dWkx4xYcno=";
version = "2.1.7";
sha256 = "sha256-C0jYDIDBK1JH8eFaFmCUilBXCbU5y2TRF3OZAw9ijoY=";
};
meta = with lib; {
changelog = "https://marketplace.visualstudio.com/items/streetsidesoftware.code-spell-checker/changelog";

View File

@ -22,11 +22,12 @@
, jq
, xorg
, libGL
, steam-run-native
, steam-run
# needed for avoiding crash on file selector
, gsettings-desktop-schemas
, glib
, wrapGAppsHook
, hicolor-icon-theme
}:
let
@ -89,6 +90,8 @@ in stdenv.mkDerivation {
xorg.libX11
libGL
python
gsettings-desktop-schemas
hicolor-icon-theme
];
postPatch = ''
@ -103,16 +106,6 @@ in stdenv.mkDerivation {
install -D -m644 etc/PlayOnLinux.desktop $out/share/applications/playonlinux.desktop
makeWrapper $out/share/playonlinux/playonlinux{,-wrapper} \
--prefix PATH : ${binpath} \
--prefix XDG_DATA_DIRS : ${gsettings-desktop-schemas}/share/GConf
# steam-run is needed to run the downloaded wine executables
mkdir -p $out/bin
cat > $out/bin/playonlinux <<EOF
#!${stdenv.shell} -e
exec ${steam-run-native}/bin/steam-run $out/share/playonlinux/playonlinux-wrapper "\$@"
EOF
chmod a+x $out/bin/playonlinux
bunzip2 $out/share/playonlinux/bin/check_dd_x86.bz2
patchelf --set-interpreter $(cat ${ld32}) --set-rpath ${libs pkgsi686Linux} $out/share/playonlinux/bin/check_dd_x86
@ -127,6 +120,15 @@ in stdenv.mkDerivation {
done
'';
dontWrapGApps = true;
postFixup = ''
makeWrapper $out/share/playonlinux/playonlinux{,-wrapped} \
--prefix PATH : ${binpath} \
''${gappsWrapperArgs[@]}
makeWrapper ${steam-run}/bin/steam-run $out/bin/playonlinux \
--add-flags $out/share/playonlinux/playonlinux-wrapped
'';
meta = with lib; {
description = "GUI for managing Windows programs under linux";
homepage = "https://www.playonlinux.com/";

View File

@ -19,11 +19,11 @@ let
vivaldiName = if isSnapshot then "vivaldi-snapshot" else "vivaldi";
in stdenv.mkDerivation rec {
pname = "vivaldi";
version = "5.1.2567.39-1";
version = "5.1.2567.49-1";
src = fetchurl {
url = "https://downloads.vivaldi.com/${branch}/vivaldi-${branch}_${version}_amd64.deb";
sha256 = "140idghryk132nyb8np011xiwzgh518n0fxrkjnnvi3c67shq7qc";
sha256 = "1cyd789apjh71vzry2zjxb0c215yarfryb9jzxjmkfvrqg4g23xr";
};
unpackPhase = ''

View File

@ -25,7 +25,9 @@
"application/vnd.openxmlformats-officedocument.spreadsheetml.template"
"application/vnd.ms-excel.sheet.macroenabled.12"
"application/vnd.ms-excel.template.macroEnabled.12"
"application/x-dif;text/spreadsheet;text/csv"
"application/x-dif"
"text/spreadsheet"
"text/csv"
"application/x-prn"
"application/vnd.ms-excel.sheet.binary.macroenabled.12"
];

View File

@ -158,7 +158,6 @@ in stdenvNoCC.mkDerivation (args // {
${lib.optionalString (!enableParallelBuilding) "--disable-parallel"} \
-p:ContinuousIntegrationBuild=true \
-p:Deterministic=true \
-p:RestoreUseStaticGraphEvaluation=true \
--packages "$HOME/nuget_pkgs" \
${lib.optionalString (dotnetRestoreFlags != []) (builtins.toString dotnetRestoreFlags)} \
${lib.optionalString (dotnetFlags != []) (builtins.toString dotnetFlags)}

View File

@ -16,7 +16,6 @@ dotnetConfigureHook() {
dotnet restore "$project" \
-p:ContinuousIntegrationBuild=true \
-p:Deterministic=true \
-p:RestoreUseStaticGraphEvaluation=true \
--source "@nugetSource@/lib" \
${parallelFlag-} \
"${dotnetRestoreFlags[@]}" \

View File

@ -0,0 +1,102 @@
{ lib
, clang-tools
, llvmPackages
, boost17x
, protobuf
, python3Support ? false
, python3
, log4cxxSupport ? false
, log4cxx
, snappySupport ? false
, snappy
, zlibSupport ? true
, zlib
, zstdSupport ? true
, zstd
, gtest
, gtestSupport ? false
, cmake
, curl
, fetchurl
, jsoncpp
, openssl
, pkg-config
, stdenv
}:
let
/*
Check if null or false
Example:
let result = enableFeature null
=> "OFF"
let result = enableFeature false
=> "OFF"
let result = enableFeature «derivation»
=> "ON"
*/
enableCmakeFeature = p: if (p == null || p == false) then "OFF" else "ON";
# Not really sure why I need to do this.. If I call clang-tools without the override it defaults to a different version and fails
clangTools = clang-tools.override { inherit stdenv llvmPackages; };
# If boost has python enabled, then boost-python package will be installed which is used by libpulsars python wrapper
boost = if python3Support then boost17x.override { inherit stdenv; enablePython = python3Support; python = python3; } else boost17x;
defaultOptionals = [ boost protobuf ]
++ lib.optional python3Support python3
++ lib.optional snappySupport snappy.dev
++ lib.optional zlibSupport zlib
++ lib.optional zstdSupport zstd
++ lib.optional log4cxxSupport log4cxx;
in
stdenv.mkDerivation rec {
pname = "libpulsar";
version = "2.9.1";
src = fetchurl {
hash = "sha512-NKHiL7D/Lmnn6ICpQyUmmQYQETz4nZPJU9/4LMRDUQ3Pck6qDh+t6CRk+b9UQ2Vb0jvPIGTjEsSp2nC7TJk3ug==";
url = "mirror://apache/pulsar/pulsar-${version}/apache-pulsar-${version}-src.tar.gz";
};
sourceRoot = "apache-pulsar-${version}-src/pulsar-client-cpp";
# clang-tools needed for clang-format
nativeBuildInputs = [ cmake pkg-config clangTools ]
++ defaultOptionals
++ lib.optional gtestSupport gtest.dev;
buildInputs = [ jsoncpp openssl curl ]
++ defaultOptionals;
# Needed for GCC on Linux
NIX_CFLAGS_COMPILE = [ "-Wno-error=return-type" ];
cmakeFlags = [
"-DBUILD_TESTS=${enableCmakeFeature gtestSupport}"
"-DBUILD_PYTHON_WRAPPER=${enableCmakeFeature python3Support}"
"-DUSE_LOG4CXX=${enableCmakeFeature log4cxxSupport}"
"-DClangTools_PATH=${clangTools}/bin"
];
enableParallelBuilding = true;
doInstallCheck = true;
installCheckPhase = ''
echo ${lib.escapeShellArg ''
#include <pulsar/Client.h>
int main (int argc, char **argv) {
pulsar::Client client("pulsar://localhost:6650");
return 0;
}
''} > test.cc
$CXX test.cc -L $out/lib -I $out/include -lpulsar -o test
'';
meta = with lib; {
homepage = "https://pulsar.apache.org/docs/en/client-libraries-cpp";
description = "Apache Pulsar C++ library";
platforms = platforms.all;
license = licenses.asl20;
maintainers = [ maintainers.corbanr ];
};
}

View File

@ -1,4 +1,5 @@
{ lib, stdenv, fetchFromGitHub, cmake, ninja
, fetchpatch
, secureBuild ? false
}:
@ -7,14 +8,28 @@ let
in
stdenv.mkDerivation rec {
pname = "mimalloc";
version = "2.0.2";
version = "2.0.5";
src = fetchFromGitHub {
owner = "microsoft";
repo = pname;
rev = "v${version}";
sha256 = "sha256-n4FGld3bq6ZOSLTzXcVlucCGbQ5/eSFbijU0dfBD/T0=";
sha256 = "sha256-q3W/w1Ofqt6EbKF/Jf9wcC+7jAxh59B3cOGxudWQXlA=";
};
patches = [
(fetchpatch {
name = "older-macos-fixes.patch";
url = "https://github.com/microsoft/mimalloc/commit/40e0507a5959ee218f308d33aec212c3ebeef3bb.patch";
sha256 = "15qx2a3axhhwbfzxdis98b8j14y9cfgca0i484aj2pjpqnm0pb8c";
})
];
doCheck = true;
preCheck = let
ldLibraryPathEnv = if stdenv.isDarwin then "DYLD_LIBRARY_PATH" else "LD_LIBRARY_PATH";
in ''
export ${ldLibraryPathEnv}="$(pwd)/build:''${${ldLibraryPathEnv}}"
'';
nativeBuildInputs = [ cmake ninja ];
cmakeFlags = [ "-DMI_INSTALL_TOPLEVEL=ON" ] ++ lib.optional secureBuild [ "-DMI_SECURE=ON" ];
@ -25,10 +40,9 @@ stdenv.mkDerivation rec {
in ''
# first, move headers and cmake files, that's easy
mkdir -p $dev/lib
mv $out/include $dev/include
mv $out/cmake $dev/lib/
mv $out/lib/cmake $dev/lib/
find $out/lib
find $dev $out -type f
'' + (lib.optionalString secureBuild ''
# pretend we're normal mimalloc
ln -sfv $out/lib/libmimalloc-secure${suffix} $out/lib/libmimalloc${suffix}
@ -44,6 +58,6 @@ stdenv.mkDerivation rec {
homepage = "https://github.com/microsoft/mimalloc";
license = licenses.bsd2;
platforms = platforms.unix;
maintainers = with maintainers; [ thoughtpolice ];
maintainers = with maintainers; [ kamadorueda thoughtpolice ];
};
}

View File

@ -0,0 +1,48 @@
From 716fcfa3203bc881b543916bdb9a17460951cd26 Mon Sep 17 00:00:00 2001
From: "P. R. d. O" <d.ol.rod@protonmail.com>
Date: Fri, 26 Nov 2021 07:13:32 -0600
Subject: [PATCH] Fixing paths on tests
---
tests/maintest.py | 7 ++++++-
tests/speedtest.py | 7 ++++++-
2 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/tests/maintest.py b/tests/maintest.py
index 0e24ca4..3484437 100644
--- a/tests/maintest.py
+++ b/tests/maintest.py
@@ -1,6 +1,11 @@
import fleep
+import os
-with open("testfile", "rb") as file:
+current_dir = os.path.realpath(os.path.join(os.getcwd(),
+ os.path.dirname(__file__)))
+
+with open(os.path.join(current_dir, "./testfile"),
+ "rb") as file:
info = fleep.get(file.read(128))
assert info.type == ["raster-image"]
diff --git a/tests/speedtest.py b/tests/speedtest.py
index 89338ab..829d563 100644
--- a/tests/speedtest.py
+++ b/tests/speedtest.py
@@ -1,7 +1,12 @@
import time
import fleep
+import os
-with open("testfile", "rb") as file:
+current_dir = os.path.realpath(os.path.join(os.getcwd(),
+ os.path.dirname(__file__)))
+
+with open(os.path.join(current_dir, "./testfile"),
+ "rb") as file:
stream = file.read(128)
times = []
--
2.33.1

View File

@ -0,0 +1,36 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, python
}:
buildPythonPackage rec {
pname = "fleep";
version = "1.0.1";
# Pypi version does not have tests
src = fetchFromGitHub {
owner = "floyernick";
repo = "fleep-py";
rev = "994bc2c274482d80ab13d89d8f7343eb316d3e44";
sha256 = "sha256-TaU7njx98nxkhZawGMFqWj4g+yCtIX9aPWQHoamzfMY=";
};
patches = [
./0001-Fixing-paths-on-tests.patch
];
checkPhase = ''
${python.interpreter} tests/maintest.py
${python.interpreter} tests/speedtest.py
'';
pythonImportsCheck = [ "fleep" ];
meta = with lib; {
description = "File format determination library";
homepage = "https://github.com/floyernick/fleep-py";
license = licenses.mit;
maintainers = with maintainers; [ wolfangaukang ];
};
}

View File

@ -8,7 +8,7 @@
buildPythonPackage rec {
pname = "graphql-subscription-manager";
version = "0.5.0";
version = "0.5.1";
disabled = pythonOlder "3.7";
@ -16,7 +16,7 @@ buildPythonPackage rec {
owner = "Danielhiversen";
repo = "PyGraphqlWebsocketManager";
rev = version;
sha256 = "sha256-18GR0OZeEh6EQT0kKCJyq7ckvKYKDJn/lugN5xlRg64=";
sha256 = "sha256-PVQa6JmBnToXuL/wNkYO0b+K1e9yrQgRUzWNUbFN5mM=";
};
propagatedBuildInputs = [

View File

@ -0,0 +1,64 @@
{ lib
, stdenv
, buildPythonPackage
, pythonOlder
, fetchFromGitHub
, substituteAll
, ffmpeg
, libopus
, aiohttp
, aiodns
, brotli
, cchardet
, orjson
, pynacl
}:
buildPythonPackage rec {
pname = "nextcord";
version = "2.0.0a8";
format = "setuptools";
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "nextcord";
repo = "nextcord";
rev = version;
hash = "sha256-aYFY58zWZlZwW3xwa1iAK4w29AofKIkTyCjQ2nR8JrY=";
};
patches = [
(substituteAll {
src = ./paths.patch;
ffmpeg = "${ffmpeg}/bin/ffmpeg";
libopus = "${libopus}/lib/libopus${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
propagatedBuildInputs = [
aiodns
aiohttp
brotli
cchardet
orjson
pynacl
];
# upstream has no tests
doCheck = false;
pythonImportsCheck = [
"nextcord"
"nextcord.ext.commands"
"nextcord.ext.tasks"
];
meta = with lib; {
description = "Python wrapper for the Discord API forked from discord.py";
homepage = "https://github.com/nextcord/nextcord";
license = licenses.mit;
maintainers = with maintainers; [ dotlambda ];
};
}

View File

@ -0,0 +1,26 @@
diff --git a/nextcord/opus.py b/nextcord/opus.py
index 97d437a3..755e1a5c 100644
--- a/nextcord/opus.py
+++ b/nextcord/opus.py
@@ -213,7 +213,7 @@ def _load_default() -> bool:
_filename = os.path.join(_basedir, 'bin', f'libopus-0.{_target}.dll')
_lib = libopus_loader(_filename)
else:
- _lib = libopus_loader(ctypes.util.find_library('opus'))
+ _lib = libopus_loader('@libopus@')
except Exception:
_lib = None
diff --git a/nextcord/player.py b/nextcord/player.py
index bedefc5a..34de0459 100644
--- a/nextcord/player.py
+++ b/nextcord/player.py
@@ -140,7 +140,7 @@ class FFmpegAudio(AudioSource):
.. versionadded:: 1.3
"""
- def __init__(self, source: Union[str, io.BufferedIOBase], *, executable: str = 'ffmpeg', args: Any, **subprocess_kwargs: Any):
+ def __init__(self, source: Union[str, io.BufferedIOBase], *, executable: str = '@ffmpeg@', args: Any, **subprocess_kwargs: Any):
piping = subprocess_kwargs.get('stdin') == subprocess.PIPE
if piping and isinstance(source, str):
raise TypeError("parameter conflict: 'source' parameter cannot be a string when piping to stdin")

View File

@ -3,16 +3,16 @@
stdenv.mkDerivation rec {
pname = "leiningen";
version = "2.9.7";
version = "2.9.8";
src = fetchurl {
url = "https://raw.github.com/technomancy/leiningen/${version}/bin/lein-pkg";
sha256 = "sha256-948g0ZMfAoJw53vA8MAKWg76Tst6VnYwSjSuT0aeKB0=";
sha256 = "1sgnxw58srjxqnskl700p7r7n23pfpjvqpiqnz1m8r6c76jwnllr";
};
jarsrc = fetchurl {
url = "https://github.com/technomancy/leiningen/releases/download/${version}/${pname}-${version}-standalone.jar";
sha256 = "sha256-gvAUFKzs3bsOvW1XFQW7Zxpv0JMja82sJGjP5fLqqAI=";
sha256 = "13f4n15i0gsk9jq52gxivnsk32qjahmxgrddm54cf8ynw0a923ia";
};
JARNAME = "${pname}-${version}-standalone.jar";

View File

@ -0,0 +1,32 @@
{ stdenv, lib, fetchurl, cabextract }:
stdenv.mkDerivation rec {
pname = "xow_dongle-firmware";
version = "2017-07";
dontUnpack = true;
dontInstall = true;
src = fetchurl {
url = "http://download.windowsupdate.com/c/msdownload/update/driver/drvs/2017/07/1cd6a87c-623f-4407-a52d-c31be49e925c_e19f60808bdcbfbd3c3df6be3e71ffc52e43261e.cab";
sha256 = "013g1zngxffavqrk5jy934q3bdhsv6z05ilfixdn8dj0zy26lwv5";
};
nativeBuildInputs = [ cabextract ];
buildPhase = ''
cabextract -F FW_ACC_00U.bin ${src}
mkdir -p $out/lib/firmware
cp -a FW_ACC_00U.bin $out/lib/firmware/xow_dongle.bin
'';
meta = with lib; {
description = "Xbox One wireless dongle firmware";
homepage = "https://www.xbox.com/en-NZ/accessories/adapters/wireless-adapter-windows";
license = licenses.unfree;
maintainers = with lib.maintainers; [ rhysmdnz ];
platforms = platforms.linux;
};
}

View File

@ -0,0 +1,39 @@
{ stdenv, lib, fetchFromGitHub, kernel, fetchurl }:
stdenv.mkDerivation rec {
name = "xone-${version}-${kernel.version}";
version = "0.2";
src = fetchFromGitHub {
owner = "medusalix";
repo = "xone";
rev = "v${version}";
sha256 = "sha256-m4305Xl5w4nyAVqubjwWsiyPDVtfGykjlSW2eKEytVk=";
};
setSourceRoot = ''
export sourceRoot=$(pwd)/source
'';
nativeBuildInputs = kernel.moduleBuildDependencies;
makeFlags = [
"-C"
"${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
"M=$(sourceRoot)"
"VERSION=${version}"
];
buildFlags = [ "modules" ];
installFlags = [ "INSTALL_MOD_PATH=${placeholder "out"}" ];
installTargets = [ "modules_install" ];
meta = with lib; {
description = "Linux kernel driver for Xbox One and Xbox Series X|S accessories";
homepage = "https://github.com/medusalix/xone";
license = licenses.gpl2;
maintainers = with lib.maintainers; [ rhysmdnz ];
platforms = platforms.linux;
};
}

View File

@ -3,12 +3,12 @@
stdenv.mkDerivation rec {
pname = "nncp";
version = "8.5.0";
version = "8.6.0";
outputs = [ "out" "doc" "info" ];
src = fetchurl {
url = "http://www.nncpgo.org/download/${pname}-${version}.tar.xz";
sha256 = "sha256-6IUNJ3DE+nRc+bmpDO7l1gXlD6UDGggTSYRMFT57v/Q=";
sha256 = "sha256-rhbwoJwbfR2jdn4cD0ENnCmsyuYypEipVdtKDxW/g48=";
};
nativeBuildInputs = [ go redo-apenwarr ];

View File

@ -0,0 +1,41 @@
{ lib
, buildPythonApplication
, fetchPypi
, fleep
, libarchive-c
, pillow
, requests-toolbelt
, setuptools
, zeroconf }:
buildPythonApplication rec {
pname = "opendrop";
version = "0.13.0";
src = fetchPypi {
inherit version pname;
sha256 = "sha256-FE1oGpL6C9iBhI8Zj71Pm9qkObJvSeU2gaBZwK1bTQc=";
};
propagatedBuildInputs = [
fleep
libarchive-c
pillow
requests-toolbelt
setuptools
zeroconf
];
# There are tests, but getting the following error:
# nix_run_setup: error: argument action: invalid choice: 'test' (choose from 'receive', 'find', 'send')
# Opendrop works as intended though
doCheck = false;
meta = with lib; {
description = "An open Apple AirDrop implementation written in Python";
homepage = "https://owlink.org/";
license = licenses.gpl3Only;
maintainers = with maintainers; [ wolfangaukang ];
platforms = [ "x86_64-linux" ];
};
}

View File

@ -0,0 +1,25 @@
{ stdenv, lib, fetchFromGitHub, cmake, libev, libnl, libpcap }:
stdenv.mkDerivation rec {
pname = "owl";
version = "unstable-2022-01-30";
src = fetchFromGitHub {
owner = "seemoo-lab";
repo = "owl";
rev = "8e4e840b212ae5a09a8a99484be3ab18bad22fa7";
sha256 = "sha256-kFk+JFLGWGBu5FPH3qp/Bxa6t04f1kpeHz3H8GNF3fg=";
fetchSubmodules = true;
};
nativeBuildInputs = [ cmake ];
buildInputs = [ libev libnl libpcap ];
meta = with lib; {
description = "An open Apple Wireless Direct Link (AWDL) implementation written in C";
homepage = "https://owlink.org/";
license = licenses.gpl3Only;
maintainers = with maintainers; [ wolfangaukang ];
platforms = [ "x86_64-linux" ];
};
}

View File

@ -549,6 +549,10 @@ with pkgs;
graph-easy = callPackage ../tools/graphics/graph-easy { };
opendrop = python3Packages.callPackage ../tools/networking/opendrop { };
owl = callPackage ../tools/networking/owl { };
packer = callPackage ../development/tools/packer { };
packr = callPackage ../development/libraries/packr { };
@ -18581,6 +18585,8 @@ with pkgs;
libptytty = callPackage ../development/libraries/libptytty { };
libpulsar = callPackage ../development/libraries/libpulsar { };
libpwquality = callPackage ../development/libraries/libpwquality { };
libqalculate = callPackage ../development/libraries/libqalculate {
@ -21492,6 +21498,7 @@ with pkgs;
openresty = callPackage ../servers/http/openresty {
withPerl = false;
modules = [];
};
opensmtpd = callPackage ../servers/mail/opensmtpd { };
@ -34201,6 +34208,8 @@ with pkgs;
xosview2 = callPackage ../tools/X11/xosview2 { };
xow_dongle-firmware = callPackage ../os-specific/linux/firmware/xow_dongle-firmware { };
xpad = callPackage ../applications/misc/xpad { };
xsane = callPackage ../applications/graphics/sane/xsane.nix {

View File

@ -462,6 +462,8 @@ in {
xmm7360-pci = callPackage ../os-specific/linux/xmm7360-pci { };
xone = if lib.versionAtLeast kernel.version "5.4" then callPackage ../os-specific/linux/xone { } else null;
xpadneo = callPackage ../os-specific/linux/xpadneo { };
zenpower = callPackage ../os-specific/linux/zenpower { };

View File

@ -3017,6 +3017,8 @@ in {
flax = callPackage ../development/python-modules/flax { };
fleep = callPackage ../development/python-modules/fleep { };
flexmock = callPackage ../development/python-modules/flexmock { };
flickrapi = callPackage ../development/python-modules/flickrapi { };
@ -5460,6 +5462,8 @@ in {
nextcloudmonitor = callPackage ../development/python-modules/nextcloudmonitor { };
nextcord = callPackage ../development/python-modules/nextcord { };
nghttp2 = (toPythonModule (pkgs.nghttp2.override {
inherit (self) python cython setuptools;
inherit (pkgs) ncurses;