Merge master into staging-next

This commit is contained in:
github-actions[bot] 2022-01-19 18:01:22 +00:00 committed by GitHub
commit 9e9e41da09
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
28 changed files with 449 additions and 199 deletions

View File

@ -7170,6 +7170,12 @@
githubId = 13791;
name = "Luke Gorrie";
};
luker = {
email = "luker@fenrirproject.org";
github = "LucaFulchir";
githubId = 2486026;
name = "Luca Fulchir";
};
lumi = {
email = "lumi@pew.im";
github = "lumi-me-not";
@ -11126,6 +11132,12 @@
fingerprint = "4242 834C D401 86EF 8281 4093 86E3 0E5A 0F5F C59C";
}];
};
smasher164 = {
email = "aindurti@gmail.com";
github = "smasher164";
githubId = 12636891;
name = "Akhil Indurti";
};
smironov = {
email = "grrwlf@gmail.com";
github = "grwlf";

View File

@ -136,7 +136,7 @@ let
+ concatStringsSep "\n"
(plainLines
++ optional (plainLines != []) ''
${pkgs.mosquitto}/bin/mosquitto_passwd -U "$file"
${cfg.package}/bin/mosquitto_passwd -U "$file"
''
++ hashedLines));
@ -444,6 +444,15 @@ let
globalOptions = with types; {
enable = mkEnableOption "the MQTT Mosquitto broker";
package = mkOption {
type = package;
default = pkgs.mosquitto;
defaultText = literalExpression "pkgs.mosquitto";
description = ''
Mosquitto package to use.
'';
};
bridges = mkOption {
type = attrsOf bridgeOptions;
default = {};
@ -565,7 +574,7 @@ in
RuntimeDirectory = "mosquitto";
WorkingDirectory = cfg.dataDir;
Restart = "on-failure";
ExecStart = "${pkgs.mosquitto}/bin/mosquitto -c ${configFile}";
ExecStart = "${cfg.package}/bin/mosquitto -c ${configFile}";
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
# Hardening

View File

@ -136,7 +136,7 @@ in
# session requirements
cinnamon-screensaver
# cinnamon-killer-daemon: provided by cinnamon-common
gnome.networkmanagerapplet # session requirement - also nm-applet not needed
networkmanagerapplet # session requirement - also nm-applet not needed
# For a polkit authentication agent
polkit_gnome
@ -145,7 +145,7 @@ in
nemo
cinnamon-control-center
cinnamon-settings-daemon
gnome.libgnomekbd
libgnomekbd
orca
# theme

View File

@ -14,7 +14,7 @@ import ../make-test-python.nix {
)
# Start the daemon and wait until it is ready
machine.execute("lorri daemon > lorri.stdout 2> lorri.stderr >&2 &")
machine.execute("lorri daemon > lorri.stdout 2> lorri.stderr &")
machine.wait_until_succeeds("grep --fixed-strings 'ready' lorri.stdout")
# Ping the daemon

View File

@ -2,12 +2,12 @@
let
pname = "plexamp";
version = "3.9.0";
version = "3.9.1";
src = fetchurl {
url = "https://plexamp.plex.tv/plexamp.plex.tv/desktop/Plexamp-${version}.AppImage";
name="${pname}-${version}.AppImage";
sha512 = "2OaV8dONv7yBcQsfecgfedP2ypBN6svD9rgZLgUwSydyH2+rODNPne4O7z2Hahm7Y0Ae+NFxbpQ9lbNbX0vhsg==";
sha512 = "uassNLdCXx3WLarUMJNhU8fbXugG7yTLMQacPAszLoRdmbMwcN6wT7ED26VhlNVhY3xr02GjZSDw4/LADZWqKw==";
};
appimageContents = appimageTools.extractType2 {
@ -33,7 +33,7 @@ in appimageTools.wrapType2 {
meta = with lib; {
description = "A beautiful Plex music player for audiophiles, curators, and hipsters";
homepage = "https://plexamp.com/";
changelog = "https://forums.plex.tv/t/plexamp-release-notes/221280/36";
changelog = "https://forums.plex.tv/t/plexamp-release-notes/221280/37";
license = licenses.unfree;
maintainers = with maintainers; [ killercup synthetica ];
platforms = [ "x86_64-linux" ];

View File

@ -0,0 +1,34 @@
diff --git a/signalbackup/setfiletimestamp.cc b/signalbackup/setfiletimestamp.cc
index f53a168..d2d1c5e 100644
--- a/signalbackup/setfiletimestamp.cc
+++ b/signalbackup/setfiletimestamp.cc
@@ -21,24 +21,23 @@
#if !defined(_WIN32) && !defined(__MINGW64__)
-#include <fcntl.h>
-#include <sys/stat.h>
+#include <sys/time.h>
bool SignalBackup::setFileTimeStamp(std::string const &file, long long int time_usec) const
{
- struct timespec ntimes[] =
+ struct timeval ntimes[] =
{
{ // ntimes[0] =
time_usec / 1000, // tv_sec, seconds
- (time_usec % 1000) * 1000 // tv_usec, nanoseconds
+ static_cast<int>(time_usec) // tv_usec, nanoseconds
},
{ // ntimes[1] =
time_usec / 1000, // tv_sec, seconds
- (time_usec % 1000) * 1000 // tv_usec, nanoseconds
+ static_cast<int>(time_usec) // tv_usec, nanoseconds
}
};
- return (utimensat(AT_FDCWD, file.c_str(), ntimes, 0) == 0);
+ return (utimes(file.c_str(), ntimes) == 0);
}
#else // this is poorly tested, I don't have windows

View File

@ -0,0 +1,45 @@
{ lib, stdenv, fetchFromGitHub, openssl, sqlite }:
stdenv.mkDerivation rec {
pname = "signalbackup-tools";
version = "20220107";
src = fetchFromGitHub {
owner = "bepaald";
repo = pname;
rev = version;
sha256 = "sha256-sB8/xQgSORtwupcwSejKUhHoz04exdYS0ymefw9wXDQ=";
};
# Remove when Apple SDK is >= 10.13
patches = lib.optional (stdenv.system == "x86_64-darwin") ./apple-sdk-missing-utimensat.patch;
buildInputs = [ openssl sqlite ];
buildFlags = [
"-Wall"
"-Wextra"
"-Wshadow"
"-Wold-style-cast"
"-Woverloaded-virtual"
"-pedantic"
"-std=c++2a"
"-O3"
"-march=native"
];
buildPhase = ''
$CXX $buildFlags */*.cc *.cc -lcrypto -lsqlite3 -o signalbackup-tools
'';
installPhase = ''
mkdir -p $out/bin
cp signalbackup-tools $out/bin/
'';
meta = with lib; {
description = "Tool to work with Signal Backup files";
homepage = "https://github.com/bepaald/signalbackup-tools";
license = licenses.gpl3Only;
maintainers = [ maintainers.malo ];
platforms = platforms.all;
};
}

View File

@ -1,167 +1,172 @@
{ lib, stdenv
, coreutils
, patchelf
, requireFile
, callPackage
{ lib
, stdenv
, autoPatchelfHook
, buildEnv
, makeWrapper
, requireFile
, alsa-lib
, cups
, dbus
, flite
, fontconfig
, freetype
, gcc
, gcc-unwrapped
, glib
, libssh2
, gmpxx
, keyutils
, libGL
, libGLU
, libpcap
, libtins
, libuuid
, libxkbcommon
, libxml2
, llvmPackages_12
, matio
, mpfr
, ncurses
, opencv4
, openjdk11
, openssl
, pciutils
, tre
, unixODBC
, xkeyboard_config
, xorg
, zlib
, libxml2
, libuuid
, lang ? "en"
, libGL
, libGLU
}:
let
l10n =
import ./l10ns.nix {
lib = lib;
inherit requireFile lang;
};
in
stdenv.mkDerivation rec {
l10n = import ./l10ns.nix {
inherit lib requireFile lang;
};
in stdenv.mkDerivation {
inherit (l10n) version name src;
buildInputs = [
coreutils
patchelf
nativeBuildInputs = [
autoPatchelfHook
makeWrapper
];
buildInputs = [
alsa-lib
coreutils
cups.lib
dbus
flite
fontconfig
freetype
gcc.cc
gcc.libc
glib
libssh2
ncurses
opencv4
openssl
stdenv.cc.cc.lib
unixODBC
xkeyboard_config
libxml2
libuuid
zlib
gmpxx
keyutils.lib
libGL
libGLU
libpcap
libtins
libuuid
libxkbcommon
libxml2
llvmPackages_12.libllvm.lib
matio
mpfr
ncurses
opencv4
openjdk11
openssl
pciutils
tre
unixODBC
xkeyboard_config
] ++ (with xorg; [
libX11
libXext
libXtst
libXi
libXmu
libXrender
libxcb
libXcursor
libXfixes
libXrandr
libICE
libSM
libX11
libXScrnSaver
libXcomposite
libXcursor
libXdamage
libXext
libXfixes
libXi
libXinerama
libXmu
libXrandr
libXrender
libXtst
libxcb
]);
ldpath = lib.makeLibraryPath buildInputs
+ lib.optionalString (stdenv.hostPlatform.system == "x86_64-linux")
(":" + lib.makeSearchPathOutput "lib" "lib64" buildInputs);
wrapProgramFlags = [
"--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ gcc-unwrapped.lib zlib ]}"
"--prefix PATH : ${lib.makeBinPath [ stdenv.cc ]}"
# Fix libQt errors - #96490
"--set USE_WOLFRAM_LD_LIBRARY_PATH 1"
# Fix xkeyboard config path for Qt
"--set QT_XKB_CONFIG_ROOT ${xkeyboard_config}/share/X11/xkb"
];
unpackPhase = ''
echo "=== Extracting makeself archive ==="
# find offset from file
runHook preUnpack
# Find offset from file
offset=$(${stdenv.shell} -c "$(grep -axm1 -e 'offset=.*' $src); echo \$offset" $src)
dd if="$src" ibs=$offset skip=1 | tar -xf -
cd Unix
tail -c +$(($offset + 1)) $src | tar -xf -
runHook postUnpack
'';
installPhase = ''
cd Installer
# don't restrict PATH, that has already been done
sed -i -e 's/^PATH=/# PATH=/' MathInstaller
runHook preInstall
# Fix the installation script as follows:
# 1. Adjust the shebang
# 2. Use the wrapper in the desktop items
cd "$TMPDIR/Unix/Installer"
mkdir -p "$out/lib/udev/rules.d"
# Patch MathInstaller's shebangs and udev rules dir
patchShebangs MathInstaller
substituteInPlace MathInstaller \
--replace "/bin/bash" "/bin/sh" \
--replace "Executables/Mathematica" "../../bin/mathematica"
--replace /etc/udev/rules.d $out/lib/udev/rules.d
# Install the desktop items
export XDG_DATA_HOME="$out/share"
# Remove PATH restriction, root and avahi daemon checks, and hostname call
sed -i '
s/^PATH=/# &/
s/isRoot="false"/# &/
s/^checkAvahiDaemon$/# &/
s/`hostname`/""/
' MathInstaller
echo "=== Running MathInstaller ==="
./MathInstaller -auto -createdir=y -execdir=$out/bin -targetdir=$out/libexec/Mathematica -silent
# NOTE: some files placed under HOME may be useful
XDG_DATA_HOME="$out/share" HOME="$TMPDIR/home" vernierLink=y \
./MathInstaller -execdir="$out/bin" -targetdir="$out/libexec/Mathematica" -auto -verbose -createdir=y
# Fix library paths
cd $out/libexec/Mathematica/Executables
for path in mathematica MathKernel Mathematica WolframKernel wolfram math; do
sed -i -e "2iexport LD_LIBRARY_PATH=${zlib}/lib:${stdenv.cc.cc.lib}/lib:${libssh2}/lib:\''${LD_LIBRARY_PATH}\n" $path
done
# Check if MathInstaller produced any errors
errLog="$out/libexec/Mathematica/InstallErrors"
if [ -f "$errLog" ]; then
echo "Installation errors:"
cat "$errLog"
return 1
fi
# Fix xkeyboard config path for Qt
for path in mathematica Mathematica; do
sed -i -e "2iexport QT_XKB_CONFIG_ROOT=\"${xkeyboard_config}/share/X11/xkb\"\n" $path
done
# Remove some broken libraries
rm -f $out/libexec/Mathematica/SystemFiles/Libraries/Linux-x86-64/libz.so*
# Set environment variable to fix libQt errors - see https://github.com/NixOS/nixpkgs/issues/96490
wrapProgram $out/bin/mathematica --set USE_WOLFRAM_LD_LIBRARY_PATH 1
runHook postInstall
'';
preFixup = ''
echo "=== PatchElfing away ==="
# This code should be a bit forgiving of errors, unfortunately
set +e
find $out/libexec/Mathematica/SystemFiles -type f -perm -0100 | while read f; do
type=$(readelf -h "$f" 2>/dev/null | grep 'Type:' | sed -e 's/ *Type: *\([A-Z]*\) (.*/\1/')
if [ -z "$type" ]; then
:
elif [ "$type" == "EXEC" ]; then
echo "patching $f executable <<"
patchelf --shrink-rpath "$f"
patchelf \
--set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" \
--set-rpath "$(patchelf --print-rpath "$f"):${ldpath}" \
"$f" \
&& patchelf --shrink-rpath "$f" \
|| echo unable to patch ... ignoring 1>&2
elif [ "$type" == "DYN" ]; then
echo "patching $f library <<"
patchelf \
--set-rpath "$(patchelf --print-rpath "$f"):${ldpath}" \
"$f" \
&& patchelf --shrink-rpath "$f" \
|| echo unable to patch ... ignoring 1>&2
else
echo "not patching $f <<: unknown elf type"
fi
for bin in $out/libexec/Mathematica/Executables/*; do
wrapProgram "$bin" ''${wrapProgramFlags[@]}
done
'';
dontConfigure = true;
dontBuild = true;
# This is primarily an IO bound build; there's little benefit to building remotely.
# This is primarily an IO bound build; there's little benefit to building remotely
preferLocalBuild = true;
# all binaries are already stripped
# All binaries are already stripped
dontStrip = true;
# we did this in prefixup already
dontPatchELF = true;
# NOTE: Some deps are still not found; ignore for now
autoPatchelfIgnoreMissingDeps = true;
meta = with lib; {
description = "Wolfram Mathematica computational software system";

View File

@ -13,14 +13,14 @@
rustPlatform.buildRustPackage rec {
pname = "pijul";
version = "1.0.0-alpha.57";
version = "1.0.0-beta";
src = fetchCrate {
inherit version pname;
sha256 = "sha256-HhGUoO8UHJkfQ5QQ/H+PT8mqvdPb8Ok4D3j7QArLBeA=";
sha256 = "sha256-s7fHg6Le4y0yAyxOQf6iUUHA4dYsamlTUb0KISOHI7Q=";
};
cargoSha256 = "sha256-SyyJqUC7bCUJf53/+GJ/7+huab8hycNABwAFaHHmJtY=";
cargoSha256 = "sha256-09PWy1yfr1FY2AsKaoZZswi4P5JdNcumIOmTm+M21UE=";
doCheck = false;
nativeBuildInputs = [ pkg-config ];

View File

@ -10,7 +10,8 @@ die() {
usage() {
echo "Usage: $scriptName <attr> <version> [<new-source-hash>] [<new-source-url>]"
echo " [--version-key=<version-key>] [--system=<system>] [--file=<file-to-update>] [--rev=<revision>]"
echo " [--version-key=<version-key>] [--source-key=<source-key>]"
echo " [--system=<system>] [--file=<file-to-update>] [--rev=<revision>]"
echo " [--ignore-same-hash] [--print-changes]"
}
@ -25,6 +26,9 @@ for arg in "$@"; do
--version-key=*)
versionKey="${arg#*=}"
;;
--source-key=*)
sourceKey="${arg#*=}"
;;
--file=*)
nixFile="${arg#*=}"
if [[ ! -f "$nixFile" ]]; then
@ -79,6 +83,10 @@ if [[ -z "$versionKey" ]]; then
versionKey=version
fi
if [[ -z "$sourceKey" ]]; then
sourceKey=src
fi
# Allow finding packages among flake outputs in repos using flake-compat.
pname=$(nix-instantiate $systemArg --eval --strict -A "$attr.name" || echo)
if [[ -z "$pname" ]]; then
@ -106,7 +114,7 @@ if [[ -z "$nixFile" ]]; then
fi
# flake-compat will return paths in the Nix store, we need to correct for that.
possiblyOutPath=$(nix-instantiate $systemArg --eval -E "with $importTree; outPath" | tr -d '"')
possiblyOutPath=$(nix-instantiate $systemArg --eval -E "with $importTree; outPath" 2>/dev/null | tr -d '"')
if [[ -n "$possiblyOutPath" ]]; then
outPathEscaped=$(echo "$possiblyOutPath" | sed 's#[$^*\\.[|]#\\&#g')
pwdEscaped=$(echo "$PWD" | sed 's#[$^*\\.[|]#\\&#g')
@ -114,21 +122,21 @@ if [[ -z "$nixFile" ]]; then
fi
fi
oldHashAlgo=$(nix-instantiate $systemArg --eval --strict -A "$attr.src.drvAttrs.outputHashAlgo" | tr -d '"')
oldHash=$(nix-instantiate $systemArg --eval --strict -A "$attr.src.drvAttrs.outputHash" | tr -d '"')
oldHashAlgo=$(nix-instantiate $systemArg --eval --strict -A "$attr.$sourceKey.drvAttrs.outputHashAlgo" | tr -d '"')
oldHash=$(nix-instantiate $systemArg --eval --strict -A "$attr.$sourceKey.drvAttrs.outputHash" | tr -d '"')
if [[ -z "$oldHashAlgo" || -z "$oldHash" ]]; then
die "Couldn't evaluate old source hash from '$attr.src'!"
die "Couldn't evaluate old source hash from '$attr.$sourceKey'!"
fi
if [[ $(grep --count "$oldHash" "$nixFile") != 1 ]]; then
die "Couldn't locate old source hash '$oldHash' (or it appeared more than once) in '$nixFile'!"
fi
oldUrl=$(nix-instantiate $systemArg --eval -E "with $importTree; builtins.elemAt ($attr.src.drvAttrs.urls or [ $attr.src.url ]) 0" | tr -d '"')
oldUrl=$(nix-instantiate $systemArg --eval -E "with $importTree; builtins.elemAt ($attr.$sourceKey.drvAttrs.urls or [ $attr.$sourceKey.url ]) 0" | tr -d '"')
if [[ -z "$oldUrl" ]]; then
die "Couldn't evaluate source url from '$attr.src'!"
die "Couldn't evaluate source url from '$attr.$sourceKey'!"
fi
oldVersion=$(nix-instantiate $systemArg --eval -E "with $importTree; $attr.${versionKey} or (builtins.parseDrvName $attr.name).version" | tr -d '"')
@ -146,9 +154,9 @@ if [[ "$oldVersion" = "$newVersion" ]]; then
fi
if [[ -n "$newRevision" ]]; then
oldRevision=$(nix-instantiate $systemArg --eval -E "with $importTree; $attr.src.rev" | tr -d '"')
oldRevision=$(nix-instantiate $systemArg --eval -E "with $importTree; $attr.$sourceKey.rev" | tr -d '"')
if [[ -z "$oldRevision" ]]; then
die "Couldn't evaluate source revision from '$attr.src'!"
die "Couldn't evaluate source revision from '$attr.$sourceKey'!"
fi
fi
@ -228,7 +236,7 @@ fi
# If new hash not given on the command line, recalculate it ourselves.
if [[ -z "$newHash" ]]; then
nix-build $systemArg --no-out-link -A "$attr.src" 2>"$attr.fetchlog" >/dev/null || true
nix-build $systemArg --no-out-link -A "$attr.$sourceKey" 2>"$attr.fetchlog" >/dev/null || true
# FIXME: use nix-build --hash here once https://github.com/NixOS/nix/issues/1172 is fixed
newHash=$(sed '1,/hash mismatch in fixed-output derivation/d' "$attr.fetchlog" | grep --perl-regexp --only-matching 'got: +.+[:-]\K.+')
@ -242,12 +250,12 @@ fi
if [[ -z "$newHash" ]]; then
cat "$attr.fetchlog" >&2
die "Couldn't figure out new hash of '$attr.src'!"
die "Couldn't figure out new hash of '$attr.$sourceKey'!"
fi
if [[ -z "${ignoreSameHash}" && "$oldVersion" != "$newVersion" && "$oldHash" = "$newHash" ]]; then
mv "$nixFile.bak" "$nixFile"
die "Both the old and new source hashes of '$attr.src' were equivalent. Please fix the package's source URL to be dependent on '\${version}'!"
die "Both the old and new source hashes of '$attr.$sourceKey' were equivalent. Please fix the package's source URL to be dependent on '\${version}'!"
fi
sed -i "$nixFile" -re "s|\"$tempHashEscaped\"|\"$newHash\"|"

View File

@ -24,7 +24,7 @@
stdenv.mkDerivation rec {
pname = "nemo";
version = "5.2.0";
version = "5.2.3";
# TODO: add plugins support (see https://github.com/NixOS/nixpkgs/issues/78327)
@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
owner = "linuxmint";
repo = pname;
rev = version;
hash = "sha256-ehcqRlI1d/KWNas36dz+hb7KU1H8wtQHTpg2fz1XdXU=";
sha256 = "sha256-kPxwWciNf4KQx3JG1qPQcZJeOa4B+udMyQmH8A7JcfQ=";
};
outputs = [ "out" "dev" ];

View File

@ -0,0 +1,24 @@
{ lib, buildGoModule, fetchFromGitHub }:
buildGoModule rec {
pname = "ivy";
version = "0.1.13";
src = fetchFromGitHub {
rev = "v${version}";
owner = "robpike";
repo = "ivy";
sha256 = "sha256-IiQrmmHitKUItm/ZSTQ3jGO3ls8vPPexyOtUvfq3yeU=";
};
vendorSha256 = "sha256-pQpattmS9VmO3ZIQUFn66az8GSmB4IvYhTTCFn6SUmo=";
subPackages = [ "." ];
meta = with lib; {
homepage = "https://github.com/robpike/ivy";
description = "ivy, an APL-like calculator";
license = licenses.bsd3;
maintainers = with maintainers; [ smasher164 ];
};
}

View File

@ -19,13 +19,13 @@
stdenv.mkDerivation rec {
pname = "umockdev";
version = "0.17.2";
version = "0.17.5";
outputs = [ "bin" "out" "dev" "devdoc" ];
src = fetchurl {
url = "https://github.com/martinpitt/umockdev/releases/download/${version}/${pname}-${version}.tar.xz";
sha256 = "sha256-D9Kb67HACi8guMoT5n3Yp9INigjuuGAIyKMgcICBJmA=";
sha256 = "sha256-9mNKYFiQtzkBTQEuVWIfR9+e2jAqDszlHGMEQpcRe8U=";
};
nativeBuildInputs = [

View File

@ -0,0 +1,33 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, requests
}:
buildPythonPackage rec {
pname = "pynut2";
version = "2.1.2";
src = fetchFromGitHub {
owner = "mezz64";
repo = "python-nut2";
rev = version;
sha256 = "1lg7n1frndfgw73s0ssl1h7kc6zxm7fpiwlc6v6d60kxzaj1dphx";
};
propagatedBuildInputs = [
requests
];
pythonImportsCheck = [ "pynut2.nut2" ];
# tests are unmaintained and broken
doCheck = false;
meta = with lib; {
description = "API overhaul of PyNUT, a Python library to allow communication with NUT (Network UPS Tools) servers.";
homepage = "https://github.com/mezz64/python-nut2";
license = with licenses; [ gpl3Plus ];
maintainers = [ maintainers.luker ];
};
}

View File

@ -26,7 +26,7 @@
, file, libvirt, glib, vips, taglib, libopus, linux-pam, libidn, protobuf, fribidi, harfbuzz
, bison, flex, pango, python3, patchelf, binutils, freetds, wrapGAppsHook, atk
, bundler, libsass, libexif, libselinux, libsepol, shared-mime-info, libthai, libdatrie
, CoreServices, DarwinTools, cctools, libtool
, CoreServices, DarwinTools, cctools, libtool, discount
}@args:
let
@ -135,6 +135,17 @@ in
hardeningDisable = [ "format" ];
};
rdiscount = attrs: {
# Use discount from nixpkgs instead of vendored version
dontBuild = false;
buildInputs = [ discount ];
patches = [
# Adapted from Debian:
# https://sources.debian.org/data/main/r/ruby-rdiscount/2.1.8-1/debian/patches/01_use-system-libmarkdown.patch
./rdiscount-use-nixpkgs-libmarkdown.patch
];
};
ethon = attrs: {
dontBuild = false;
postPatch = ''

View File

@ -0,0 +1,14 @@
diff --git a/ext/extconf.rb b/ext/extconf.rb
index 30764cb..b87ac2b 100644
--- a/ext/extconf.rb
+++ b/ext/extconf.rb
@@ -46,4 +46,9 @@ if /mswin/.match RbConfig::CONFIG['host_os']
$defs.push("-Dinline=__inline")
end
+$srcs = %w[
+ rdiscount.c
+]
+have_library('markdown')
+
create_makefile('rdiscount')

View File

@ -1,4 +1,4 @@
{ stdenv, lib, bundlerEnv, bundlerUpdateScript, makeWrapper, groff }:
{ stdenv, lib, bundlerEnv, bundlerUpdateScript, makeWrapper, groff, callPackage }:
stdenv.mkDerivation rec {
pname = "ronn";
@ -21,6 +21,8 @@ stdenv.mkDerivation rec {
passthru.updateScript = bundlerUpdateScript "ronn";
passthru.tests.reproducible-html-manpage = callPackage ./test-reproducible-html.nix { };
meta = with lib; {
description = "markdown-based tool for building manpages";
homepage = "https://rtomayko.github.io/ronn/";

View File

@ -0,0 +1,30 @@
{ runCommand
, diffutils
, ronn
}:
runCommand "ronn-test-reproducible-html" { } ''
set -euo pipefail
cat > aprog.1.ronn << EOF
aprog
=====
## AUTHORS
Vincent Haupert <veehaitch@users.noreply.github.com>
EOF
# We have to repeat the manpage generation a few times to be confident
# it is in fact reproducible.
for i in {1..20}; do
${ronn}/bin/ronn --html --pipe aprog.1.ronn > aprog.1.html-1
${ronn}/bin/ronn --html --pipe aprog.1.ronn > aprog.1.html-2
${diffutils}/bin/diff -q aprog.1.html-1 aprog.1.html-2 \
|| (printf 'The HTML manpage is not reproducible (round %d)' "$i" && exit 1)
done
echo 'The HTML manpage appears reproducible'
mkdir $out
''

View File

@ -2,14 +2,14 @@
rustPlatform.buildRustPackage rec {
pname = "svd2rust";
version = "0.19.0";
version = "0.21.0";
src = fetchCrate {
inherit pname version;
sha256 = "sha256-LNJd88Gw8HaE1qnRbD7mipVEFgG7jCsyUu9pbwY/4JY=";
sha256 = "0mxzbbxrg1jysxpjqcvgwwmh8qf0lyf64fl1gxxp0whph0x279qj";
};
cargoSha256 = "sha256-Qg/wA3R98FAb8UZ5s7GOEgOeifrqwFJ4lg0BC2SZOE8=";
cargoSha256 = "0kvya6swx1nsxxlhn2w8x4dhl4j3v56jxqr2h259cx6lzv3xjhin";
buildInputs = lib.optional stdenv.isDarwin libiconv;

View File

@ -589,7 +589,7 @@
"nuki" = ps: with ps; [ pynuki ];
"numato" = ps: with ps; [ ]; # missing inputs: numato-gpio
"number" = ps: with ps; [ ];
"nut" = ps: with ps; [ ]; # missing inputs: pynut2
"nut" = ps: with ps; [ pynut2 ];
"nws" = ps: with ps; [ pynws ];
"nx584" = ps: with ps; [ pynx584 ];
"nzbget" = ps: with ps; [ ]; # missing inputs: pynzbgetapi
@ -1348,6 +1348,7 @@
"nsw_rural_fire_service_feed"
"nuki"
"number"
"nut"
"nws"
"nx584"
"octoprint"

View File

@ -1,10 +1,8 @@
{ lib
, mkDerivation
, fetchurl
, fetchpatch
, variant ? "standalone"
, fetchFromGitHub
, fetchFromGitLab
, cmake
, pkg-config
, opencv3
@ -20,6 +18,12 @@
, gimp ? null
, qtbase
, qttools
, writeShellScript
, common-updater-scripts
, gnugrep
, gnused
, coreutils
, jq
}:
let
@ -52,61 +56,42 @@ assert lib.assertMsg (builtins.all (d: d != null) variants.${variant}.extraDeps
mkDerivation rec {
pname = "gmic-qt${lib.optionalString (variant != "standalone") "-${variant}"}";
version = "2.7.1";
version = "3.0.0";
gmic-community = fetchFromGitHub {
owner = "dtschump";
repo = "gmic-community";
rev = "3fd528f20a2a7d651e96078c205ff21efb9cdd1a";
sha256 = "08d37b49qgh5d4rds7hvr5wjj4p1y8cnbidz1cyqsibq0555pwq2";
rev = "df23b08bc52767762f0e38d040cd8ffeea4b865e";
sha256 = "euk5RsFPBgx2czAukPRdi/O4ahgXO8J8VJdiGHNge5M=";
};
CImg = fetchFromGitLab {
domain = "framagit.org";
CImg = fetchFromGitHub {
owner = "dtschump";
repo = "CImg";
rev = "v.${version}";
sha256 = "1mfkjvf5r3ppc1dd6yvqn7xlhgzfg9k1k5v2sq2k9m70g8p7rgpd";
sha256 = "dC4VuWTz0uyFxLjBQ+2ggndHaCErcoI7tJMfkqbWmeg=";
};
gmic_stdlib = fetchurl {
name = "gmic_stdlib.h";
url = "http://gmic.eu/gmic_stdlib${lib.replaceStrings ["."] [""] version}.h";
sha256 = "0v12smknr1s44s6wq2gbnw0hb98xrwp6i3zg9wf49cl7s9qf76j3";
sha256 = "CAYSxw5NCmE29hie1/J1csBcdQvIrmZ/+mNMl0sLLGI=";
};
gmic = fetchFromGitHub {
owner = "dtschump";
repo = "gmic";
rev = "v.${version}";
sha256 = "0pa6kflr1gqgzh8rk7bylvkxs989r5jy0q7b62mnzx8895slwfb5";
sha256 = "PyeJmjOqjbHlZ1Xl3IpoOD6oZEcUrHNHqF7Ft1RZDL4=";
};
gmic_qt = fetchFromGitHub {
owner = "c-koi";
repo = "gmic-qt";
rev = "v.${version}";
sha256 = "08a0660083wv5fb1w9qqhm4f8cfwbqq723qzqq647mid1n7sy959";
sha256 = "nENXumOArRAHENqnBUjM7m+I5hf/WAFTVfm6cJgnv+0=";
};
patches = [
# Install GIMP plug-in to a correct destination
# https://github.com/c-koi/gmic-qt/pull/78
./fix-gimp-plugin-path.patch
];
unpackPhase = ''
cp -r ${gmic} gmic
ln -s ${gmic-community} gmic-community
cp -r ${gmic_qt} gmic_qt
chmod -R +w gmic gmic_qt
ln -s ${CImg} CImg
cp ${gmic_stdlib} gmic/src/gmic_stdlib.h
cd gmic_qt
'';
nativeBuildInputs = [
cmake
pkg-config
@ -130,15 +115,54 @@ mkDerivation rec {
"-DGMIC_QT_HOST=${if variant == "standalone" then "none" else variant}"
];
postFixup = lib.optionalString (variant == "gimp") ''
echo "wrapping $out/${gimp.targetPluginDir}/gmic_gimp_qt"
wrapQtApp "$out/${gimp.targetPluginDir}/gmic_gimp_qt"
unpackPhase = ''
cp -r ${gmic} gmic
ln -s ${gmic-community} gmic-community
cp -r ${gmic_qt} gmic_qt
chmod -R +w gmic gmic_qt
ln -s ${CImg} CImg
cp ${gmic_stdlib} gmic/src/gmic_stdlib.h
cd gmic_qt
'';
postFixup = lib.optionalString (variant == "gimp") ''
echo "wrapping $out/${gimp.targetPluginDir}/gmic_gimp_qt/gmic_gimp_qt"
wrapQtApp "$out/${gimp.targetPluginDir}/gmic_gimp_qt/gmic_gimp_qt"
'';
passthru = {
updateScript = writeShellScript "${pname}-update-script" ''
set -o errexit
PATH=${lib.makeBinPath [ common-updater-scripts curl gnugrep gnused coreutils jq ]}
latestVersion=$(curl 'https://gmic.eu/files/source/' | grep -E 'gmic_[^"]+\.tar\.gz' | sed -E 's/.+<a href="gmic_([^"]+)\.tar\.gz".+/\1/g' | sort --numeric-sort --reverse | head -n1)
if [[ "${version}" = "$latestVersion" ]]; then
echo "The new version same as the old version."
exit 0
fi
# gmic-community is not versioned so lets just update to master.
communityLatestCommit=$(curl "https://api.github.com/repos/dtschump/gmic-community/commits/master")
communityLatestSha=$(echo "$communityLatestCommit" | jq .sha --raw-output)
communityLatestDate=$(echo "$communityLatestCommit" | jq .commit.committer.date --raw-output | sed 's/T.\+//')
update-source-version --source-key=gmic-community "gmic-qt" "unstable-$communityLatestDate" --rev="$communityLatestSha"
for component in CImg gmic_stdlib gmic gmic_qt; do
# The script will not perform an update when the version attribute is up to date from previous platform run
# We need to clear it before each run
update-source-version "--source-key=$component" "gmic-qt" 0 "$(printf '0%.0s' {1..64})"
update-source-version "--source-key=$component" "gmic-qt" $latestVersion
done
'';
};
meta = with lib; {
description = variants.${variant}.description;
homepage = "http://gmic.eu/";
license = licenses.gpl3;
license = licenses.gpl3Plus;
platforms = platforms.unix;
};
}

View File

@ -1,21 +0,0 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 1483056..26d2b9a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -473,6 +473,7 @@
execute_process(COMMAND gimptool-2.0 --libs-noui OUTPUT_VARIABLE GIMP2_LIBRARIES OUTPUT_STRIP_TRAILING_WHITESPACE)
execute_process(COMMAND gimptool-2.0 --cflags-noui OUTPUT_VARIABLE GIMP2_INCLUDE_DIRS OUTPUT_STRIP_TRAILING_WHITESPACE)
+ execute_process(COMMAND pkg-config gimp-2.0 --define-variable=prefix=${CMAKE_INSTALL_PREFIX} --variable gimplibdir OUTPUT_VARIABLE GIMP2_PKGLIBDIR OUTPUT_STRIP_TRAILING_WHITESPACE)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${GIMP2_INCLUDE_DIRS}")
set (gmic_qt_SRCS ${gmic_qt_SRCS} src/Host/Gimp/host_gimp.cpp)
@@ -484,7 +485,7 @@
${GIMP2_LIBRARIES}
${gmic_qt_LIBRARIES}
)
- install(TARGETS gmic_gimp_qt RUNTIME DESTINATION bin)
+ install(TARGETS gmic_gimp_qt RUNTIME DESTINATION "${GIMP2_PKGLIBDIR}/plug-ins")
elseif (${GMIC_QT_HOST} STREQUAL "krita")

View File

@ -6,13 +6,13 @@
stdenv.mkDerivation rec {
pname = "pipectl";
version = "0.2.2";
version = "0.3.0";
src = fetchFromGitHub {
owner = "Ferdi265";
repo = pname;
rev = "v${version}";
hash = "sha256-wa/SKKNXkl8XxE7XORodoAlrMc2QNGXGPE+/yya209Y=";
hash = "sha256-+o5hIDtDAh4r+AKCUhueQ3GBYf2sZtMATGX73Qg+tbo=";
};
nativeBuildInputs = [ cmake ];

View File

@ -26,11 +26,17 @@ stdenv.mkDerivation rec {
"--pkg-config"
"--shared"
"--with-fenced-code"
# Use deterministic mangling
"--debian-glitch"
];
enableParallelBuilding = true;
doCheck = true;
postFixup = lib.optionalString stdenv.isDarwin ''
install_name_tool -id $out/lib/libmarkdown.dylib $out/lib/libmarkdown.dylib
'';
meta = with lib; {
description = "Implementation of Markdown markup language in C";
homepage = "http://www.pell.portland.or.us/~orc/Code/discount/";

View File

@ -11,13 +11,13 @@
stdenv.mkDerivation rec {
pname = "ugrep";
version = "3.5.0";
version = "3.6.0";
src = fetchFromGitHub {
owner = "Genivia";
repo = pname;
rev = "v${version}";
sha256 = "sha256-4A0UrXSJhV330W6phNDfqd/iNWYmKuzYUwr4gfTndQw=";
sha256 = "sha256-hEP7Oe1CNLEvSfUIXoXwRJUG4kIkb2f1549cZRXK+NY=";
};
buildInputs = [

View File

@ -9602,6 +9602,8 @@ with pkgs;
sigil = libsForQt5.callPackage ../applications/editors/sigil { };
signalbackup-tools = callPackage ../applications/networking/instant-messengers/signalbackup-tools { };
signald = callPackage ../applications/networking/instant-messengers/signald { };
signal-cli = callPackage ../applications/networking/instant-messengers/signal-cli { };
@ -13492,6 +13494,10 @@ with pkgs;
io = callPackage ../development/interpreters/io { };
ivy = callPackage ../development/interpreters/ivy {
buildGoModule = buildGo117Module;
};
j = callPackage ../development/interpreters/j {
stdenv = clangStdenv;
};

View File

@ -33,6 +33,10 @@ pkgs.runCommand "nixpkgs-release-checks" { src = nixpkgs; buildInputs = [nix]; }
for platform in ${pkgs.lib.concatStringsSep " " supportedSystems}; do
header "checking Nixpkgs on $platform"
# To get a call trace; see https://nixos.org/manual/nixpkgs/stable/#function-library-lib.trivial.warn
# Relies on impure eval
export NIX_ABORT_ON_WARN=true
nix-env -f $src \
--show-trace --argstr system "$platform" \
--arg config '{ allowAliases = false; }' \
@ -40,6 +44,7 @@ pkgs.runCommand "nixpkgs-release-checks" { src = nixpkgs; buildInputs = [nix]; }
-qa --drv-path --system-filter \* --system \
"''${opts[@]}" 2>&1 >/dev/null | tee eval-warnings.log
# Catch any trace calls not caught by NIX_ABORT_ON_WARN (lib.warn)
if [ -s eval-warnings.log ]; then
echo "Nixpkgs on $platform evaluated with warnings, aborting"
exit 1

View File

@ -6052,6 +6052,8 @@ in {
pynuki = callPackage ../development/python-modules/pynuki { };
pynut2 = callPackage ../development/python-modules/pynut2 { };
pynws = callPackage ../development/python-modules/pynws { };
pynx584 = callPackage ../development/python-modules/pynx584 { };