push sheeet
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s

This commit is contained in:
Dark Steveneq
2025-10-09 14:15:47 +02:00
commit 646b892680
49168 changed files with 5897842 additions and 0 deletions

View File

@@ -0,0 +1,63 @@
{
lib,
fetchFromGitHub,
libiconv,
openssl,
pkg-config,
rustPlatform,
stdenv,
testers,
}:
let
self = rustPlatform.buildRustPackage {
pname = "so";
version = "0.4.10";
src = fetchFromGitHub {
pname = "so-source";
inherit (self) version;
owner = "samtay";
repo = "so";
rev = "v${self.version}";
hash = "sha256-25jZEo1C9XF4m9YzDwtecQy468nHyv2wnRuK5oY2siU=";
};
cargoHash = "sha256-cSLsfYYtdMiXGCG3jpq2Cxl8TgSb7iCWoeXNwEuv4FM=";
nativeBuildInputs = [ pkg-config ];
buildInputs = [
openssl
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
libiconv
];
strictDeps = true;
passthru = {
tests = {
version = testers.testVersion {
package = self;
command = ''
export HOME=$TMP
so --version
'';
};
};
};
meta = {
homepage = "https://github.com/samtay/so";
description = "TUI to StackExchange network";
changelog = "https://github.com/samtay/so/blob/main/CHANGELOG.md";
mainProgram = "so";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [
unsolvedcypher
];
};
};
in
self

View File

@@ -0,0 +1,67 @@
{
fetchurl,
lib,
stdenv,
writeText,
jdk,
makeWrapper,
nixosTests,
}:
stdenv.mkDerivation rec {
pname = "soapui";
version = "5.9.1";
src = fetchurl {
url = "https://dl.eviware.com/soapuios/${version}/SoapUI-${version}-linux-bin.tar.gz";
sha256 = "sha256-VlI6TcesavKOpKf/R8S6IubepkthArFf8Jmi7YUGHjs=";
};
nativeBuildInputs = [ makeWrapper ];
buildInputs = [ jdk ];
installPhase = ''
runHook preInstall
mkdir -p $out/share/java
cp -R bin lib $out/share/java
makeWrapper $out/share/java/bin/soapui.sh $out/bin/soapui --set SOAPUI_HOME $out/share/java
runHook postInstall
'';
patches = [
# Adjust java path to point to derivation paths
(writeText "soapui-${version}.patch" ''
--- a/bin/soapui.sh
+++ b/bin/soapui.sh
@@ -50,7 +50,7 @@
#JAVA 16
JAVA_OPTS="$JAVA_OPTS --illegal-access=permit"
-JFXRTPATH=`java -cp $SOAPUI_CLASSPATH com.eviware.soapui.tools.JfxrtLocator`
+JFXRTPATH=`${jdk}/bin/java -cp $SOAPUI_CLASSPATH com.eviware.soapui.tools.JfxrtLocator`
SOAPUI_CLASSPATH=$JFXRTPATH:$SOAPUI_CLASSPATH
if $darwin
@@ -85,4 +85,4 @@
echo =
echo ================================
-java $JAVA_OPTS -cp $SOAPUI_CLASSPATH com.eviware.soapui.SoapUI "$@"
+${jdk}/bin/java $JAVA_OPTS -cp $SOAPUI_CLASSPATH com.eviware.soapui.SoapUI "$@"
'')
];
passthru.tests = { inherit (nixosTests) soapui; };
meta = with lib; {
description = "Most Advanced REST & SOAP Testing Tool in the World";
homepage = "https://www.soapui.org/";
sourceProvenance = with sourceTypes; [ binaryBytecode ];
license = lib.licenses.eupl11;
maintainers = with maintainers; [ gerschtli ];
platforms = platforms.linux; # we don't fetch the dmg yet
mainProgram = "soapui";
};
}

View File

@@ -0,0 +1,36 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
airspy,
soapysdr,
}:
stdenv.mkDerivation rec {
pname = "soapyairspy";
version = "0.2.0";
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyAirspy";
rev = "soapy-airspy-${version}";
sha256 = "0g23yybnmq0pg2m8m7dbhif8lw0hdsmnnjym93fdyxfk5iln7fsc";
};
nativeBuildInputs = [ cmake ];
buildInputs = [
airspy
soapysdr
];
cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyAirspy";
description = "SoapySDR plugin for Airspy devices";
license = licenses.mit;
maintainers = with maintainers; [ markuskowa ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,55 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
pkg-config,
hamlib,
rtaudio,
alsa-lib,
libpulseaudio,
libjack2,
libusb1,
soapysdr,
}:
stdenv.mkDerivation rec {
pname = "soapyaudio";
version = "0.1.1";
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyAudio";
rev = "soapy-audio-${version}";
sha256 = "0minlsc1lvmqm20vn5hb4im7pz8qwklfy7sbr2xr73xkrbqdahc0";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
hamlib
rtaudio
libjack2
libusb1
soapysdr
]
++ lib.optionals stdenv.hostPlatform.isLinux [
alsa-lib
libpulseaudio
];
cmakeFlags = [
"-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/"
"-DUSE_HAMLIB=ON"
];
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyAudio";
description = "SoapySDR plugin for amateur radio and audio devices";
license = licenses.mit;
maintainers = with maintainers; [ numinit ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,44 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
pkg-config,
libbladeRF,
soapysdr,
}:
let
version = "0.4.2";
in
stdenv.mkDerivation {
pname = "soapybladerf";
inherit version;
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyBladeRF";
rev = "soapy-bladerf-${version}";
sha256 = "sha256-lhTiu+iCdlLTY5ceND+F8HzKf2K9afuTi3cme6nGEMo=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
libbladeRF
soapysdr
];
cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyBladeRF";
description = "SoapySDR plugin for BladeRF devices";
license = licenses.lgpl21Only;
maintainers = with maintainers; [ markuskowa ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,44 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
pkg-config,
hackrf,
soapysdr,
}:
let
version = "0.3.4";
in
stdenv.mkDerivation {
pname = "soapyhackrf";
inherit version;
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyHackRF";
rev = "soapy-hackrf-${version}";
sha256 = "sha256-fzPYHJAPX8FkFxPXpLlUagTd/NoamRX0YnxHwkbV1nI=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
hackrf
soapysdr
];
cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyHackRF";
description = "SoapySDR plugin for HackRF devices";
license = licenses.mit;
maintainers = with maintainers; [ markuskowa ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,45 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
pkg-config,
libad9361,
libiio,
libusb1,
soapysdr,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "soapyplutosdr";
version = "0.2.2";
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyPlutoSDR";
rev = "soapy-plutosdr-${finalAttrs.version}";
hash = "sha256-uXKvv/QRbYknqsLGlPFxSH7KLh0CucLjq4XEFFcieWw=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
libad9361
libiio
libusb1
soapysdr
];
cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyPlutoSDR";
changelog = "https://github.com/pothosware/SoapyPlutoSDR/blob/soapy-plutosdr-${finalAttrs.version}/Changelog.txt";
description = "SoapySDR plugin for Pluto SDR devices";
license = licenses.lgpl21;
maintainers = with maintainers; [ wucke13 ];
platforms = platforms.unix;
};
})

View File

@@ -0,0 +1,45 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
soapysdr,
avahi,
}:
let
version = "0.5.2-unstable-2024-01-24";
in
stdenv.mkDerivation {
pname = "soapyremote";
inherit version;
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyRemote";
rev = "54caa5b2af348906607c5516a112057650d0873d";
sha256 = "sha256-uekElbcbX2P5TEufWEoP6tgUM/4vxgSQZu8qaBCSo18=";
};
nativeBuildInputs = [ cmake ];
buildInputs = [
soapysdr
avahi
];
cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
env.NIX_CFLAGS_COMPILE = toString (
lib.optionals stdenv.hostPlatform.isDarwin [ "-include sys/select.h" ]
);
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyRemote";
description = "SoapySDR plugin for remote access to SDRs";
license = licenses.boost;
maintainers = with maintainers; [ markuskowa ];
platforms = platforms.unix;
mainProgram = "SoapySDRServer";
};
}

View File

@@ -0,0 +1,58 @@
{
lib,
stdenv,
fetchFromGitHub,
fetchpatch2,
cmake,
pkg-config,
rtl-sdr,
soapysdr,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "soapyrtlsdr";
version = "0.3.3";
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyRTLSDR";
rev = "soapy-rtl-sdr-${finalAttrs.version}";
sha256 = "sha256-IapdrBE8HhibY52Anm76/mVAoA0GghwnRCxxfGkyLTw=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
rtl-sdr
soapysdr
];
patches = [
(fetchpatch2 {
name = "cmake-update.patch";
url = "https://github.com/pothosware/SoapyRTLSDR/commit/448c9d0d326c2600905b7ce84222ff9d72ba2189.patch?full_index=1";
hash = "sha256-hWlNowkf9yZM6p+EGh+IiUm2JfG5mLe8Qq8gTVIdIak=";
})
(fetchpatch2 {
name = "fix-cmake4-build.patch";
url = "https://github.com/pothosware/SoapyRTLSDR/commit/bb2d1511b957138051764c9193a3d6971e912b85.patch?full_index=1";
hash = "sha256-C90B5WMjx1lJKiX0F/cAfGmz2WRc2BA84FTmVmnC+DI=";
})
];
cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyRTLSDR";
description = "SoapySDR plugin for RTL-SDR devices";
license = licenses.mit;
maintainers = with maintainers; [
ragge
luizribeiro
];
platforms = platforms.unix;
};
})

View File

@@ -0,0 +1,43 @@
{
stdenv,
lib,
fetchFromGitHub,
cmake,
pkg-config,
soapysdr,
sdrplay,
}:
stdenv.mkDerivation rec {
pname = "soapysdr-sdrplay3";
version = "0.4.0";
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapySDRPlay3";
rev = "soapy-sdrplay3-${version}";
sha256 = "sha256-WMcAw0uR2o2SrQR4mBtdVEZlJ/ZXRqwo6zMJNsB/5U4=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
soapysdr
sdrplay
];
cmakeFlags = [
"-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/"
];
meta = with lib; {
description = "Soapy SDR module for SDRplay";
homepage = "https://github.com/pothosware/SoapySDRPlay3";
license = licenses.mit;
maintainers = [ maintainers.pmenke ];
platforms = platforms.linux;
};
}

View File

@@ -0,0 +1,47 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
pkg-config,
uhd,
boost,
soapysdr,
}:
stdenv.mkDerivation {
pname = "soapyuhd";
version = "0.4.1-unstable-2025-10-05";
src = fetchFromGitHub {
owner = "pothosware";
repo = "SoapyUHD";
# version that supports cmake 4
rev = "cf78b9ca3bddfc9263d2acb7e8afcb0036938163";
hash = "sha256-/hJ78dUL477gX3c2kV8kUknIk01PUf+ie1Gl7Ujq1Ac=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
uhd
boost
soapysdr
];
cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
postPatch = ''
sed -i "s:DESTINATION .*uhd/modules:DESTINATION $out/lib/uhd/modules:" CMakeLists.txt
'';
meta = with lib; {
homepage = "https://github.com/pothosware/SoapyAirspy";
description = "SoapySDR plugin for UHD devices";
license = licenses.gpl3Only;
maintainers = with maintainers; [ markuskowa ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,60 @@
{
pkgs,
lib,
stdenv,
fetchFromGitHub,
fetchpatch,
cmake,
withStatic ? stdenv.hostPlatform.isStatic,
withShared ? !withStatic,
buildExamples ? false,
}:
# Ensure build examples with static library.
assert buildExamples -> withStatic;
stdenv.mkDerivation (finalAttrs: {
pname = "sobjectizer";
version = "5.8.4";
src = fetchFromGitHub {
owner = "Stiffstream";
repo = "sobjectizer";
tag = "v.${finalAttrs.version}";
hash = "sha256-tIqWgd6TppHfqZk3XHzhG0t+Nn8BQCTP81UD7ls67UE=";
};
patches = [
(fetchpatch {
name = "tests-do-not-require-static-library.patch";
url = "https://github.com/Stiffstream/sobjectizer/commit/10eb34c65ccdaa4fea62d0c4354b83104256370d.patch";
hash = "sha256-a2g6jDGDC/y8cmbAD0KtVQKhVS5ZAjKtMhbAUyoQIvg=";
})
];
nativeBuildInputs = [ cmake ];
cmakeDir = "../dev";
cmakeFlags = [
(lib.cmakeBool "SOBJECTIZER_BUILD_STATIC" withStatic)
(lib.cmakeBool "SOBJECTIZER_BUILD_SHARED" withShared)
(lib.cmakeBool "BUILD_EXAMPLES" (buildExamples && withStatic))
(lib.cmakeBool "BUILD_TESTS" (finalAttrs.doCheck && withShared))
];
# The tests require the shared library thanks to the patch.
doCheck = withShared;
# Receive semi-automated updates.
passthru.updateScript = pkgs.nix-update-script { };
meta = {
homepage = "https://github.com/Stiffstream/sobjectizer/tree/master";
changelog = "https://github.com/Stiffstream/sobjectizer/releases/tag/v.${finalAttrs.version}";
description = "Implementation of Actor, Publish-Subscribe, and CSP models in one rather small C++ framework";
license = lib.licenses.bsd3;
maintainers = [ lib.maintainers.ivalery111 ];
platforms = lib.platforms.all;
};
})

View File

@@ -0,0 +1,169 @@
{
stdenv,
fetchFromGitHub,
lib,
cmake,
pkg-config,
alsa-lib,
copyDesktopItems,
makeDesktopItem,
xorg,
freetype,
expat,
libGL,
libjack2,
curl,
webkitgtk_4_1,
libsysprof-capture,
pcre2,
util-linux,
libselinux,
libsepol,
libthai,
libxkbcommon,
libdatrie,
libepoxy,
lerc,
sqlite,
ninja,
# Disable VST building by default, since NixOS doesn't have a VST license
enableVST2 ? false,
}:
stdenv.mkDerivation {
pname = "socalabs-sid";
version = "1.1.0";
src =
(fetchFromGitHub {
owner = "FigBug";
repo = "SID";
rev = "bb826fdea39da0804c53d81d35bea29aeff4436d";
hash = "sha256-6IStysItOS7EltTCqdyo9vrsnSA1YYoN4y8Bjv1fhNk=";
fetchSubmodules = true;
}).overrideAttrs
(_: {
GIT_CONFIG_COUNT = 1;
GIT_CONFIG_KEY_0 = "url.https://github.com/.insteadOf";
GIT_CONFIG_VALUE_0 = "git@github.com:";
});
desktopItems = [
(makeDesktopItem {
type = "Application";
name = "socalabs-sid";
desktopName = "Socalabs SID";
comment = "Socalabs Commodore 64 SID Emulation Plugin (Standalone)";
icon = "SID";
exec = "SID";
categories = [
"Audio"
"AudioVideo"
];
})
];
nativeBuildInputs = [
cmake
pkg-config
copyDesktopItems
ninja
];
buildInputs = [
alsa-lib
xorg.libX11
xorg.libXcomposite
xorg.libXcursor
xorg.libXinerama
xorg.libXrandr
xorg.libXtst
xorg.libXdmcp
xorg.xvfb
libGL
libjack2
libsysprof-capture
libselinux
libsepol
libthai
libxkbcommon
libdatrie
libepoxy
lerc
freetype
curl
webkitgtk_4_1
pcre2
util-linux
sqlite
expat
];
cmakeFlags = [
(lib.cmakeBool "JUCE_COPY_PLUGIN_AFTER_BUILD" false)
"--preset ninja-gcc"
];
patchPhase = ''
substituteInPlace CMakeLists.txt \
--replace-fail 'FORMATS Standalone VST VST3 AU LV2' 'FORMATS Standalone ${lib.optionalString enableVST2 "VST"} VST3 LV2'
# we need to patch JUCE itself to enable jack MIDI support
# please https://github.com/juce-framework/JUCE/issues/952
# TODO: remove when juce updates :D
substituteInPlace modules/juce/modules/juce_audio_devices/native/juce_Midi_linux.cpp \
--replace-fail "port = client.createPort (portName, forInput, false);" "port = client.createPort (portName, forInput, true);"
'';
cmakeBuildType = "Release";
strictDeps = true;
preBuild = ''
# build takes 10 years without this set
HOME=(mktemp -d)
cd ../Builds/ninja-gcc
'';
installPhase = ''
runHook preInstall
mkdir -p $out/lib/vst3 $out/lib/lv2 $out/bin
${lib.optionalString enableVST2 ''
mkdir -p $out/lib/vst
cp -r SID_artefacts/Release/VST/libSID.so $out/lib/vst
''}
cp -r SID_artefacts/Release/LV2/SID.lv2 $out/lib/lv2
cp -r SID_artefacts/Release/VST3/SID.vst3 $out/lib/vst3
install -Dm755 SID_artefacts/Release/Standalone/SID $out/bin
install -Dm444 $src/plugin/Resources/icon.png $out/share/pixmaps/SID.png
runHook postInstall
'';
NIX_LDFLAGS = (
toString [
"-lX11"
"-lXext"
"-lXcomposite"
"-lXcursor"
"-lXinerama"
"-lXrandr"
"-lXtst"
"-lXdmcp"
]
);
meta = {
description = "Socalabs Commodore 64 SID Emulation Plugin";
homepage = "https://socalabs.com/synths/commodore-64-sid/";
mainProgram = "SID";
platforms = lib.platforms.linux;
license = [ lib.licenses.gpl3 ] ++ lib.optional enableVST2 lib.licenses.unfree;
maintainers = [ lib.maintainers.l1npengtul ];
};
}

View File

@@ -0,0 +1,63 @@
{
lib,
fetchurl,
net-tools,
openssl,
readline,
stdenv,
which,
buildPackages,
}:
stdenv.mkDerivation rec {
pname = "socat";
version = "1.8.0.3";
src = fetchurl {
url = "http://www.dest-unreach.org/socat/download/${pname}-${version}.tar.bz2";
hash = "sha256-AesBc2HZW7OmlB6EC1nkRjo/q/kt9BVO0CsWou1qAJU=";
};
postPatch = ''
patchShebangs test.sh
substituteInPlace test.sh \
--replace /bin/rm rm \
--replace /sbin/ifconfig ifconfig
'';
configureFlags =
lib.optionals (!stdenv.hostPlatform.isLinux) [
"--disable-posixmq"
]
++ lib.optionals stdenv.hostPlatform.isFreeBSD [
"--disable-dccp"
];
buildInputs = [
openssl
readline
];
hardeningEnable = [ "pie" ];
enableParallelBuilding = true;
nativeCheckInputs = [
which
net-tools
];
doCheck = false; # fails a bunch, hangs
passthru.tests = lib.optionalAttrs stdenv.buildPlatform.isLinux {
musl = buildPackages.pkgsMusl.socat;
};
meta = with lib; {
description = "Utility for bidirectional data transfer between two independent data channels";
homepage = "http://www.dest-unreach.org/socat/";
platforms = platforms.unix;
license = with licenses; [ gpl2Only ];
maintainers = with maintainers; [ ryan4yin ];
mainProgram = "socat";
};
}

View File

@@ -0,0 +1,43 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
boost,
libpq,
sqlite,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "soci";
version = "4.1.2";
src = fetchFromGitHub {
owner = "SOCI";
repo = "soci";
tag = "v${finalAttrs.version}";
hash = "sha256-vdvvqPTODC0AMDLZa2pOy5/qkZ1IuJ0PEDTN6oMJAqg=";
};
# Do not build static libraries
cmakeFlags = [
(lib.cmakeFeature "CMAKE_CXX_STANDARD" "11")
(lib.cmakeBool "SOCI_STATIC" false)
(lib.cmakeBool "SOCI_TESTS" false)
];
nativeBuildInputs = [ cmake ];
buildInputs = [
sqlite
libpq
boost
];
meta = {
description = "Database access library for C++";
homepage = "https://soci.sourceforge.net/";
license = lib.licenses.boost;
platforms = lib.platforms.all;
maintainers = with lib.maintainers; [ jluttine ];
};
})

View File

@@ -0,0 +1,76 @@
{
lib,
fetchFromGitHub,
python3Packages,
makeWrapper,
metasploit,
}:
python3Packages.buildPythonApplication rec {
pname = "social-engineer-toolkit";
version = "8.0.3";
format = "other";
src = fetchFromGitHub {
owner = "trustedsec";
repo = "social-engineer-toolkit";
rev = version;
sha256 = "ePbmUvnzLO0Wfuhym3bNSPV1x8rcCPqKMeWSRcbJGAo=";
};
postPatch = ''
substituteInPlace setoolkit \
--replace "src/core/config.baseline" "$out/share/social-engineer-toolkit/src/core/config.baseline"
substituteInPlace src/core/setcore.py \
--replace '"src/core/set.version"' "\"$out/share/social-engineer-toolkit/src/core/set.version\"" \
--replace "/opt/metasploit-framework" "${metasploit}/bin"
'';
nativeBuildInputs = [
makeWrapper
];
propagatedBuildInputs = with python3Packages; [
pexpect
pycrypto
requests
pyopenssl
pefile
impacket
qrcode
pillow
# Has been abandoned upstream. Features using this library are broken
# pymssql
];
installPhase = ''
runHook preInstall
install -Dt $out/bin setoolkit seautomate seproxy
mkdir -p $out/share/social-engineer-toolkit
cp -r modules readme src $out/share/social-engineer-toolkit/
runHook postInstall
'';
makeWrapperArgs = [
"--chdir ${placeholder "out"}/share/social-engineer-toolkit"
"--prefix PYTHONPATH : \"${placeholder "out"}/share/social-engineer-toolkit\""
];
# Project has no tests
doCheck = false;
meta = with lib; {
description = "Open-source penetration testing framework designed for social engineering";
longDescription = ''
The Social-Engineer Toolkit is an open-source penetration testing framework
designed for social engineering. SET has a number of custom attack vectors
that allow you to make a believable attack quickly.
'';
homepage = "https://github.com/trustedsec/social-engineer-toolkit";
mainProgram = "setoolkit";
license = licenses.bsd3;
maintainers = with maintainers; [ emilytrau ];
};
}

View File

@@ -0,0 +1,33 @@
{
lib,
fetchFromGitHub,
python3,
bcc,
}:
python3.pkgs.buildPythonApplication rec {
pname = "sockdump";
version = "0-unstable-2023-12-11";
src = fetchFromGitHub {
owner = "mechpen";
repo = "sockdump";
rev = "d40ec77e960d021861220bc14a273c5dcad13160";
hash = "sha256-FLK1rgWvIoFGv/6+DtDhZGeOZrn7V1jYNS3S8qwL/dc=";
};
propagatedBuildInputs = [ bcc ];
format = "other"; # none
installPhase = "install -D sockdump.py $out/bin/sockdump";
meta = src.meta // {
description = "Dump unix domain socket traffic with bpf";
mainProgram = "sockdump";
license = lib.licenses.unlicense;
maintainers = with lib.maintainers; [
picnoir
];
};
}

View File

@@ -0,0 +1,29 @@
{
lib,
stdenv,
fetchurl,
cmake,
pkg-config,
}:
stdenv.mkDerivation rec {
pname = "socket_wrapper";
version = "1.5.1";
src = fetchurl {
url = "mirror://samba/cwrap/socket_wrapper-${version}.tar.gz";
sha256 = "sha256-miEZA+G3BeORbMUJ0MbV8PjftutYf0SOEdjiAJtHdaU=";
};
nativeBuildInputs = [
cmake
pkg-config
];
meta = with lib; {
description = "Library passing all socket communications through unix sockets";
homepage = "https://git.samba.org/?p=socket_wrapper.git;a=summary;";
license = licenses.bsd3;
platforms = platforms.all;
};
}

View File

@@ -0,0 +1,63 @@
{
lib,
stdenv,
fetchurl,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "socklog";
version = "2.1.1";
src = fetchurl {
url = "https://smarden.org/socklog/socklog-${finalAttrs.version}.tar.gz";
hash = "sha256-6xk3JB1seyoEArSf/evwIrsvzaPgDBsaF66Lzx5KObo=";
};
sourceRoot = "admin/socklog-${finalAttrs.version}";
outputs = [
"out"
"man"
"doc"
];
postPatch = ''
# Fails to run as user without supplementary groups
echo "int main() { return 0; }" >src/chkshsgr.c
'';
configurePhase = ''
echo "$NIX_CC/bin/cc $NIX_CFLAGS_COMPILE" >src/conf-cc
echo "$NIX_CC/bin/cc -s" >src/conf-ld
'';
buildPhase = "package/compile";
installPhase = ''
mkdir -p $out/bin
mv command"/"* $out/bin
for i in {1,8} ; do
mkdir -p $man/share/man/man$i
mv man"/"*.$i $man/share/man/man$i
done
mkdir -p $doc/share/doc/socklog/html
mv doc/*.html $doc/share/doc/socklog/html/
'';
checkPhase = "package/check";
doCheck = true;
# Needed for tests
__darwinAllowLocalNetworking = true;
meta = {
description = "System and kernel logging services";
homepage = "https://smarden.org/socklog/";
license = lib.licenses.bsd3;
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ joachifm ];
};
})

View File

@@ -0,0 +1,44 @@
{
lib,
stdenv,
fetchFromGitHub,
autoreconfHook,
doxygen,
enableTool ? false,
enableTest ? false,
}:
stdenv.mkDerivation rec {
pname = "sockperf";
version = "3.10";
src = fetchFromGitHub {
owner = "Mellanox";
repo = "sockperf";
rev = version;
sha256 = "sha256-VvxL/bcn69uL7CBpDu4qwbKZwlC4N/kNeRX4k3UzxPI=";
};
nativeBuildInputs = [
autoreconfHook
doxygen
];
configureFlags = [
"--enable-doc"
]
++ lib.optional enableTest "--enable-test"
++ lib.optional enableTool "--enable-tool";
doCheck = true;
meta = with lib; {
broken = stdenv.hostPlatform.isDarwin;
description = "Network Benchmarking Utility";
homepage = "https://github.com/Mellanox/sockperf";
license = licenses.bsd3;
maintainers = with maintainers; [ emilytrau ];
platforms = platforms.all;
mainProgram = "sockperf";
};
}

View File

@@ -0,0 +1,48 @@
{
lib,
stdenv,
fetchFromGitHub,
installShellFiles,
versionCheckHook,
nix-update-script,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sockstat";
version = "1.1.0";
src = fetchFromGitHub {
owner = "mezantrop";
repo = "sockstat";
tag = finalAttrs.version;
hash = "sha256-7VfideKNWlWb9nnAL2TK7HiD0T5EJsQiagT2kPMwrdA=";
};
nativeBuildInputs = [ installShellFiles ];
installPhase = ''
runHook preInstall
installBin sockstat
runHook postInstall
'';
doInstallCheck = true;
nativeInstallCheckInputs = [ versionCheckHook ];
versionCheckProgramArg = "-v";
passthru = {
updateScript = nix-update-script { };
};
meta = {
description = "FreeBSD-like sockstat for macOS using libproc";
homepage = "https://github.com/mezantrop/sockstat";
changelog = "https://github.com/mezantrop/sockstat/releases/tag/${finalAttrs.version}";
license = lib.licenses.bsd2;
maintainers = with lib.maintainers; [ DimitarNestorov ];
platforms = lib.platforms.darwin;
mainProgram = "sockstat";
};
})

View File

@@ -0,0 +1,45 @@
{
lib,
fetchFromGitHub,
python3,
}:
python3.pkgs.buildPythonApplication rec {
pname = "soco-cli";
version = "0.4.80";
pyproject = true;
disabled = python3.pythonOlder "3.6";
src = fetchFromGitHub {
owner = "avantrec";
repo = "soco-cli";
rev = "v${version}";
hash = "sha256-w4F1N1ULGH7mbxtI8FpZ54ixa9o7N2A9OEiE2FOf73g=";
};
build-system = with python3.pkgs; [ setuptools ];
dependencies = with python3.pkgs; [
fastapi
rangehttpserver
soco
tabulate
uvicorn
];
# Tests wants to communicate with hardware
doCheck = false;
pythonImportsCheck = [
"soco_cli"
];
meta = {
description = "Command-line interface to control Sonos sound systems";
homepage = "https://github.com/avantrec/soco-cli";
license = with lib.licenses; [ asl20 ];
mainProgram = "sonos";
maintainers = with lib.maintainers; [ fab ];
};
}

View File

@@ -0,0 +1,47 @@
{
lib,
fetchurl,
stdenvNoCC,
nix-update-script,
}:
stdenvNoCC.mkDerivation (finalAttrs: {
pname = "sof-firmware";
version = "2025.05.1";
src = fetchurl {
url = "https://github.com/thesofproject/sof-bin/releases/download/v${finalAttrs.version}/sof-bin-${finalAttrs.version}.tar.gz";
hash = "sha256-YNVOrjJpQzKiEgt8ROSvQDoU/h/fTFjXKYEQKxkdJZw=";
};
dontFixup = true; # binaries must not be stripped or patchelfed
installPhase = ''
runHook preInstall
mkdir -p $out/lib/firmware/intel
# copy sof and sof-* recursively, preserving symlinks
cp -R -d sof{,-*} $out/lib/firmware/intel/
runHook postInstall
'';
passthru.updateScript = nix-update-script { };
meta = {
changelog = "https://github.com/thesofproject/sof-bin/releases/tag/v${finalAttrs.version}";
description = "Sound Open Firmware";
homepage = "https://www.sofproject.org/";
license = with lib.licenses; [
bsd3
isc
];
maintainers = with lib.maintainers; [
lblasc
evenbrenden
hmenke
];
platforms = with lib.platforms; linux;
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
};
})

View File

@@ -0,0 +1,32 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
alsa-lib,
}:
stdenv.mkDerivation rec {
pname = "sof-tools";
version = "2.10";
src = fetchFromGitHub {
owner = "thesofproject";
repo = "sof";
rev = "v${version}";
hash = "sha256-VmP0z3q1P8LqQ+ELZGkI7lEXGiMYdAPvS8Lbwv6dUyk=";
};
nativeBuildInputs = [ cmake ];
buildInputs = [ alsa-lib ];
sourceRoot = "${src.name}/tools";
meta = with lib; {
description = "Tools to develop, test and debug SoF (Sund Open Firmware)";
homepage = "https://thesofproject.github.io";
license = licenses.bsd3;
platforms = platforms.unix;
maintainers = [ maintainers.johnazoidberg ];
mainProgram = "sof-ctl";
};
}

View File

@@ -0,0 +1,91 @@
{
lib,
stdenv,
fetchFromGitHub,
fetchpatch,
# propagatedNativeBuildInputs
cmake,
qt6Packages,
# propagatedBuildInputs
boost,
cxxopts,
eigen,
glew,
gtest,
libGL,
metis,
tinyxml-2,
zlib,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sofa";
version = "24.12.00";
src = fetchFromGitHub {
owner = "sofa-framework";
repo = "sofa";
tag = "v${finalAttrs.version}";
hash = "sha256-LeFIM1RJjA2ynimjE8XngOQ8gR7BgqqTZBbDp0KXxs0=";
};
patches = [
# Include missing header for setw / setfill.
# ref. https://github.com/sofa-framework/sofa/pull/5279
# This was merged upstream and can be removed in next version
(fetchpatch {
url = "https://github.com/sofa-framework/sofa/commit/700b6cdd94fe24a51b2a7014fb0fc83e6abe1fbc.patch";
hash = "sha256-czc1u03USQt18d7cMPmXYguBhSb5JOJLplPvoixp+3w=";
})
(fetchpatch {
# Compat with metis > 5.1
name = "sofamatrix-allow-newer-metis-versions.patch";
url = "https://github.com/sofa-framework/sofa/commit/f1a45da7c77776ea9559b1958576b0187a8b9958.patch";
hash = "sha256-YPMBKG1Ju5XON14CmSYNqljpqEbFRvI5SgKwOnxs7+I=";
})
];
propagatedNativeBuildInputs = [
cmake
qt6Packages.wrapQtAppsHook
];
propagatedBuildInputs = [
boost
cxxopts
eigen
glew
gtest
qt6Packages.libqglviewer
qt6Packages.qtbase
libGL
metis
tinyxml-2
zlib
];
cmakeFlags = [
(lib.cmakeBool "SOFA_ALLOW_FETCH_DEPENDENCIES" false)
];
doCheck = true;
postFixup = lib.optionalString stdenv.hostPlatform.isDarwin ''
install_name_tool -change \
$out/lib/libSceneChecking.${finalAttrs.version}.dylib \
$out/plugins/SceneChecking/lib/libSceneChecking.${finalAttrs.version}.dylib \
$out/bin/.runSofa-${finalAttrs.version}-wrapped
'';
meta = {
description = "Real-time multi-physics simulation with an emphasis on medical simulation";
homepage = "https://github.com/sofa-framework/sofa/";
changelog = "https://github.com/sofa-framework/sofa/blob/v${finalAttrs.version}/CHANGELOG.md";
license = lib.licenses.lgpl21Only;
maintainers = with lib.maintainers; [ nim65s ];
mainProgram = "runSofa";
platforms = lib.platforms.unix ++ lib.platforms.windows;
};
})

View File

@@ -0,0 +1,47 @@
{
lib,
stdenv,
fetchFromGitHub,
fetchpatch2,
glib,
openssl,
pkg-config,
autoreconfHook,
}:
stdenv.mkDerivation rec {
pname = "sofia-sip";
version = "1.13.17";
src = fetchFromGitHub {
owner = "freeswitch";
repo = "sofia-sip";
rev = "v${version}";
sha256 = "sha256-7QmK2UxEO5lC0KBDWB3bwKTy0Nc7WrdTLjoQYzezoaY=";
};
patches = [
# Fix build with gcc 14 from https://github.com/freeswitch/sofia-sip/pull/249
(fetchpatch2 {
name = "sofia-sip-fix-incompatible-pointer-type.patch";
url = "https://github.com/freeswitch/sofia-sip/commit/46b02f0655af0a9594e805f09a8ee99278f84777.diff";
hash = "sha256-4uZVtKnXG+BPW8byjd7tu4uEZo9SYq9EzTEvMwG0Bak=";
})
];
buildInputs = [
glib
openssl
];
nativeBuildInputs = [
autoreconfHook
pkg-config
];
meta = with lib; {
description = "Open-source SIP User-Agent library, compliant with the IETF RFC3261 specification";
homepage = "https://github.com/freeswitch/sofia-sip";
platforms = platforms.unix;
license = licenses.lgpl2;
};
}

View File

@@ -0,0 +1,56 @@
{
lib,
buildGoModule,
fetchFromGitHub,
makeWrapper,
nixosTests,
git,
bash,
}:
buildGoModule rec {
pname = "soft-serve";
version = "0.10.0";
src = fetchFromGitHub {
owner = "charmbracelet";
repo = "soft-serve";
rev = "v${version}";
hash = "sha256-Lg7cESGMbVCNx0KQBIAP/UsfvO3IO+DO9bYiQbg9Fls=";
};
vendorHash = "sha256-DBgVcbt2kejtEJSajJh6vS4feT3Lwm+KqUOks55iWIc=";
doCheck = false;
ldflags = [
"-s"
"-w"
"-X=main.Version=${version}"
];
nativeBuildInputs = [ makeWrapper ];
postInstall = ''
# Soft-serve generates git-hooks at run-time.
# The scripts require git and bash inside the path.
wrapProgram $out/bin/soft \
--prefix PATH : "${
lib.makeBinPath [
git
bash
]
}"
'';
passthru.tests = nixosTests.soft-serve;
meta = {
description = "Tasty, self-hosted Git server for the command line";
homepage = "https://github.com/charmbracelet/soft-serve";
changelog = "https://github.com/charmbracelet/soft-serve/releases/tag/v${version}";
mainProgram = "soft";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ penguwin ];
};
}

View File

@@ -0,0 +1,68 @@
{
lib,
stdenv,
fetchFromGitHub,
openssl,
readline,
ncurses,
zlib,
bash,
dataDir ? "/var/lib/softether",
}:
stdenv.mkDerivation (finalAttrs: {
pname = "softether";
version = "4.44-9807-rtm";
src = fetchFromGitHub {
owner = "SoftEtherVPN";
repo = "SoftEtherVPN_Stable";
tag = "v${finalAttrs.version}";
hash = "sha256-roi5M/YmSBH44pRPSVZcADIHDbSpAfASiPbTdijisUM=";
};
buildInputs = [
openssl
readline
ncurses
zlib
bash
];
preConfigure = ''
./configure
'';
buildPhase = ''
mkdir -p $out/bin
sed -i \
-e "/INSTALL_BINDIR=/s|/usr/bin|/bin|g" \
-e "/_DIR=/s|/usr|${dataDir}|g" \
-e "s|\$(INSTALL|$out/\$(INSTALL|g" \
-e "/echo/s|echo $out/|echo |g" \
Makefile
'';
postInstall = ''
substituteInPlace $out/bin/vpnbridge --replace-fail /var/lib/softether/vpnbridge/vpnbridge $out/var/lib/softether/vpnbridge/vpnbridge
substituteInPlace $out/bin/vpnclient --replace-fail /var/lib/softether/vpnclient/vpnclient $out/var/lib/softether/vpnclient/vpnclient
substituteInPlace $out/bin/vpncmd --replace-fail /var/lib/softether/vpncmd/vpncmd $out/var/lib/softether/vpncmd/vpncmd
substituteInPlace $out/bin/vpnserver --replace-fail /var/lib/softether/vpnserver/vpnserver $out/var/lib/softether/vpnserver/vpnserver
'';
env.NIX_CFLAGS_COMPILE = toString [
"-Wno-incompatible-pointer-types"
"-Wno-implicit-function-declaration"
];
meta = {
description = "Open-Source Free Cross-platform Multi-protocol VPN Program";
homepage = "https://www.softether.org/";
license = lib.licenses.asl20;
maintainers = [ lib.maintainers.rick68 ];
platforms = [
"x86_64-linux"
"aarch64-linux"
];
};
})

View File

@@ -0,0 +1,46 @@
{
lib,
stdenv,
fetchFromGitHub,
autoreconfHook,
libpcap,
versionCheckHook,
gitUpdater,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "softflowd";
version = "1.1.1";
src = fetchFromGitHub {
owner = "irino";
repo = "softflowd";
tag = "softflowd-v${finalAttrs.version}";
hash = "sha256-qWHwkXT1Lw8fe9nELaMB6EzAnNxsDvxiLWH3AacVZeA=";
};
nativeBuildInputs = [
autoreconfHook
];
buildInputs = [
libpcap
];
nativeInstallCheckInputs = [
versionCheckHook
];
doInstallCheck = true;
passthru.updateScript = gitUpdater { rev-prefix = "softflowd-v"; };
meta = {
description = "Flow-based network traffic analyser capable of Cisco NetFlow";
homepage = "https://github.com/irino/softflowd";
changelog = "https://github.com/irino/softflowd/releases/tag/spftflowd-v${finalAttrs.version}";
license = lib.licenses.bsd2;
maintainers = with lib.maintainers; [ fooker ];
platforms = lib.platforms.unix;
};
})

View File

@@ -0,0 +1,64 @@
{
lib,
stdenv,
fetchFromGitHub,
botan2,
sqlite,
autoreconfHook,
}:
stdenv.mkDerivation rec {
pname = "softhsm";
version = "2.6.1";
src = fetchFromGitHub {
owner = "softhsm";
repo = "SoftHSMv2";
rev = "${version}";
hash = "sha256-sx0ceVY795JbtKbQGAVFllB9UJfTdgd242d6c+s1tBw=";
};
nativeBuildInputs = [
autoreconfHook
];
configureFlags = [
"--with-crypto-backend=botan"
"--with-botan=${lib.getDev botan2}"
"--with-objectstore-backend-db"
"--sysconfdir=$out/etc"
"--localstatedir=$out/var"
# The configure script checks for the sqlite3 command, but never uses it.
# Provide an arbitrary executable file for cross scenarios.
"ac_cv_path_SQLITE3=/"
];
buildInputs = [
botan2
sqlite
];
strictDeps = true;
postInstall = "rm -rf $out/var";
meta = with lib; {
homepage = "https://www.softhsm.org/";
description = "Cryptographic store accessible through a PKCS #11 interface";
longDescription = "
SoftHSM provides a software implementation of a generic
cryptographic device with a PKCS#11 interface, which is of
course especially useful in environments where a dedicated hardware
implementation of such a device - for instance a Hardware
Security Module (HSM) or smartcard - is not available.
SoftHSM follows the OASIS PKCS#11 standard, meaning it should be
able to work with many cryptographic products. SoftHSM is a
programme of The Commons Conservancy.
";
license = licenses.bsd2;
maintainers = [ maintainers.leenaars ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,35 @@
{
lib,
stdenvNoCC,
fetchurl,
}:
stdenvNoCC.mkDerivation (finalAttrs: {
pname = "softnet";
version = "0.7.1";
src = fetchurl {
url = "https://github.com/cirruslabs/softnet/releases/download/${finalAttrs.version}/softnet.tar.gz";
sha256 = "1g274x524xc85hfzxi3vb4xp720bjgk740bp6hc92d1ikmp0b664";
};
sourceRoot = ".";
installPhase = ''
runHook preInstall
install -D softnet $out/bin/softnet
install -Dm444 -t $out/share/softnet README.md LICENSE
runHook postInstall
'';
meta = with lib; {
description = "Software networking with isolation for Tart";
homepage = "https://github.com/cirruslabs/softnet";
license = licenses.agpl3Plus;
maintainers = with maintainers; [ emilytrau ];
platforms = [ "aarch64-darwin" ];
# Source build will be possible after darwin SDK 12.0 bump
# https://github.com/NixOS/nixpkgs/pull/229210
sourceProvenance = with sourceTypes; [ binaryNativeCode ];
};
})

View File

@@ -0,0 +1,21 @@
--- a/ActiveSync/NSData+ActiveSync.m
+++ b/ActiveSync/NSData+ActiveSync.m
@@ -36,7 +36,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#import <NGExtensions/NGBase64Coding.h>
#import <NGExtensions/NSObject+Logs.h>
-#include <wbxml/wbxml.h>
+#include <libwbxml-1.1/wbxml/wbxml.h>
#define WBXMLDEBUG 0
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -11,6 +11,7 @@ SUBPROJECTS = \
UI \
Tools \
Tests/Unit \
+ ActiveSync \
include $(GNUSTEP_MAKEFILES)/aggregate.make

View File

@@ -0,0 +1,121 @@
{
lib,
clangStdenv,
fetchFromGitHub,
makeWrapper,
python3,
lndir,
libxcrypt,
openssl,
openldap,
sope,
libmemcached,
curl,
libsodium,
libytnef,
libzip,
pkg-config,
nixosTests,
oath-toolkit,
gnustep-make,
gnustep-base,
enableActiveSync ? false,
libwbxml,
}:
clangStdenv.mkDerivation rec {
pname = "sogo";
version = "5.12.3";
# always update the sope package as well, when updating sogo
src = fetchFromGitHub {
owner = "Alinto";
repo = "sogo";
rev = "SOGo-${version}";
hash = "sha256-HTfe/ZiipqS6QdKQK0wf4Xl6xCTNw5fEdXfRFbBMWMY=";
};
nativeBuildInputs = [
makeWrapper
python3
pkg-config
];
buildInputs = [
gnustep-base
sope
openssl
libmemcached
curl
libsodium
libytnef
libzip
openldap
oath-toolkit
libxcrypt
]
++ lib.optional enableActiveSync libwbxml;
patches = lib.optional enableActiveSync ./enable-activesync.patch;
postPatch = ''
# Exclude NIX_ variables
sed -i 's/grep GNUSTEP_/grep ^GNUSTEP_/g' configure
# Disable argument verification because $out is not a GNUStep prefix
sed -i 's/^validateArgs$//g' configure
# Patch exception-generating python scripts
patchShebangs .
# Move all GNUStep makefiles to a common directory
mkdir -p makefiles
cp -r {${gnustep-make},${sope}}/share/GNUstep/Makefiles/* makefiles
# Modify the search path for GNUStep makefiles
find . -type f -name GNUmakefile -exec sed -i "s:\\$.GNUSTEP_MAKEFILES.:$PWD/makefiles:g" {} +
'';
configureFlags = [
"--disable-debug"
"--with-ssl=ssl"
"--enable-mfa"
];
env.NIX_CFLAGS_COMPILE = "-Wno-error=incompatible-pointer-types -Wno-error=int-conversion -Wno-error=implicit-int -Wno-error=return-type";
preFixup = ''
# Create gnustep.conf
mkdir -p $out/share/GNUstep
cp ${gnustep-make}/etc/GNUstep/GNUstep.conf $out/share/GNUstep/
sed -i "s:${gnustep-make}:$out:g" $out/share/GNUstep/GNUstep.conf
# Link in GNUstep base
${lndir}/bin/lndir ${lib.getLib gnustep-base}/lib/GNUstep/ $out/lib/GNUstep/
# Link in sope
${lndir}/bin/lndir ${sope}/ $out/
# sbin fixup
mkdir -p $out/bin
mv $out/sbin/* $out/bin
rmdir $out/sbin
# Make sogo find its files
for bin in $out/bin/*; do
wrapProgram $bin --prefix LD_LIBRARY_PATH : $out/lib/sogo --prefix GNUSTEP_CONFIG_FILE : $out/share/GNUstep/GNUstep.conf
done
'';
passthru.tests.sogo = nixosTests.sogo;
meta = with lib; {
description = "Very fast and scalable modern collaboration suite (groupware)";
license = with licenses; [
gpl2Only
lgpl21Only
];
homepage = "https://sogo.nu/";
platforms = platforms.linux;
maintainers = with maintainers; [ jceb ];
};
}

View File

@@ -0,0 +1,45 @@
{
stdenv,
lib,
fetchzip,
libGL,
libX11,
}:
stdenv.mkDerivation {
pname = "soil";
version = "unstable-2020-01-04";
src = fetchzip {
url = "https://web.archive.org/web/20200104042737id_/http://www.lonesock.net/files/soil.zip";
sha256 = "1c05nwbnfdgwaz8ywn7kg2xrcvrcbpdyhcfkkiiwk69zvil0pbgd";
};
buildInputs = lib.optionals (!stdenv.hostPlatform.isDarwin) [
libGL
libX11
];
buildPhase = ''
cd src
$CC $NIX_CFLAGS_COMPILE -c *.c
$AR rcs libSOIL.a *.o
'';
installPhase = ''
mkdir -p $out/lib $out/include/SOIL
cp libSOIL.a $out/lib/
cp SOIL.h $out/include/SOIL/
'';
meta = with lib; {
description = "Simple OpenGL Image Library";
longDescription = ''
SOIL is a tiny C library used primarily for uploading textures
into OpenGL.
'';
homepage = "https://www.lonesock.net/soil.html";
license = licenses.publicDomain;
platforms = platforms.unix;
maintainers = with maintainers; [ r-burns ];
};
}

View File

@@ -0,0 +1,61 @@
{
buildGoModule,
fetchFromGitHub,
lib,
pkg-config,
nix-update-script,
alsa-lib,
libGL,
libxkbcommon,
vulkan-headers,
wayland,
xorg,
}:
buildGoModule {
pname = "sointu";
version = "0.4.1-unstable-2025-08-13";
src = fetchFromGitHub {
owner = "vsariola";
repo = "sointu";
rev = "74fea4138fd788eddeb726440c872937de56fd1c";
hash = "sha256-kHK35Bt/+ucPCsFE3p72J3jSHzhOK9QKtJPG+3grBvs=";
};
nativeBuildInputs = [
pkg-config
];
buildInputs = [
alsa-lib
libGL
libxkbcommon
vulkan-headers
wayland
xorg.libX11
xorg.libXcursor
xorg.libXfixes
];
proxyVendor = true;
vendorHash = "sha256-gLDLKqu6k7/nwv6xHUE6MIYrbQFfVFAuUiMbLptcE5k=";
subPackages = [
"cmd/sointu-track"
"cmd/sointu-compile"
"cmd/sointu-play"
];
passthru.updateScript = nix-update-script {
extraArgs = [ "--version=branch" ];
};
meta = {
description = "Fork of 4klang that can target 386, amd64 and WebAssembly";
mainProgram = "sointu-track";
homepage = "https://github.com/vsariola/sointu";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ martinimoe ];
};
}

View File

@@ -0,0 +1,66 @@
{
lib,
buildGoModule,
fetchFromGitea,
installShellFiles,
scdoc,
nixosTests,
}:
buildGoModule rec {
pname = "soju";
version = "0.9.0";
src = fetchFromGitea {
domain = "codeberg.org";
owner = "emersion";
repo = "soju";
rev = "v${version}";
hash = "sha256-qbSTaE0qOeXVcEmOver8Tu+gwV4cP4gNzIxByLKApCU=";
};
vendorHash = "sha256-JhoAtBw4O6lOd27dIXBNvA9EfUH5AD3ZHuGcWgU/Xv0=";
nativeBuildInputs = [
installShellFiles
scdoc
];
ldflags = [
"-s"
"-w"
"-X codeberg.org/emersion/soju/config.DefaultPath=/etc/soju/config"
"-X codeberg.org/emersion/soju/config.DefaultUnixAdminPath=/run/soju/admin"
];
postBuild = ''
make doc/soju.1 doc/sojuctl.1
'';
checkFlags = [ "-skip TestPostgresMigrations" ];
postInstall = ''
installManPage doc/soju.1 doc/sojuctl.1
'';
passthru.tests.soju = nixosTests.soju;
meta = with lib; {
description = "User-friendly IRC bouncer";
longDescription = ''
soju is a user-friendly IRC bouncer. soju connects to upstream IRC servers
on behalf of the user to provide extra functionality. soju supports many
features such as multiple users, numerous IRCv3 extensions, chat history
playback and detached channels. It is well-suited for both small and large
deployments.
'';
homepage = "https://soju.im";
changelog = "https://codeberg.org/emersion/soju/releases/tag/${src.rev}";
license = licenses.agpl3Only;
maintainers = with maintainers; [
azahi
malte-v
];
mainProgram = "sojuctl";
};
}

View File

@@ -0,0 +1,38 @@
{
lib,
stdenv,
fetchFromGitHub,
}:
stdenv.mkDerivation {
pname = "sokol";
version = "0-unstable-2024-09-20";
src = fetchFromGitHub {
owner = "floooh";
repo = "sokol";
rev = "38e4c9a516f8808d706343a5c525acfe7007fe67";
sha256 = "sha256-g4JMCbG9is7uBFv6cTBTCmRYfKWMruagtYQjYZnOFn4=";
};
dontBuild = true;
dontConfigure = true;
installPhase = ''
runHook preInstall
mkdir -p $out/include/sokol
cp *.h $out/include/sokol/
cp -R util $out/include/sokol/util
runHook postInstall
'';
meta = with lib; {
description = "Minimal cross-platform standalone C headers";
homepage = "https://github.com/floooh/sokol";
license = licenses.zlib;
platforms = platforms.all;
maintainers = with maintainers; [ jonnybolton ];
};
}

View File

@@ -0,0 +1,40 @@
{
fetchFromGitHub,
lib,
stdenv,
cmake,
lua,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sol2";
version = "3.5.0";
src = fetchFromGitHub {
owner = "ThePhD";
repo = "sol2";
rev = "v${finalAttrs.version}";
hash = "sha256-bW6HD9WLOWizli6LnrkFZKxiT8IdN0QESlok+xCFz1w=";
};
nativeBuildInputs = [
cmake
lua
];
cmakeFlags = [
"-DSOL2_LUA_VERSION=${lua.version}"
"-DSOL2_BUILD_LUA=FALSE"
];
meta = with lib; {
description = "Lua API wrapper with advanced features and top notch performance";
longDescription = ''
sol2 is a C++ library binding to Lua.
It currently supports all Lua versions 5.1+ (LuaJIT 2.0+ and MoonJIT included).
sol2 aims to be easy to use and easy to add to a project.
The library is header-only for easy integration with projects, and a single header can be used for drag-and-drop start up.
'';
homepage = "https://github.com/ThePhD/sol2";
license = licenses.mit;
maintainers = with maintainers; [ mrcjkb ];
};
})

View File

@@ -0,0 +1,112 @@
{
fetchFromGitHub,
lib,
gobject-introspection,
gtk3,
python3Packages,
wrapGAppsHook3,
gdk-pixbuf,
libappindicator,
librsvg,
udevCheckHook,
acl,
}:
# Although we copy in the udev rules here, you probably just want to use
# `logitech-udev-rules`, which is an alias to `udev` output of this derivation,
# instead of adding this to `services.udev.packages` on NixOS,
python3Packages.buildPythonApplication rec {
pname = "solaar";
version = "1.1.14";
format = "setuptools";
src = fetchFromGitHub {
owner = "pwr-Solaar";
repo = "Solaar";
tag = version;
hash = "sha256-cAM4h0OOXxItSf0Gb9PfHn385FXMKwvIUuYTrjgABwA=";
};
outputs = [
"out"
"udev"
];
nativeBuildInputs = [
gdk-pixbuf
gobject-introspection
wrapGAppsHook3
udevCheckHook
];
buildInputs = [
libappindicator
librsvg
];
propagatedBuildInputs = with python3Packages; [
evdev
dbus-python
gtk3
hid-parser
psutil
pygobject3
pyudev
pyyaml
typing-extensions
xlib
];
nativeCheckInputs = with python3Packages; [
pytestCheckHook
pytest-mock
pytest-cov-stub
];
preConfigure = ''
substituteInPlace lib/solaar/listener.py \
--replace-fail /usr/bin/getfacl "${lib.getExe' acl "getfacl"}"
'';
# the -cli symlink is just to maintain compabilility with older versions where
# there was a difference between the GUI and CLI versions.
postInstall = ''
ln -s $out/bin/solaar $out/bin/solaar-cli
install -Dm444 -t $udev/etc/udev/rules.d rules.d-uinput/*.rules
'';
dontWrapGApps = true;
preFixup = ''
makeWrapperArgs+=("''${gappsWrapperArgs[@]}")
'';
pythonImportsCheck = [
"solaar"
"solaar.gtk"
];
meta = with lib; {
description = "Linux devices manager for the Logitech Unifying Receiver";
longDescription = ''
Solaar is a Linux manager for many Logitech keyboards, mice, and trackpads that
connect wirelessly to a USB Unifying, Lightspeed, or Nano receiver, connect
directly via a USB cable, or connect via Bluetooth. Solaar does not work with
peripherals from other companies.
Solaar can be used as a GUI application or via its command-line interface.
This tool requires either to be run with root/sudo or alternatively to have the udev rules files installed. On NixOS this can be achieved by setting `hardware.logitech.wireless.enable`.
'';
homepage = "https://pwr-solaar.github.io/Solaar/";
license = licenses.gpl2Only;
mainProgram = "solaar";
maintainers = with maintainers; [
spinus
ysndr
oxalica
];
platforms = platforms.linux;
};
}

View File

@@ -0,0 +1,125 @@
{
stdenv,
fetchFromGitHub,
lib,
rustPlatform,
udev,
protobuf,
installShellFiles,
pkg-config,
openssl,
nix-update-script,
versionCheckHook,
clang,
libclang,
rocksdb,
# Taken from https://github.com/solana-labs/solana/blob/master/scripts/cargo-install-all.sh#L84
solanaPkgs ? [
"cargo-build-sbf"
"cargo-test-sbf"
"solana"
"solana-bench-tps"
"solana-faucet"
"solana-gossip"
"agave-install"
"solana-keygen"
"agave-ledger-tool"
"solana-log-analyzer"
"solana-net-shaper"
"agave-validator"
"solana-test-validator"
]
++ [
# XXX: Ensure `solana-genesis` is built LAST!
# See https://github.com/solana-labs/solana/issues/5826
"solana-genesis"
],
}:
let
version = "2.3.8";
hash = "sha256-CqkedeQk66VXG6lQAIVGd7ci0KPltf2Qq69iErBAQGo=";
in
rustPlatform.buildRustPackage rec {
pname = "solana-cli";
inherit version;
src = fetchFromGitHub {
owner = "anza-xyz";
repo = "agave";
tag = "v${version}";
inherit hash;
};
cargoHash = "sha256-J7gyR7K1hauV+VrzoNzRrooLuSkjk8U6A3aFn9O2yFY=";
strictDeps = true;
cargoBuildFlags = map (n: "--bin=${n}") solanaPkgs;
RUSTFLAGS = "-Amismatched_lifetime_syntaxes -Adead_code";
LIBCLANG_PATH = "${libclang.lib}/lib";
# Even tho the tests work, a shit ton of them try to connect to a local RPC
# or access internet in other ways, eventually failing due to Nix sandbox.
# Maybe we could restrict the check to the tests that don't require an RPC,
# but judging by the quantity of tests, that seems like a lengthty work and
# I'm not in the mood ((ΦωΦ))
doCheck = false;
nativeBuildInputs = [
installShellFiles
protobuf
pkg-config
];
buildInputs = [
openssl
clang
libclang
rustPlatform.bindgenHook
]
++ lib.optionals stdenv.hostPlatform.isLinux [ udev ];
doInstallCheck = true;
nativeInstallCheckInputs = [ versionCheckHook ];
versionCheckProgram = "${placeholder "out"}/bin/solana";
versionCheckProgramArg = "--version";
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd solana \
--bash <($out/bin/solana completion --shell bash) \
--fish <($out/bin/solana completion --shell fish)
mkdir -p $out/bin/platform-tools-sdk
cp -r ./platform-tools-sdk/sbf $out/bin/platform-tools-sdk
mkdir -p $out/bin/deps
find . -name libsolana_program.dylib -exec cp {} $out/bin/deps \;
find . -name libsolana_program.rlib -exec cp {} $out/bin/deps \;
'';
# Used by build.rs in the rocksdb-sys crate. If we don't set these, it would
# try to build RocksDB from source.
ROCKSDB_LIB_DIR = "${rocksdb}/lib";
# Require this on darwin otherwise the compiler starts rambling about missing
# cmath functions
CPPFLAGS = lib.optionals stdenv.hostPlatform.isDarwin "-isystem ${lib.getInclude stdenv.cc.libcxx}/include/c++/v1";
LDFLAGS = lib.optionals stdenv.hostPlatform.isDarwin "-L${lib.getLib stdenv.cc.libcxx}/lib";
# If set, always finds OpenSSL in the system, even if the vendored feature is enabled.
OPENSSL_NO_VENDOR = 1;
meta = with lib; {
description = "Web-Scale Blockchain for fast, secure, scalable, decentralized apps and marketplaces";
homepage = "https://solana.com";
license = licenses.asl20;
maintainers = with maintainers; [
netfox
happysalada
aikooo7
JacoMalan1
];
platforms = platforms.unix;
};
passthru.updateScript = nix-update-script { };
}

View File

@@ -0,0 +1,14 @@
diff --git a/Makefile.am b/Makefile.am
index 19e7b396..21093521 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -35,9 +35,6 @@ include/serno.h:
echo '#define DATECODE 0UL' >>include/serno.h; \
fi
-install-data-hook:
- test -d ${DESTDIR}${logdir} || mkdir -p ${DESTDIR}${logdir}
-
install-exec-hook:
rm -f ${DESTDIR}${libdir}/*.la
rm -f ${DESTDIR}${moduledir}/*.la

View File

@@ -0,0 +1,91 @@
{
lib,
stdenv,
autoconf,
automake,
libtool,
bison,
fetchFromGitHub,
flex,
lksctp-tools,
openssl,
pkg-config,
sqlite,
util-linux,
unstableGitUpdater,
nixosTests,
}:
stdenv.mkDerivation {
pname = "solanum";
version = "0-unstable-2025-09-20";
src = fetchFromGitHub {
owner = "solanum-ircd";
repo = "solanum";
rev = "380dca67c2f270f1b60634b6ed9a90c80884684d";
hash = "sha256-R+TXRFzTVWxWVRSmPgmFjYplEonDKszsBckPWUS+gOU=";
};
patches = [
./dont-create-logdir.patch
];
postPatch = ''
substituteInPlace include/defaults.h --replace 'ETCPATH "' '"/etc/solanum'
'';
preConfigure = ''
./autogen.sh
'';
configureFlags = [
"--enable-epoll"
"--enable-ipv6"
"--enable-openssl=${openssl.dev}"
"--with-program-prefix=solanum-"
"--localstatedir=/var/lib"
"--with-rundir=/run"
"--with-logdir=/var/log"
]
++ lib.optionals (stdenv.hostPlatform.isLinux) [
"--enable-sctp=${lksctp-tools.out}/lib"
];
nativeBuildInputs = [
autoconf
automake
libtool
bison
flex
pkg-config
util-linux
];
buildInputs = [
openssl
sqlite
];
doCheck = !stdenv.hostPlatform.isDarwin;
enableParallelBuilding = true;
# Missing install depends:
# ...-binutils-2.40/bin/ld: cannot find ./.libs/libircd.so: No such file or directory
# collect2: error: ld returned 1 exit status
# make[4]: *** [Makefile:634: solanum] Error 1
enableParallelInstalling = false;
passthru = {
tests = { inherit (nixosTests) solanum; };
updateScript = unstableGitUpdater { };
};
meta = with lib; {
description = "IRCd for unified networks";
homepage = "https://github.com/solanum-ircd/solanum";
license = licenses.gpl2Plus;
maintainers = with maintainers; [ hexa ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,46 @@
{
lib,
stdenv,
fetchFromGitHub,
autoconf,
automake,
pkg-config,
gtk-engine-murrine,
gtk3,
}:
stdenv.mkDerivation {
pname = "solarc-gtk-theme";
version = "1.0.2";
src = fetchFromGitHub {
owner = "schemar";
repo = "solarc-theme";
rev = "d1eb117325b8e5085ecaf78df2eb2413423fc643";
sha256 = "005b66whyxba3403yzykpnlkz0q4m154pxpb4jzcny3fggy9r70s";
};
nativeBuildInputs = [
autoconf
automake
pkg-config
gtk3
];
propagatedUserEnvPkgs = [
gtk-engine-murrine
gtk3
];
buildPhase = ''
./autogen.sh --prefix=$out
'';
meta = with lib; {
description = "Solarized version of the Arc theme";
homepage = "https://github.com/schemar/solarc-theme";
license = licenses.gpl3;
maintainers = [ ];
platforms = platforms.linux;
};
}

View File

@@ -0,0 +1,34 @@
diff --git a/launcher/cmake/addDependencies.cmake b/launcher/cmake/addDependencies.cmake
index d2927668e..dc8309de2 100644
--- a/cmake/addDependencies.cmake
+++ b/cmake/addDependencies.cmake
@@ -20,8 +20,7 @@ include(FetchContent)
# Qlementine-Icons: an SVG icon library made for Qt.
FetchContent_Declare(qlementine-icons
- GIT_REPOSITORY "https://github.com/oclero/qlementine-icons.git"
- GIT_TAG v1.8.0
+ SOURCE_DIR "@qlementine-icons-src@"
EXCLUDE_FROM_ALL
)
FetchContent_MakeAvailable(qlementine-icons)
@@ -34,8 +33,7 @@ set_target_properties(qlementine-icons
# Qlementine: the QStyle library to have a modern look n' feel.
FetchContent_Declare(qlementine
- GIT_REPOSITORY "https://github.com/oclero/qlementine.git"
- GIT_TAG v1.2.1
+ SOURCE_DIR "@qlementine-src@"
EXCLUDE_FROM_ALL
)
FetchContent_MakeAvailable(qlementine)
@@ -48,8 +46,7 @@ set_target_properties(qlementine
# QtAppInstanceManager: a library to manage multiple instances of a Qt application.
FetchContent_Declare(QtAppInstanceManager
- GIT_REPOSITORY "https://github.com/oclero/qtappinstancemanager.git"
- GIT_TAG v1.3.0
+ SOURCE_DIR "@qtappinstancemanager-src@"
EXCLUDE_FROM_ALL
)
FetchContent_MakeAvailable(QtAppInstanceManager)

View File

@@ -0,0 +1,78 @@
{
lib,
stdenv,
replaceVars,
cmake,
ninja,
luajit,
SDL2,
SDL2_image,
SDL2_ttf,
physfs,
openal,
libmodplug,
libvorbis,
solarus,
glm,
qt6,
qlementine,
qlementine-icons,
qtappinstancemanager,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "solarus-launcher";
inherit (solarus) version;
src = solarus.src + "/launcher";
patches = [
(replaceVars ./github-fetches.patch {
qlementine-src = qlementine.src;
qlementine-icons-src = qlementine-icons.src;
qtappinstancemanager-src = qtappinstancemanager.src;
})
];
strictDeps = true;
nativeBuildInputs = [
cmake
ninja
qt6.qttools
qt6.wrapQtAppsHook
];
buildInputs = [
luajit
SDL2
SDL2_image
SDL2_ttf
physfs
openal
libmodplug
libvorbis
solarus
qt6.qtbase
qt6.qtsvg
glm
];
meta = {
description = "Launcher for the Zelda-like ARPG game engine, Solarus";
longDescription = ''
Solarus is a game engine for Zelda-like ARPG games written in lua.
Many full-fledged games have been writen for the engine.
Games can be created easily using the editor.
'';
homepage = "https://www.solarus-games.org";
mainProgram = "solarus-launcher";
license = with lib.licenses; [
# code
gpl3Plus
# assets
cc-by-sa-40
];
maintainers = with lib.maintainers; [ marcin-serwin ];
platforms = lib.platforms.linux;
};
})

View File

@@ -0,0 +1,67 @@
{
lib,
stdenv,
qlementine,
cmake,
ninja,
luajit,
SDL2,
SDL2_image,
SDL2_ttf,
physfs,
openal,
libmodplug,
libvorbis,
solarus,
glm,
qt6,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "solarus-quest-editor";
inherit (solarus) version;
src = solarus.src + "/editor";
strictDeps = true;
nativeBuildInputs = [
cmake
ninja
qt6.qttools
qt6.wrapQtAppsHook
];
buildInputs = [
luajit
SDL2
SDL2_image
SDL2_ttf
physfs
openal
libmodplug
libvorbis
solarus
qt6.qtbase
qt6.qtsvg
glm
];
cmakeFlags = [
(lib.cmakeBool "SOLARUS_USE_LOCAL_QLEMENTINE" true)
(lib.cmakeFeature "SOLARUS_QLEMENTINE_LOCAL_PATH" "${qlementine.src}")
];
meta = {
description = "Editor for the Zelda-like ARPG game engine, Solarus";
mainProgram = "solarus-editor";
longDescription = ''
Solarus is a game engine for Zelda-like ARPG games written in lua.
Many full-fledged games have been writen for the engine.
Games can be created easily using the editor.
'';
homepage = "https://www.solarus-games.org";
license = lib.licenses.gpl3;
maintainers = with lib.maintainers; [ marcin-serwin ];
platforms = lib.platforms.linux;
};
})

View File

@@ -0,0 +1,83 @@
{
lib,
stdenv,
fetchFromGitLab,
cmake,
ninja,
luajit,
SDL2,
SDL2_image,
SDL2_ttf,
physfs,
glm,
openal,
libmodplug,
libvorbis,
# tests
solarus-quest-editor,
solarus-launcher,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "solarus";
version = "2.0.1";
src = fetchFromGitLab {
owner = "solarus-games";
repo = "solarus";
rev = "e70e3df7369d690615fc4c9b3f8dfa00066c5e87";
hash = "sha256-NOHv4b+r2WnyHEVLtcox+8+3Q3TtSDHB7vpKSTDHVKM=";
};
outputs = [
"out"
"lib"
"dev"
];
strictDeps = true;
nativeBuildInputs = [
cmake
ninja
];
buildInputs = [
luajit
SDL2
SDL2_image
SDL2_ttf
physfs
openal
libmodplug
libvorbis
glm
];
cmakeFlags = [
(lib.cmakeFeature "CMAKE_CXX_FLAGS" "-DGLM_ENABLE_EXPERIMENTAL")
(lib.cmakeFeature "CMAKE_INSTALL_DATADIR" "${placeholder "lib"}/share")
];
passthru.tests = {
inherit solarus-quest-editor solarus-launcher;
};
meta = {
description = "Zelda-like ARPG game engine";
longDescription = ''
Solarus is a game engine for Zelda-like ARPG games written in lua.
Many full-fledged games have been writen for the engine.
'';
homepage = "https://www.solarus-games.org";
mainProgram = "solarus-run";
license = with lib.licenses; [
# code
gpl3Plus
# assets
cc-by-sa-30
cc-by-sa-40
];
maintainers = with lib.maintainers; [ marcin-serwin ];
platforms = lib.platforms.linux;
};
})

View File

@@ -0,0 +1,183 @@
{
lib,
gccStdenv,
fetchzip,
pkgs,
boost,
cmake,
jq,
ncurses,
python3,
versionCheckHook,
z3Support ? true,
z3 ? null,
cvc4Support ? gccStdenv.hostPlatform.isLinux,
cvc4 ? null,
cln ? null,
gmp ? null,
}:
# compiling source/libsmtutil/CVC4Interface.cpp breaks on clang on Darwin,
# general commandline tests fail at abiencoderv2_no_warning/ on clang on NixOS
assert z3Support -> z3 != null && lib.versionAtLeast z3.version "4.11.0";
assert cvc4Support -> cvc4 != null && cln != null && gmp != null;
let
pname = "solc";
version = "0.8.28";
linuxHash = "sha256-kosJ10stylGK5NUtsnMM7I+OfhR40TXPQDvnggOFLLc=";
darwinHash = "sha256-gVFbDlPeqiZtVJVFzKrApalubU6CAcd/ZzsscQl22eo=";
nativeInstallCheckInputs = [
versionCheckHook
];
versionCheckProgramArg = "--version";
doInstallCheck = true;
meta = {
description = "Compiler for Ethereum smart contract language Solidity";
homepage = "https://github.com/ethereum/solidity";
changelog = "https://github.com/ethereum/solidity/releases/tag/v${version}";
license = lib.licenses.gpl3;
maintainers = with lib.maintainers; [
dbrock
akru
lionello
sifmelcara
];
};
solc =
if gccStdenv.hostPlatform.isLinux then
gccStdenv.mkDerivation rec {
inherit
pname
version
nativeInstallCheckInputs
versionCheckProgramArg
doInstallCheck
meta
;
# upstream suggests avoid using archive generated by github
src = fetchzip {
url = "https://github.com/ethereum/solidity/releases/download/v${version}/solidity_${version}.tar.gz";
hash = linuxHash;
};
# Fix build with GCC 14
# Submitted upstream: https://github.com/ethereum/solidity/pull/15685
postPatch = ''
substituteInPlace test/yulPhaser/Chromosome.cpp \
--replace-fail \
"BOOST_TEST(abs" \
"BOOST_TEST(fabs"
'';
cmakeFlags = [
"-DBoost_USE_STATIC_LIBS=OFF"
]
++ (
if z3Support then
[
"-DSTRICT_Z3_VERSION=OFF"
]
else
[
"-DUSE_Z3=OFF"
]
)
++ lib.optionals (!cvc4Support) [
"-DUSE_CVC4=OFF"
];
nativeBuildInputs = [ cmake ];
buildInputs = [
boost
]
++ lib.optionals z3Support [ z3 ]
++ lib.optionals cvc4Support [
cvc4
cln
gmp
];
nativeCheckInputs = [
jq
ncurses
(python3.withPackages (
ps: with ps; [
colorama
deepdiff
devtools
docopt
docutils
requests
sphinx
tabulate
z3-solver
]
))
]; # contextlib2 glob2 textwrap3 traceback2 urllib3
enableParallelBuilding = true;
# tests take 60+ minutes to complete, only run as part of passthru tests
doCheck = false;
checkPhase = ''
pushd ..
# IPC tests need aleth avaliable, so we disable it
sed -i "s/IPC_ENABLED=true/IPC_ENABLED=false\nIPC_FLAGS=\"--no-ipc\"/" ./scripts/tests.sh
for i in ./scripts/*.sh ./scripts/*.py ./test/*.sh ./test/*.py; do
patchShebangs "$i"
done
## TODO: reenable tests below after adding evmone and hera and their dependencies to nixpkgs
#TERM=xterm ./scripts/tests.sh ${lib.optionalString z3Support "--no-smt"}
popd
'';
installCheckPhase = ''
runHook preInstallCheck
$out/bin/solc --version > /dev/null
runHook postInstallCheck
'';
passthru.tests = {
solcWithTests = solc.overrideAttrs (attrs: {
doCheck = true;
});
};
}
else
gccStdenv.mkDerivation rec {
inherit
pname
version
nativeInstallCheckInputs
versionCheckProgramArg
doInstallCheck
meta
;
src = pkgs.fetchurl {
url = "https://github.com/ethereum/solidity/releases/download/v${version}/solc-macos";
hash = darwinHash;
};
dontUnpack = true;
installPhase = ''
runHook preInstall
mkdir -p $out/bin
cp ${src} $out/bin/solc
chmod +x $out/bin/solc
runHook postInstall
'';
};
in
solc

View File

@@ -0,0 +1,33 @@
Fix theme parsing errors: https://savannah.gnu.org/bugs/index.php?53107
--- a/solfege.css
+++ b/solfege.css
@@ -7,19 +7,19 @@
-#ProgressionNameLabel, #Feedback { font: "Sans 18" }
-#ProgressionLabelNumber { font: "Sans 12" }
-#BoldText { font: Bold }
+#ProgressionNameLabel, #Feedback { font: 18px Sans }
+#ProgressionLabelNumber { font: 12px Sans }
+#BoldText { font: 12px Sans Bold }
-#StatisticsH1, #Heading1 { font: Sans 18 }
-#StatisticsH2, #Heading2 { font: Sans 14 }
+#StatisticsH1, #Heading1 { font: 18px Sans }
+#StatisticsH2, #Heading2 { font: 14px Sans }
-#BpmInactiveLabel { font: Sans 12 }
-#BpmActiveLabel { font: Sans Bold 12 }
+#BpmInactiveLabel { font: 12px Sans }
+#BpmActiveLabel { font: 12px Sans Bold }
#DIALOGWARNING2 { background: red; }
#DIALOGWARNING { background: yellow; }
#DEBUGWARNING {
background: red;
- font: Sans Bold 24;
+ font: 24px Sans Bold;
}
-#FlashBarLabel { font: Sans 16 }
+#FlashBarLabel { font: 16px Sans }

View File

@@ -0,0 +1,7 @@
Fix https://savannah.gnu.org/bugs/index.php?53109
--- a/solfege/mainwin.py
+++ b/solfege/mainwin.py
@@ -270,1 +270,1 @@
- hdlbox = Gtk.HandleBox()
+ hdlbox = Gtk.HBox()

View File

@@ -0,0 +1,98 @@
{
lib,
alsa-utils,
autoconf,
automake,
csound,
fetchurl,
gdk-pixbuf,
gettext,
gobject-introspection,
gtk3,
librsvg,
lilypond,
mpg123,
pkg-config,
python3Packages,
texinfo,
timidity,
txt2man,
vorbis-tools,
wrapGAppsHook3,
}:
python3Packages.buildPythonApplication rec {
pname = "solfege";
version = "3.23.4";
format = "other";
src = fetchurl {
url = "https://alpha.gnu.org/gnu/solfege/solfege-${version}.tar.gz";
hash = "sha256-t6JJxgGk5hpN76o9snxtM07tkYnwpQ808M/8Ttw+gWk=";
};
patches = [
./css.patch
./menubar.patch
./texinfo.patch
./webbrowser.patch
];
preConfigure = ''
aclocal
autoconf
'';
nativeBuildInputs = [
autoconf
automake
gdk-pixbuf
gettext
gobject-introspection
pkg-config
texinfo
txt2man
wrapGAppsHook3
];
buildInputs = [
gtk3
librsvg
];
propagatedBuildInputs = with python3Packages; [
pycairo
pygobject3
];
preBuild = ''
sed -i -e 's|wav_player=.*|wav_player=${alsa-utils}/bin/aplay|' \
-e 's|midi_player=.*|midi_player=${timidity}/bin/timidity|' \
-e 's|mp3_player=.*|mp3_player=${mpg123}/bin/mpg123|' \
-e 's|ogg_player=.*|ogg_player=${vorbis-tools}/bin/ogg123|' \
-e 's|csound=.*|csound=${csound}/bin/csound|' \
-e 's|lilypond-book=.*|lilypond-book=${lilypond}/bin/lilypond-book|' \
default.config
'';
dontWrapGApps = true;
preFixup = ''
makeWrapperArgs+=("''${gappsWrapperArgs[@]}")
'';
enableParallelBuilding = true;
meta = with lib; {
description = "Ear training program";
homepage = "https://www.gnu.org/software/solfege/";
license = licenses.gpl3Only;
platforms = platforms.linux;
maintainers = with maintainers; [
bjornfor
orivej
anthonyroussel
];
mainProgram = "solfege";
};
}

View File

@@ -0,0 +1,20 @@
Fix build with texinfo 6.7. Otherwise
makeinfo -I topdocs --no-split --no-headers --output AUTHORS topdocs/AUTHORS.texi
fails with
utf8 "\xC1" does not map to Unicode at /nix/store/...-texinfo-6.7/share/texinfo/Texinfo/ParserNonXS.pm line 1796, <FH> line 38.
--- a/topdocs/AUTHORS.texi
+++ b/topdocs/AUTHORS.texi
@@ -1,2 +1,3 @@
\input texinfo
+@documentencoding ISO-8859-1
@setfilename AUTHORS.info
--- a/topdocs/README.texi
+++ b/topdocs/README.texi
@@ -1,2 +1,3 @@
\input texinfo
+@documentencoding ISO-8859-1
@setfilename README.info

View File

@@ -0,0 +1,8 @@
Fix startup.
--- a/solfege/mainwin.py
+++ b/solfege/mainwin.py
@@ -27,2 +27,3 @@ import textwrap
try:
+ webbrowser.register_standard_browsers()
i = webbrowser._tryorder.index("x-www-browser")

View File

@@ -0,0 +1,43 @@
{
stdenv,
lib,
fetchFromGitHub,
ncurses,
}:
stdenv.mkDerivation {
pname = "solicurses";
version = "0-unstable-2020-02-13";
src = fetchFromGitHub {
owner = "KaylaPP";
repo = "SoliCurses";
rev = "dc89ca00fc1711dc449d0a594a4727af22fc35a0";
sha256 = "sha256-zWYXpvEnViT/8gsdMU9Ymi4Hw+nwkG6FT/3h5sNMCE4=";
};
buildInputs = [
ncurses
];
preBuild = ''
cd build
'';
makeFlags = [
"CC=${stdenv.cc.targetPrefix}c++"
];
installPhase = ''
install -D SoliCurses.out $out/bin/solicurses
'';
meta = with lib; {
description = "Version of Solitaire written in C++ using the ncurses library";
mainProgram = "solicurses";
homepage = "https://github.com/KaylaPP/SoliCurses";
maintainers = with maintainers; [ laalsaas ];
license = licenses.gpl3Only;
inherit (ncurses.meta) platforms;
};
}

View File

@@ -0,0 +1,32 @@
{
lib,
fetchFromGitHub,
buildGoModule,
}:
buildGoModule {
pname = "solitaire-tui";
version = "0-unstable-2023-04-20";
src = fetchFromGitHub {
owner = "brianstrauch";
repo = "solitaire-tui";
rev = "45fffc4b13dbf1056f25a01c612dd835ddab5501";
hash = "sha256-xbqKtqFVvL+1x/SDoMEJ1LgnTy31LmZ/Je8K/bhP2bI=";
};
vendorHash = "sha256-jFbxT0ekimBNjIHGgMmCUrwZTS3Sdop/MFQMVdBF/38=";
ldflags = [
"-s"
"-w"
];
meta = with lib; {
homepage = "https://github.com/brianstrauch/solitaire-tui";
description = "Klondike solitaire for the terminal";
mainProgram = "solitaire-tui";
maintainers = with maintainers; [ nyadiia ];
license = licenses.asl20;
};
}

View File

@@ -0,0 +1,43 @@
{
lib,
stdenv,
fetchurl,
gmp,
mpfr,
mpfi,
libxml2,
fplll,
}:
stdenv.mkDerivation rec {
pname = "sollya";
version = "8.0";
src = fetchurl {
url = "https://www.sollya.org/releases/sollya-${version}/sollya-${version}.tar.gz";
sha256 = "sha256-WNc0+aL8jmczwR+W0t+aslvvJNccQBIw4p8KEzmoEZI=";
};
buildInputs = [
gmp
mpfr
mpfi
libxml2
fplll
];
configureFlags = [
"--with-xml2-config=${lib.getExe' (lib.getDev libxml2) "xml2-config"}"
];
doCheck = true;
meta = with lib; {
description = "Tool environment for safe floating-point code development";
mainProgram = "sollya";
homepage = "https://www.sollya.org/";
license = licenses.cecill-c;
platforms = platforms.unix;
maintainers = with maintainers; [ wegank ];
};
}

View File

@@ -0,0 +1,60 @@
{
lib,
stdenv,
rustPlatform,
fetchFromGitHub,
installShellFiles,
pkg-config,
pcsclite,
udev,
udevCheckHook,
}:
rustPlatform.buildRustPackage rec {
pname = "solo2-cli";
version = "0.2.2";
src = fetchFromGitHub {
owner = "solokeys";
repo = "solo2-cli";
rev = "v${version}";
sha256 = "sha256-7tpO5ir42mIKJXD0NJzEPXi/Xe6LdyEeBQWNfOdgX5I=";
};
cargoHash = "sha256-qD185H6wfW9yuYImTm9hqSgQpUQcKuCESM8riZwmGY0=";
nativeBuildInputs = [
installShellFiles
pkg-config
udevCheckHook
];
buildInputs =
[ ]
++ lib.optionals stdenv.hostPlatform.isLinux [
pcsclite
udev
];
postInstall = ''
install -D 70-solo2.rules $out/lib/udev/rules.d/70-solo2.rules
installShellCompletion target/*/release/solo2.{bash,fish}
installShellCompletion --zsh target/*/release/_solo2
'';
doCheck = true;
doInstallCheck = true;
buildFeatures = [ "cli" ];
meta = with lib; {
description = "CLI tool for managing SoloKeys' Solo2 USB security keys";
homepage = "https://github.com/solokeys/solo2-cli";
license = with licenses; [
asl20
mit
]; # either at your option
maintainers = with maintainers; [ lukegb ];
mainProgram = "solo2";
};
}

View File

@@ -0,0 +1,112 @@
{
lib,
stdenv,
fetchurl,
dosfstools,
libseccomp,
makeWrapper,
mtools,
parted,
pkg-config,
qemu_test,
syslinux,
util-linux,
}:
let
version = "0.9.3";
# list of all theoretically available targets
targets = [
"genode"
"hvt"
"muen"
"spt"
"virtio"
"xen"
];
in
stdenv.mkDerivation {
pname = "solo5";
inherit version;
nativeBuildInputs = [
makeWrapper
pkg-config
];
buildInputs = lib.optional (stdenv.hostPlatform.isLinux) libseccomp;
src = fetchurl {
url = "https://github.com/Solo5/solo5/releases/download/v${version}/solo5-v${version}.tar.gz";
hash = "sha256-KbeY667Y/ZPUuRIGYOZMMAuVEVJ7Kn9UDUSThX5zfII=";
};
hardeningEnable = [ "pie" ];
configurePhase = ''
runHook preConfigure
sh configure.sh --prefix=/
runHook postConfigure
'';
enableParallelBuilding = true;
separateDebugInfo = true;
# debugging requires information for both the unikernel and the tender
installPhase = ''
runHook preInstall
export DESTDIR=$out
export PREFIX=$out
make install
substituteInPlace $out/bin/solo5-virtio-mkimage \
--replace "/usr/lib/syslinux" "${syslinux}/share/syslinux" \
--replace "/usr/share/syslinux" "${syslinux}/share/syslinux" \
--replace "cp " "cp --no-preserve=mode "
wrapProgram $out/bin/solo5-virtio-mkimage \
--prefix PATH : ${
lib.makeBinPath [
dosfstools
mtools
parted
syslinux
]
}
runHook postInstall
'';
doCheck = stdenv.hostPlatform.isLinux;
nativeCheckInputs = [
util-linux
qemu_test
];
checkPhase = ''
runHook preCheck
patchShebangs tests
substituteInPlace scripts/virtio-run/solo5-virtio-run.sh \
--replace " -no-acpi" ""
./tests/bats-core/bats ./tests/tests.bats
runHook postCheck
'';
meta = with lib; {
description = "Sandboxed execution environment";
homepage = "https://github.com/solo5/solo5";
license = licenses.isc;
platforms = mapCartesianProduct ({ arch, os }: "${arch}-${os}") {
arch = [
"aarch64"
"x86_64"
];
os = [
"freebsd"
"genode"
"linux"
"openbsd"
];
};
};
}

View File

@@ -0,0 +1,103 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
pkg-config,
wrapGAppsHook3,
at-spi2-core,
cairo,
dbus,
eigen,
freetype,
fontconfig,
glew,
gtkmm3,
json_c,
libdatrie,
libepoxy,
libGLU,
libpng,
libselinux,
libsepol,
libspnav,
libthai,
libxkbcommon,
pangomm,
pcre,
util-linuxMinimal, # provides libmount
xorg,
zlib,
}:
stdenv.mkDerivation rec {
pname = "solvespace";
version = "3.1";
src = fetchFromGitHub {
owner = "solvespace";
repo = "solvespace";
rev = "v${version}";
hash = "sha256-sSDht8pBrOG1YpsWfC/CLTTWh2cI5pn2PXGH900Z0yA=";
fetchSubmodules = true;
};
nativeBuildInputs = [
cmake
pkg-config
wrapGAppsHook3
];
buildInputs = [
at-spi2-core
cairo
dbus
eigen
freetype
fontconfig
glew
gtkmm3
json_c
libdatrie
libepoxy
libGLU
libpng
libselinux
libsepol
libspnav
libthai
libxkbcommon
pangomm
pcre
util-linuxMinimal
xorg.libpthreadstubs
xorg.libXdmcp
xorg.libXtst
zlib
];
postPatch = ''
patch CMakeLists.txt <<EOF
@@ -20,9 +20,9 @@
# NOTE TO PACKAGERS: The embedded git commit hash is critical for rapid bug triage when the builds
# can come from a variety of sources. If you are mirroring the sources or otherwise build when
# the .git directory is not present, please comment the following line:
-include(GetGitCommitHash)
+# include(GetGitCommitHash)
# and instead uncomment the following, adding the complete git hash of the checkout you are using:
-# set(GIT_COMMIT_HASH 0000000000000000000000000000000000000000)
+set(GIT_COMMIT_HASH $version)
EOF
'';
cmakeFlags = [ "-DENABLE_OPENMP=ON" ];
meta = {
description = "Parametric 3d CAD program";
license = lib.licenses.gpl3Plus;
maintainers = [ lib.maintainers.edef ];
platforms = lib.platforms.linux;
homepage = "https://solvespace.com";
changelog = "https://github.com/solvespace/solvespace/raw/v${version}/CHANGELOG.md";
};
}

View File

@@ -0,0 +1,43 @@
{
lib,
stdenv,
fetchFromGitHub,
makeWrapper,
curl,
jq,
mpv,
}:
stdenv.mkDerivation rec {
pname = "somafm-cli";
version = "0.3.1";
src = fetchFromGitHub {
owner = "rockymadden";
repo = "somafm-cli";
rev = "v${version}";
sha256 = "1h5p9qsczgfr450sklh2vkllcpzb7nicbs8ciyvkavh3d7hds0yy";
};
nativeBuildInputs = [ makeWrapper ];
installPhase = ''
install -m0755 -D src/somafm $out/bin/somafm
wrapProgram $out/bin/somafm --prefix PATH ":" "${
lib.makeBinPath [
curl
jq
mpv
]
}";
'';
meta = with lib; {
description = "Listen to SomaFM in your terminal via pure bash";
homepage = "https://github.com/rockymadden/somafm-cli";
license = licenses.mit;
platforms = platforms.all;
maintainers = with maintainers; [ SuperSandro2000 ];
mainProgram = "somafm";
};
}

View File

@@ -0,0 +1,40 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
zlib,
ncurses,
}:
stdenv.mkDerivation rec {
pname = "somatic-sniper";
version = "1.0.5.0";
src = fetchFromGitHub {
owner = "genome";
repo = "somatic-sniper";
rev = "v${version}";
sha256 = "0lk7p9sp6mp50f6w1nppqhr40fcwy1asw06ivw8w8jvvnwaqf987";
};
patches = [ ./somatic-sniper.patch ];
nativeBuildInputs = [ cmake ];
buildInputs = [
zlib
ncurses
];
enableParallelBuilding = false;
meta = with lib; {
description = "Identify single nucleotide positions that are different between tumor and normal";
mainProgram = "bam-somaticsniper";
license = licenses.mit;
homepage = "https://github.com/genome/somatic-sniper";
maintainers = with maintainers; [ jbedo ];
platforms = platforms.linux;
};
}

View File

@@ -0,0 +1,26 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6d5a180..7254292 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,7 +11,7 @@ set(CMAKE_MODULE_PATH
)
include(TestHelper)
-include(VersionHelper)
+#include(VersionHelper)
include(ProjectHelper)
# NOTE: for sniper we want the exe suffix to be like 0.7.4, not just 0.7
diff --git a/vendor/samtools.patch b/vendor/samtools.patch
index f173017..654f878 100644
--- a/vendor/samtools.patch
+++ b/vendor/samtools.patch
@@ -6,7 +6,7 @@ diff -Nuar a/Makefile b/Makefile
samtools:lib $(AOBJS)
- $(CC) $(CFLAGS) -o $@ $(AOBJS) -lm $(LIBPATH) $(LIBCURSES) -lz -L. -lbam
-+ $(CC) $(CFLAGS) -o $@ $(AOBJS) -lm $(LIBPATH) $(LIBCURSES) -L. -lbam -lz
++ $(CC) $(CFLAGS) -o $@ $(AOBJS) -lm $(LIBPATH) -lncurses -L. -lbam -lz
razip:razip.o razf.o
$(CC) $(CFLAGS) -o $@ razf.o razip.o -lz

View File

@@ -0,0 +1,55 @@
{
lib,
stdenv,
fetchFromSourcehut,
meson,
ninja,
pkg-config,
wayland,
pango,
wayland-protocols,
wayland-scanner,
conf ? null,
}:
let
# There is a configuration in src/config.def.hpp, which we use by default
configFile = if lib.isDerivation conf || builtins.isPath conf then conf else "src/config.def.hpp";
in
stdenv.mkDerivation rec {
pname = "somebar";
version = "1.0.3";
src = fetchFromSourcehut {
owner = "~raphi";
repo = "somebar";
rev = version;
sha256 = "sha256-PBxCy1dZrOL1nmhVDQozvF0XL79uKMhhERGNpPPzaRU=";
};
nativeBuildInputs = [
meson
ninja
pkg-config
wayland-scanner
];
buildInputs = [
pango
wayland
wayland-protocols
];
prePatch = ''
cp ${configFile} src/config.hpp
'';
meta = with lib; {
homepage = "https://git.sr.ht/~raphi/somebar";
description = "dwm-like bar for dwl";
license = licenses.mit;
maintainers = with maintainers; [ magnouvean ];
platforms = platforms.linux;
mainProgram = "somebar";
};
}

View File

@@ -0,0 +1,67 @@
{
lib,
stdenv,
fetchzip,
meson,
ninja,
pkg-config,
python3,
python3Packages,
wayland-scanner,
libxkbcommon,
libgbm,
pixman,
xorg,
wayland,
gtest,
}:
stdenv.mkDerivation {
pname = "sommelier";
version = "126.0";
src = fetchzip rec {
url = "https://chromium.googlesource.com/chromiumos/platform2/+archive/${passthru.rev}/vm_tools/sommelier.tar.gz";
passthru.rev = "fd3798efe23f2edbc48f86f2fbd82ba5059fd875";
stripRoot = false;
sha256 = "BmWZnMcK7IGaEAkVPulyb3hngsmuI0D1YtQEbqMjV5c=";
};
nativeBuildInputs = [
meson
ninja
pkg-config
python3
python3Packages.jinja2
wayland-scanner
];
buildInputs = [
libxkbcommon
libgbm
pixman
wayland
xorg.libxcb
];
preConfigure = ''
patchShebangs gen-shim.py
'';
doCheck = true;
nativeCheckInputs = [ gtest ];
postInstall = ''
rm $out/bin/sommelier_test # why does it install the test binary? o_O
'';
passthru.updateScript = ./update.py;
meta = with lib; {
homepage = "https://chromium.googlesource.com/chromiumos/platform2/+/refs/heads/main/vm_tools/sommelier/";
description = "Nested Wayland compositor with support for X11 forwarding";
maintainers = with maintainers; [ qyliss ];
license = licenses.bsd3;
platforms = platforms.linux;
mainProgram = "sommelier";
};
}

View File

@@ -0,0 +1,61 @@
#! /usr/bin/env nix-shell
#! nix-shell -p common-updater-scripts python3
#! nix-shell -i python
import csv
import json
import re
import shlex
import subprocess
from os.path import abspath, dirname, splitext
from urllib.request import urlopen
# CrOS version numbers look like this:
# [<chrome-major-version>.]<tip-build>.<branch-build>.<branch-branch-build>
#
# As far as I can tell, branches are where internal Google
# modifications are added to turn Chromium OS into Chrome OS, and
# branch branches are used for fixes for specific devices. So for
# Chromium OS they will always be 0. This is a best guess, and is not
# documented.
with urlopen('https://chromiumdash.appspot.com/cros/download_serving_builds_csv?deviceCategory=ChromeOS') as resp:
reader = csv.reader(map(bytes.decode, resp))
header = next(reader)
cr_stable_index = header.index('cr_stable')
cros_stable_index = header.index('cros_stable')
chrome_version = []
platform_version = []
for line in reader:
this_chrome_version_str = line[cr_stable_index]
if "no update" in this_chrome_version_str:
continue
this_chrome_version = list(map(int, this_chrome_version_str.split('.')))
this_platform_version = list(map(int, line[cros_stable_index].split('.')))
chrome_version = max(chrome_version, this_chrome_version)
platform_version = max(platform_version, this_platform_version)
chrome_major_version = chrome_version[0]
chromeos_tip_build = platform_version[0]
release_branch = f'release-R{chrome_major_version}-{chromeos_tip_build}.B'
# Determine the git revision.
with urlopen(f'https://chromium.googlesource.com/chromiumos/platform2/+/refs/heads/{release_branch}?format=JSON') as resp:
resp.readline() # Remove )]}' header
rev = json.load(resp)['commit']
# Determine the patch version by counting the commits that have been
# added to the release branch since it forked off the chromeos branch.
with urlopen(f'https://chromium.googlesource.com/chromiumos/platform2/+log/refs/heads/main..{rev}/vm_tools/sommelier?format=JSON') as resp:
resp.readline() # Remove )]}' header
branch_commits = json.load(resp)['log']
version = f'{chrome_major_version}.{len(branch_commits)}'
# Update the version, git revision, and hash in sommelier's default.nix.
subprocess.run(['update-source-version', 'sommelier', f'--rev={rev}', version])
# Find the path to sommelier's default.nix, so Cargo.lock can be written
# into the same directory.
argv = ['nix-instantiate', '--eval', '--json', '-A', 'sommelier.meta.position']
position = json.loads(subprocess.check_output(argv).decode('utf-8'))
filename = re.match(r'[^:]*', position)[0]

View File

@@ -0,0 +1,60 @@
{
lib,
stdenv,
rustPlatform,
fetchFromGitHub,
installShellFiles,
versionCheckHook,
nix-update-script,
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "somo";
version = "1.1.0";
src = fetchFromGitHub {
owner = "theopfr";
repo = "somo";
tag = "v${finalAttrs.version}";
hash = "sha256-HUTaBSy3FemAQH1aKZYTJnUWiq0bU/H6c5Gz3yamPiA=";
};
cargoHash = "sha256-e3NrEfbWz6h9q4TJnn8jnRmMJbeaEc4Yo3hFlaRLzzQ=";
nativeBuildInputs = [
installShellFiles
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# Avoids "couldn't find any valid shared libraries matching: ['libclang.dylib']" error on darwin in sandbox mode.
rustPlatform.bindgenHook
];
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd somo \
--bash <("$out/bin/somo" generate-completions bash) \
--zsh <("$out/bin/somo" generate-completions zsh) \
--fish <("$out/bin/somo" generate-completions fish)
'';
nativeInstallCheckInputs = [
versionCheckHook
];
doInstallCheck = true;
versionCheckProgramArg = "--version";
passthru = {
updateScript = nix-update-script { };
};
meta = {
description = "Socket and port monitoring tool";
homepage = "https://github.com/theopfr/somo";
changelog = "https://github.com/theopfr/somo/blob/v${finalAttrs.version}/CHANGELOG.md";
license = lib.licenses.mit;
platforms = with lib.platforms; linux ++ darwin;
maintainers = with lib.maintainers; [
kachick
];
mainProgram = "somo";
};
})

View File

@@ -0,0 +1,22 @@
{
lib,
sonar-scanner-cli,
jre_minimal,
jdk_headless,
}:
sonar-scanner-cli.override {
jre = jre_minimal.override {
jdk = jdk_headless;
modules = [
"java.base"
"java.logging"
"java.naming"
"java.sql"
"java.xml"
"jdk.crypto.ec"
"jdk.jdwp.agent"
"jdk.unsupported"
];
};
}

View File

@@ -0,0 +1,81 @@
{
lib,
coreutils,
fetchFromGitHub,
jre,
libarchive,
makeWrapper,
maven,
nix-update-script,
}:
maven.buildMavenPackage rec {
pname = "sonar-scanner-cli";
version = "7.3.0.5189";
src = fetchFromGitHub {
owner = "SonarSource";
repo = "sonar-scanner-cli";
tag = version;
hash = "sha256-Vbd+vQKFQo/wzGF4ekcCiEczlyuTD41Liz+nePR9lVA=";
};
mvnHash = "sha256-1SPpGu6uQ1Xa0U/DUjfZAXi6SQN/8LImU6THv4e9CSo=";
mvnParameters = "-Dproject.build.outputTimestamp=1980-01-01T00:00:02Z";
nativeBuildInputs = [
# For bsdtar (name is a misnomer since it handles multiple archive formats) to extract nested directories from .zip files.
libarchive
makeWrapper
];
doCheck = false;
# The .zip file with the programs is placed at "target/sonar-scanner-{project.version}.zip".
#
# To compute this .zip file path directly, we need to get the project version from the project's pom.xml.
#
# Parsing pom.xml is unsafe because project versions can be set dynamically. We need to use maven-help-plugin to get the evaluated value instead.
#
# Network isolation, however, prevents Maven from downloading packages in our shell script so we can't do this:
#
# MAVEN_PROJECT_VERSION=$(mvn org.apache.maven.plugins:maven-help-plugin:3.4.1:evaluate \
# -Dmaven.repo.local=.m2 \
# -Dexpression=project.version \
# -DforceStdout \
# --quiet)
#
# We'll use wildcard expansion instead to find (what should be) the only .zip file in the "target" directory.
installPhase = ''
mkdir $out
FILES=(target/sonar-scanner-*.zip)
bsdtar --extract --file ''${FILES[0]} --strip-components 1 --directory $out
wrapProgram $out/bin/sonar-scanner \
--prefix PATH : ${
lib.makeBinPath [
coreutils
jre
]
} \
--set JAVA_HOME ${jre}
wrapProgram $out/bin/sonar-scanner-debug \
--prefix PATH : ${lib.makeBinPath [ coreutils ]}
'';
passthru = {
updateScript = nix-update-script { };
};
meta = {
description = "Scanner CLI for SonarQube and SonarCloud";
homepage = "https://github.com/SonarSource/sonar-scanner-cli";
license = lib.licenses.lgpl3Only;
mainProgram = "sonar-scanner";
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ peterromfeldhk ];
};
}

View File

@@ -0,0 +1,108 @@
{
lib,
fetchFromGitHub,
jre_headless,
maven,
jdk17,
makeWrapper,
writeShellApplication,
curl,
pcre,
common-updater-scripts,
jq,
gnused,
versionCheckHook,
}:
maven.buildMavenPackage rec {
pname = "sonarlint-ls";
version = "3.25.0.76263";
src = fetchFromGitHub {
owner = "SonarSource";
repo = "sonarlint-language-server";
rev = version;
hash = "sha256-bnR6h2NRdGwmx04ydQIlE2VMe/C23YRqNxdbbb19yzE=";
};
mvnJdk = jdk17;
mvnHash = "sha256-cRDrd2QysN3KCndfdnTn8/hXuJ1xd28GcE8vrd6ILuM=";
# Disables failing tests which either need network access or are flaky.
mvnParameters = lib.escapeShellArgs [
"-Dskip.installnodenpm=true"
"-Dskip.npm"
"-Dtest=!LanguageServerMediumTests,
!LanguageServerWithFoldersMediumTests,
!NotebookMediumTests,
!ConnectedModeMediumTests,
!JavaMediumTests,
!OpenNotebooksCacheTests"
];
installPhase = ''
runHook preInstall
mkdir -p $out/{bin,share/plugins}
install -Dm644 target/sonarlint-language-server-*.jar $out/share/sonarlint-ls.jar
install -Dm644 target/plugins/* $out/share/plugins
makeWrapper ${jre_headless}/bin/java $out/bin/sonarlint-ls \
--add-flags "-jar $out/share/sonarlint-ls.jar" \
--add-flags "-analyzers $(ls -1 $out/share/plugins | tr '\n' ' ')"
runHook postInstall
'';
nativeBuildInputs = [ makeWrapper ];
nativeInstallCheckInputs = [ versionCheckHook ];
doInstallCheck = true;
preVersionCheck = "export version=${lib.versions.majorMinor version}";
versionCheckProgramArg = "-V";
passthru.updateScript =
let
pkgFile = toString ./package.nix;
in
lib.getExe (writeShellApplication {
name = "update-${pname}";
runtimeInputs = [
curl
pcre
common-updater-scripts
jq
gnused
];
text = ''
if [ -z "''${GITHUB_TOKEN:-}" ]; then
echo "no GITHUB_TOKEN provided - you could meet API request limiting" >&2
fi
LATEST_TAG=$(curl -H "Accept: application/vnd.github+json" \
''${GITHUB_TOKEN:+-H "Authorization: bearer $GITHUB_TOKEN"} \
-Lsf https://api.github.com/repos/${src.owner}/${src.repo}/tags | \
jq -r '[.[] | select(.name | test("^[0-9]"))] | sort_by(.name | split(".") |
map(tonumber)) | reverse | .[0].name')
update-source-version ${pname} "$LATEST_TAG"
sed -i '0,/mvnHash *= *"[^"]*"/{s/mvnHash = "[^"]*"/mvnHash = ""/}' ${pkgFile}
echo -e "\nFetching all mvn dependencies to calculate the mvnHash. This may take a while ..."
nix-build -A ${pname}.fetchedMavenDeps 2> ${pname}-stderr.log || true
NEW_MVN_HASH=$(grep "got:" ${pname}-stderr.log | awk '{print ''$2}')
rm ${pname}-stderr.log
# escaping double quotes looks ugly but is needed for variable substitution
# use # instead of / as separator because the sha256 might contain the / character
sed -i "0,/mvnHash *= *\"[^\"]*\"/{s#mvnHash = \"[^\"]*\"#mvnHash = \"$NEW_MVN_HASH\"#}" ${pkgFile}
'';
});
meta = {
description = "Sonarlint language server";
mainProgram = "sonarlint-ls";
homepage = "https://github.com/SonarSource/sonarlint-language-server";
license = lib.licenses.lgpl3;
maintainers = with lib.maintainers; [ tricktron ];
};
}

1692
pkgs/by-name/so/sonarr/deps.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,207 @@
{
lib,
stdenvNoCC,
fetchFromGitHub,
buildDotnetModule,
dotnetCorePackages,
sqlite,
withFFmpeg ? true, # replace bundled ffprobe binary with symlink to ffmpeg package.
servarr-ffmpeg,
fetchYarnDeps,
yarn,
fixup-yarn-lock,
nodejs,
nixosTests,
# update script
writers,
python3Packages,
nix,
prefetch-yarn-deps,
fetchpatch,
applyPatches,
}:
let
version = "4.0.15.2941";
# The dotnet8 compatibility patches also change `yarn.lock`, so we must pass
# the already patched lockfile to `fetchYarnDeps`.
src = applyPatches {
src = fetchFromGitHub {
owner = "Sonarr";
repo = "Sonarr";
tag = "v${version}";
hash = "sha256-1lBUkodBDFpJD7pyHAFb8HRLrbK8wyAboX0A2oBQnTM=";
};
postPatch = ''
mv src/NuGet.Config NuGet.Config
'';
patches = lib.optionals (lib.versionOlder version "5.0") [
# See https://github.com/Sonarr/Sonarr/issues/7442 and
# https://github.com/Sonarr/Sonarr/pull/7443.
# Unfortunately, the .NET 8 upgrade was only merged into the v5 branch,
# and it may take some time for that to become stable.
# However, the patches cleanly apply to v4 as well.
(fetchpatch {
name = "dotnet8-compatibility";
url = "https://github.com/Sonarr/Sonarr/commit/518f1799dca96a7481004ceefe39be465de3d72d.patch";
hash = "sha256-e+/rKZrTf6lWq9bmCAwnZrbEPRkqVmI7qNavpLjfpUE=";
})
(fetchpatch {
name = "dotnet8-darwin-compatibility";
url = "https://github.com/Sonarr/Sonarr/commit/1a5fa185d11d2548f45fefb8a0facd3731a946d0.patch";
hash = "sha256-6Lzo4ph1StA05+B1xYhWH+BBegLd6DxHiEiaRxGXn7k=";
})
];
};
rid = dotnetCorePackages.systemToDotnetRid stdenvNoCC.hostPlatform.system;
in
buildDotnetModule {
pname = "sonarr";
inherit version src;
strictDeps = true;
nativeBuildInputs = [
nodejs
yarn
prefetch-yarn-deps
fixup-yarn-lock
];
yarnOfflineCache = fetchYarnDeps {
yarnLock = "${src}/yarn.lock";
hash = "sha256-YkBFvv+g4p22HdM/GQAHVGGW1yLYGWpNtRq7+QJiLIw=";
};
ffprobe = lib.optionalDrvAttr withFFmpeg (lib.getExe' servarr-ffmpeg "ffprobe");
postConfigure = ''
yarn config --offline set yarn-offline-mirror "$yarnOfflineCache"
fixup-yarn-lock yarn.lock
yarn install --offline --frozen-lockfile --ignore-platform --ignore-scripts --no-progress --non-interactive
patchShebangs --build node_modules
'';
postBuild = ''
yarn --offline run build --env production
'';
postInstall =
lib.optionalString withFFmpeg ''
rm -- "$out/lib/sonarr/ffprobe"
ln -s -- "$ffprobe" "$out/lib/sonarr/ffprobe"
''
+ ''
cp -a -- _output/UI "$out/lib/sonarr/UI"
'';
# Add an alias for compatibility with Sonarr v3 package.
postFixup = ''
ln -s -- Sonarr "$out/bin/NzbDrone"
'';
nugetDeps = ./deps.json;
runtimeDeps = [ sqlite ];
dotnet-sdk = dotnetCorePackages.sdk_8_0;
dotnet-runtime = dotnetCorePackages.aspnetcore_8_0;
doCheck = true;
__darwinAllowLocalNetworking = true; # for tests
__structuredAttrs = true; # for Copyright property that contains spaces
executables = [ "Sonarr" ];
projectFile = [
"src/NzbDrone.Console/Sonarr.Console.csproj"
"src/NzbDrone.Mono/Sonarr.Mono.csproj"
];
testProjectFile = [
"src/NzbDrone.Api.Test/Sonarr.Api.Test.csproj"
"src/NzbDrone.Common.Test/Sonarr.Common.Test.csproj"
"src/NzbDrone.Core.Test/Sonarr.Core.Test.csproj"
"src/NzbDrone.Host.Test/Sonarr.Host.Test.csproj"
"src/NzbDrone.Libraries.Test/Sonarr.Libraries.Test.csproj"
"src/NzbDrone.Mono.Test/Sonarr.Mono.Test.csproj"
"src/NzbDrone.Test.Common/Sonarr.Test.Common.csproj"
];
dotnetFlags = [
"--property:TargetFramework=net8.0"
"--property:EnableAnalyzers=false"
"--property:SentryUploadSymbols=false" # Fix Sentry upload failed warnings
# Override defaults in src/Directory.Build.props that use current time.
"--property:Copyright=Copyright 2014-2025 sonarr.tv (GNU General Public v3)"
"--property:AssemblyVersion=${version}"
"--property:AssemblyConfiguration=main"
"--property:RuntimeIdentifier=${rid}"
];
# Skip manual, integration, automation and platform-dependent tests.
dotnetTestFlags = [
"--filter:${
lib.concatStringsSep "&" (
[
"TestCategory!=ManualTest"
"TestCategory!=IntegrationTest"
"TestCategory!=AutomationTest"
# setgid tests
"FullyQualifiedName!=NzbDrone.Mono.Test.DiskProviderTests.DiskProviderFixture.should_preserve_setgid_on_set_folder_permissions"
"FullyQualifiedName!=NzbDrone.Mono.Test.DiskProviderTests.DiskProviderFixture.should_clear_setgid_on_set_folder_permissions"
# we do not set application data directory during tests (i.e. XDG data directory)
"FullyQualifiedName!=NzbDrone.Mono.Test.DiskProviderTests.FreeSpaceFixture.should_return_free_disk_space"
# attempts to read /etc/*release and fails since it does not exist
"FullyQualifiedName!=NzbDrone.Mono.Test.EnvironmentInfo.ReleaseFileVersionAdapterFixture.should_get_version_info"
# fails to start test dummy because it cannot locate .NET runtime for some reason
"FullyQualifiedName!=NzbDrone.Common.Test.ProcessProviderFixture.Should_be_able_to_start_process"
"FullyQualifiedName!=NzbDrone.Common.Test.ProcessProviderFixture.kill_all_should_kill_all_process_with_name"
# makes real HTTP requests
"FullyQualifiedName!~NzbDrone.Core.Test.TvTests.RefreshEpisodeServiceFixture"
"FullyQualifiedName!~NzbDrone.Core.Test.UpdateTests.UpdatePackageProviderFixture"
]
++ lib.optionals stdenvNoCC.buildPlatform.isDarwin [
# fails on macOS
"FullyQualifiedName!~NzbDrone.Core.Test.Http.HttpProxySettingsProviderFixture"
"FullyQualifiedName!=NzbDrone.Common.Test.ServiceFactoryFixture.event_handlers_should_be_unique"
]
)
}"
];
passthru = {
tests = {
inherit (nixosTests) sonarr;
};
updateScript = writers.writePython3 "sonarr-updater" {
libraries = with python3Packages; [ requests ];
makeWrapperArgs = [
"--prefix"
"PATH"
":"
(lib.makeBinPath [
nix
prefetch-yarn-deps
])
];
} ./update.py;
};
meta = {
description = "Smart PVR for newsgroup and bittorrent users";
homepage = "https://sonarr.tv";
license = lib.licenses.gpl3Only;
maintainers = with lib.maintainers; [
fadenb
purcell
tie
niklaskorz
];
mainProgram = "Sonarr";
# platforms inherited from dotnet-sdk.
};
}

View File

@@ -0,0 +1,181 @@
import json
import os
import pathlib
import requests
import shutil
import subprocess
import sys
import tempfile
def replace_in_file(file_path, replacements):
file_contents = pathlib.Path(file_path).read_text()
for old, new in replacements.items():
if old == new:
continue
updated_file_contents = file_contents.replace(old, new)
# A dumb way to check that weve actually replaced the string.
if file_contents == updated_file_contents:
print(f"no string to replace: {old}{new}", file=sys.stderr)
sys.exit(1)
file_contents = updated_file_contents
with tempfile.NamedTemporaryFile(mode="w") as t:
t.write(file_contents)
t.flush()
shutil.copyfile(t.name, file_path)
def nix_hash_to_sri(hash):
return subprocess.run(
[
"nix",
"--extra-experimental-features", "nix-command",
"hash",
"to-sri",
"--type", "sha256",
"--",
hash,
],
stdout=subprocess.PIPE,
text=True,
check=True,
).stdout.rstrip()
nixpkgs_path = "."
attr_path = os.getenv("UPDATE_NIX_ATTR_PATH", "sonarr")
package_attrs = json.loads(subprocess.run(
[
"nix",
"--extra-experimental-features", "nix-command",
"eval",
"--json",
"--file", nixpkgs_path,
"--apply", """p: {
dir = dirOf p.meta.position;
version = p.version;
sourceHash = p.src.src.outputHash;
yarnHash = p.yarnOfflineCache.outputHash;
}""",
"--",
attr_path,
],
stdout=subprocess.PIPE,
text=True,
check=True,
).stdout)
old_version = package_attrs["version"]
new_version = old_version
# Note that we use Sonarr API instead of GitHub to fetch latest stable release.
# This corresponds to the Updates tab in the web UI. See also
# https://github.com/Sonarr/Sonarr/blob/070919a7e6a96ca7e26524996417c6f8d1b5fcaa/src/NzbDrone.Core/Update/UpdatePackageProvider.cs
version_update = requests.get(
f"https://services.sonarr.tv/v1/update/main?version={old_version}",
).json()
if version_update["available"]:
new_version = version_update["updatePackage"]["version"]
if new_version == old_version:
sys.exit()
source_nix_hash, source_store_path = subprocess.run(
[
"nix-prefetch-url",
"--name", "source",
"--unpack",
"--print-path",
f"https://github.com/Sonarr/Sonarr/archive/v{new_version}.tar.gz",
],
stdout=subprocess.PIPE,
text=True,
check=True,
).stdout.rstrip().split("\n")
old_source_hash = package_attrs["sourceHash"]
new_source_hash = nix_hash_to_sri(source_nix_hash)
package_dir = package_attrs["dir"]
package_file_name = "package.nix"
deps_file_name = "deps.json"
# To update deps.nix, we copy the package to a temporary directory and run
# passthru.fetch-deps script there.
with tempfile.TemporaryDirectory() as work_dir:
package_file = os.path.join(work_dir, package_file_name)
deps_file = os.path.join(work_dir, deps_file_name)
shutil.copytree(package_dir, work_dir, dirs_exist_ok=True)
replace_in_file(package_file, {
# NB unlike hashes, versions are likely to be used in code or comments.
# Try to be more specific to avoid false positive matches.
f"version = \"{old_version}\"": f"version = \"{new_version}\"",
old_source_hash: new_source_hash,
})
# We need access to the patched and updated src to get the patched
# `yarn.lock`.
patched_src = os.path.join(work_dir, "patched-src")
subprocess.run(
[
"nix",
"--extra-experimental-features", "nix-command",
"build",
"--impure",
"--nix-path", "",
"--include", f"nixpkgs={nixpkgs_path}",
"--include", f"package={package_file}",
"--expr", "(import <nixpkgs> { }).callPackage <package> { }",
"--out-link", patched_src,
"src",
],
check=True,
)
old_yarn_hash = package_attrs["yarnHash"]
new_yarn_hash = nix_hash_to_sri(subprocess.run(
[
"prefetch-yarn-deps",
# does not support "--" separator :(
# Also --verbose writes to stdout, yikes.
os.path.join(patched_src, "yarn.lock"),
],
stdout=subprocess.PIPE,
text=True,
check=True,
).stdout.rstrip())
replace_in_file(package_file, {
old_yarn_hash: new_yarn_hash,
})
# Generate nuget-to-json dependency lock file.
fetch_deps = os.path.join(work_dir, "fetch-deps")
subprocess.run(
[
"nix",
"--extra-experimental-features", "nix-command",
"build",
"--impure",
"--nix-path", "",
"--include", f"nixpkgs={nixpkgs_path}",
"--include", f"package={package_file}",
"--expr", "(import <nixpkgs> { }).callPackage <package> { }",
"--out-link", fetch_deps,
"passthru.fetch-deps",
],
check=True,
)
subprocess.run(
[
fetch_deps,
deps_file,
],
stdout=subprocess.DEVNULL,
check=True,
)
shutil.copy(deps_file, os.path.join(package_dir, deps_file_name))
shutil.copy(package_file, os.path.join(package_dir, package_file_name))

View File

@@ -0,0 +1,99 @@
{
lib,
fetchFromGitHub,
wrapGAppsHook3,
gettext,
python3Packages,
adwaita-icon-theme,
gtk3,
glib,
gdk-pixbuf,
gsettings-desktop-schemas,
gobject-introspection,
}:
let
inherit (python3Packages)
buildPythonApplication
isPy3k
dbus-python
pygobject3
mpd2
setuptools
;
in
buildPythonApplication rec {
pname = "sonata";
version = "1.7.1";
pyproject = true;
src = fetchFromGitHub {
owner = "multani";
repo = "sonata";
tag = "v${version}";
sha256 = "sha256-80F2dVaRawnI0E+GzaxRUudaLWWHGUjICCEbXHVGy+E=";
};
disabled = !isPy3k;
nativeBuildInputs = [
gettext
gobject-introspection
wrapGAppsHook3
];
buildInputs = [
glib
adwaita-icon-theme
gsettings-desktop-schemas
gtk3
gdk-pixbuf
];
build-system = [ setuptools ];
# The optional tagpy dependency (for editing metadata) is not yet
# included because it's difficult to build.
pythonPath = [
dbus-python
mpd2
pygobject3
setuptools # pkg_resources is imported during runtime
];
postPatch = ''
# Remove "Local MPD" tab which is not suitable for NixOS.
sed -i '/localmpd/d' sonata/consts.py
'';
meta = {
description = "Elegant client for the Music Player Daemon";
mainProgram = "sonata";
longDescription = ''
Sonata is an elegant client for the Music Player Daemon.
Written in Python and using the GTK 3 widget set, its features
include:
- Expanded and collapsed views
- Automatic remote and local album art
- Library browsing by folders, or by genre/artist/album
- User-configurable columns
- Automatic fetching of lyrics
- Playlist and stream support
- Support for editing song tags (not in NixOS version)
- Drag and drop to copy files
- Popup notification
- Library and playlist searching, filter as you type
- Audioscrobbler (last.fm) 1.2 support
- Multiple MPD profiles
- Keyboard friendly
- Support for multimedia keys
- Commandline control
- Available in 24 languages
'';
homepage = "https://www.nongnu.org/sonata/";
license = lib.licenses.gpl3;
platforms = lib.platforms.linux;
};
}

View File

@@ -0,0 +1,50 @@
{
lib,
rustPlatform,
fetchFromGitHub,
gtk3,
openssl,
alsa-lib,
pkg-config,
ffmpeg,
dbus,
libpulseaudio,
}:
rustPlatform.buildRustPackage rec {
pname = "songrec";
version = "0.4.3";
src = fetchFromGitHub {
owner = "marin-m";
repo = "songrec";
rev = version;
hash = "sha256-pTonrxlYvfuLRKMXW0Lao4KCoNFlMzE9rH+hwpa60JY=";
};
cargoHash = "sha256-wSRn1JY067RVqGGdiox87+zRb2/2OMcvKLYZE1QUs/s=";
nativeBuildInputs = [ pkg-config ];
buildInputs = [
alsa-lib
dbus
gtk3
openssl
ffmpeg
libpulseaudio
];
postInstall = ''
mv packaging/rootfs/usr/share $out/share
'';
meta = with lib; {
description = "Open-source Shazam client for Linux, written in Rust";
homepage = "https://github.com/marin-m/SongRec";
license = licenses.gpl3Only;
platforms = platforms.linux;
maintainers = with maintainers; [ tcbravo ];
mainProgram = "songrec";
};
}

View File

@@ -0,0 +1,69 @@
{
lib,
stdenv,
fetchFromGitHub,
nix-update-script,
nixosTests,
rustPlatform,
sonic-server,
testers,
}:
rustPlatform.buildRustPackage rec {
pname = "sonic-server";
version = "1.4.9";
src = fetchFromGitHub {
owner = "valeriansaliou";
repo = "sonic";
tag = "v${version}";
hash = "sha256-PTujR3ciLRvbpiqStNMx3W5fkUdW2dsGmCj/iFRTKJM=";
};
cargoHash = "sha256-RO4wY7FMwczZeR4GOxA3mwfBJZKPToOJJKGZb48yHJA=";
nativeBuildInputs = [
rustPlatform.bindgenHook
];
postPatch = ''
substituteInPlace src/main.rs \
--replace-fail "./config.cfg" "$out/etc/sonic/config.cfg"
'';
postInstall = ''
install -Dm444 -t $out/etc/sonic config.cfg
install -Dm444 -t $out/lib/systemd/system debian/sonic.service
substituteInPlace $out/lib/systemd/system/sonic.service \
--replace-fail /usr/bin/sonic $out/bin/sonic \
--replace-fail /etc/sonic.cfg $out/etc/sonic/config.cfg
'';
# Found argument '--test-threads' which wasn't expected, or isn't valid in this context
doCheck = false;
passthru = {
tests = {
inherit (nixosTests) sonic-server;
version = testers.testVersion {
command = "sonic --version";
package = sonic-server;
};
};
updateScript = nix-update-script { };
};
meta = {
description = "Fast, lightweight and schema-less search backend";
homepage = "https://github.com/valeriansaliou/sonic";
changelog = "https://github.com/valeriansaliou/sonic/releases/tag/v${version}";
license = lib.licenses.mpl20;
platforms = lib.platforms.unix;
mainProgram = "sonic";
maintainers = with lib.maintainers; [
pleshevskiy
anthonyroussel
];
};
}

View File

@@ -0,0 +1,44 @@
{
lib,
stdenv,
fetchFromGitHub,
fftw,
installShellFiles,
}:
stdenv.mkDerivation {
pname = "sonic-unstable";
version = "2020-12-27";
src = fetchFromGitHub {
owner = "waywardgeek";
repo = "sonic";
rev = "4a052d9774387a9d9b4af627f6a74e1694419960";
sha256 = "0ah54nizb6iwcx277w104wsfnx05vrp4sh56d2pfxhf8xghg54m6";
};
makeFlags = [
"PREFIX=${placeholder "out"}"
"CC=${stdenv.cc.targetPrefix}cc"
];
nativeBuildInputs = [ installShellFiles ];
buildInputs = [ fftw ];
postInstall = ''
installManPage sonic.1
''
+ lib.optionalString stdenv.hostPlatform.isDarwin ''
install_name_tool -id $out/lib/libsonic.so.0.3.0 $out/lib/libsonic.so.0.3.0
'';
meta = with lib; {
description = "Simple library to speed up or slow down speech";
mainProgram = "sonic";
homepage = "https://github.com/waywardgeek/sonic";
license = licenses.asl20;
maintainers = with maintainers; [ aske ];
platforms = platforms.all;
};
}

View File

@@ -0,0 +1,28 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
}:
stdenv.mkDerivation rec {
pname = "sonivox";
version = "3.6.16";
src = fetchFromGitHub {
owner = "pedrolcl";
repo = "sonivox";
rev = "v${version}";
hash = "sha256-2OWlm1GZI08OeiG3AswRyvguv9MUYo1dLo6QUPr3r3s=";
};
nativeBuildInputs = [ cmake ];
meta = with lib; {
homepage = "https://github.com/pedrolcl/sonivox";
description = "MIDI synthesizer library";
license = licenses.asl20;
maintainers = with maintainers; [ orivej ];
platforms = platforms.linux;
};
}

View File

@@ -0,0 +1,34 @@
{
lib,
fetchurl,
appimageTools,
}:
let
pname = "sonixd";
version = "0.15.5";
src = fetchurl {
url = "https://github.com/jeffvli/sonixd/releases/download/v${version}/Sonixd-${version}-linux-x86_64.AppImage";
sha256 = "sha256-j8B+o/CJ5SsZPMNbugyP3T9Kb+xuxlVxH02loxlwwDg=";
};
appimageContents = appimageTools.extractType2 { inherit pname version src; };
in
appimageTools.wrapType2 rec {
inherit pname version src;
extraInstallCommands = ''
install -m 444 -D ${appimageContents}/${pname}.desktop -t $out/share/applications
substituteInPlace $out/share/applications/${pname}.desktop \
--replace 'Exec=AppRun --no-sandbox %U' 'Exec=${pname}'
cp -r ${appimageContents}/usr/share/icons $out/share
'';
meta = with lib; {
description = "Full-featured Subsonic/Jellyfin compatible desktop music player";
homepage = "https://github.com/jeffvli/sonixd";
license = licenses.gpl3Only;
maintainers = with maintainers; [ onny ];
platforms = [ "x86_64-linux" ];
mainProgram = "sonixd";
};
}

View File

@@ -0,0 +1,67 @@
{
lib,
buildGoModule,
fetchFromGitHub,
testers,
sonobuoy,
}:
# SHA of ${version} for the tool's help output. Unfortunately this is needed in build flags.
# The update script can update this automatically, the comment is used to find the line.
let
rev = "a988242e8bbded3ef4602eda48addcfac24a1a91"; # update-commit-sha
in
buildGoModule rec {
pname = "sonobuoy";
version = "0.57.3"; # Do not forget to update `rev` above
ldflags =
let
t = "github.com/vmware-tanzu/sonobuoy";
in
[
"-s"
"-X ${t}/pkg/buildinfo.Version=v${version}"
"-X ${t}/pkg/buildinfo.GitSHA=${rev}"
"-X ${t}/pkg/buildDate=unknown"
];
src = fetchFromGitHub {
owner = "vmware-tanzu";
repo = "sonobuoy";
rev = "v${version}";
hash = "sha256-YFItnwU08g4pVo4OOHscRmPRVXyr+R9YWYTxhSzd7iI=";
};
vendorHash = "sha256-QjVnC6CZXuw6qLNyX9ut2g1Ws1cYO1JuT043aqqeF0Q=";
subPackages = [ "." ];
passthru = {
updateScript = ./update.sh;
tests.version = testers.testVersion {
package = sonobuoy;
command = "sonobuoy version";
version = "v${version}";
};
};
meta = {
description = "Diagnostic tool that makes it easier to understand the state of a Kubernetes cluster";
longDescription = ''
Sonobuoy is a diagnostic tool that makes it easier to understand the state of
a Kubernetes cluster by running a set of Kubernetes conformance tests in an
accessible and non-destructive manner.
'';
homepage = "https://sonobuoy.io";
changelog = "https://github.com/vmware-tanzu/sonobuoy/releases/tag/v${version}";
license = lib.licenses.asl20;
mainProgram = "sonobuoy";
maintainers = with lib.maintainers; [
carlosdagos
saschagrunert
wilsonehusin
];
};
}

View File

@@ -0,0 +1,50 @@
#!/usr/bin/env nix-shell
#!nix-shell -i bash -p nix-update curl jq gnused
set -euo pipefail
# Do the actual update.
nix-update "${UPDATE_NIX_ATTR_PATH}"
# Get the src metadata.
src=$(
nix-instantiate --json --eval --strict --expr '
with import ./. {};
{
owner = '"${UPDATE_NIX_ATTR_PATH}"'.src.owner;
repo = '"${UPDATE_NIX_ATTR_PATH}"'.src.repo;
tag = '"${UPDATE_NIX_ATTR_PATH}"'.src.rev;
}'
)
owner=$(jq -r '.owner' <<< "${src}")
repo=$(jq -r '.repo' <<< "${src}")
tag=$(jq -r '.tag' <<< "${src}")
# Curl the release to get the commit sha.
curlFlags=("-fsSL")
curlFlags+=(${GITHUB_TOKEN:+-u ":$GITHUB_TOKEN"})
read -r type tag_sha < <(
curl "${curlFlags[@]}" "https://api.github.com/repos/${owner}/${repo}/git/ref/tags/${tag}" |
jq -j '.object.type, " ", .object.sha, "\n"'
)
if [[ "${type}" == "commit" ]]; then
sha="${tag_sha}"
else
sha=$(
curl "${curlFlags[@]}" "https://api.github.com/repos/${owner}/${repo}/git/tags/${tag_sha}" |
jq '.object.sha'
)
fi
if [[ -z "${sha}" ]]; then
echo "failed to get commit sha of ${owner}/${repo} @ ${tag}" >&2
exit 1
fi
echo "updating commit hash of ${owner}/${repo} @ ${tag} to ${sha}" >&2
cd "$(dirname "$(readlink -f "$0")")"
sed -i "s|\".*\"; # update-commit-sha|${sha}; # update-commit-sha|" default.nix

View File

@@ -0,0 +1,87 @@
{
lib,
pkg-config,
stdenv,
fetchFromGitHub,
autoPatchelfHook,
alsa-lib,
cmake,
freetype,
libGL,
libX11,
libXcursor,
libXext,
libXinerama,
libXrandr,
libjack2,
libopus,
curl,
gtk3,
webkitgtk_4_0,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sonobus";
version = "1.7.2";
src = fetchFromGitHub {
owner = "sonosaurus";
repo = "sonobus";
tag = finalAttrs.version;
hash = "sha256-NOdmHFKrV7lb8XbeG5GdLKYZ0c/vcz3fcqYj9JvE+/Q=";
fetchSubmodules = true;
};
nativeBuildInputs = [
autoPatchelfHook
cmake
pkg-config
];
buildInputs = [
alsa-lib
freetype
libjack2
libopus
curl
gtk3
webkitgtk_4_0
];
runtimeDependencies = [
libGL
libX11
libXcursor
libXext
libXinerama
libXrandr
];
env.NIX_LDFLAGS = lib.optionalString stdenv.hostPlatform.isLinux "-rpath ${lib.makeLibraryPath (finalAttrs.runtimeDependencies)}";
dontPatchELF = true; # needed or nix will try to optimize the binary by removing "useless" rpath
postPatch = lib.optionalString (stdenv.hostPlatform.isLinux) ''
# needs special setup on Linux, dunno if it can work on Darwin
# Also, I get issues with linking without that, not sure why
sed -i -e '/juce::juce_recommended_lto_flags/d' CMakeLists.txt
patchShebangs linux/install.sh
'';
# The program does not provide any CMake install instructions
installPhase = lib.optionalString (stdenv.hostPlatform.isLinux) ''
runHook preInstall
cd ../linux
./install.sh "$out"
runHook postInstall
'';
meta = with lib; {
description = "High-quality network audio streaming";
homepage = "https://sonobus.net/";
license = with licenses; [ gpl3Plus ];
maintainers = with maintainers; [ PowerUser64 ];
platforms = platforms.unix;
broken = stdenv.hostPlatform.isDarwin;
mainProgram = "sonobus";
};
})

View File

@@ -0,0 +1,65 @@
{
fetchFromGitHub,
fetchurl,
lib,
python3Packages,
coreVersion ? "1.13.3", # the version of the binary espurna image to flash
coreSize ? "1MB", # size of the binary image to flash
coreSha256 ? "0pkb2nmml0blrfiqpc46xpjc2dw927i89k1lfyqx827wanhc704x",
}:
with python3Packages;
let
core = fetchurl {
url = "https://github.com/xoseperez/espurna/releases/download/${coreVersion}/espurna-${coreVersion}-espurna-core-${coreSize}.bin";
sha256 = coreSha256;
};
in
buildPythonApplication rec {
pname = "sonota-unstable";
version = "2018-10-07";
src = fetchFromGitHub {
owner = "mirko";
repo = "SonOTA";
rev = "d7f4b353858aae7ac403f95475a35560fb7ffeae";
sha256 = "0jd9xrhcyk8d2plbjnrlpn87536zr6n708797n0k5blf109q3c1z";
};
patches = [
./set_resource_path.patch
];
postPatch = ''
substituteInPlace sonota.py --subst-var out
'';
format = "other";
propagatedBuildInputs = [
httplib2
netifaces
tornado
];
installPhase = ''
runHook preInstall
install -Dm755 sonota.py $out/bin/sonota
install -d $out/share/sonota
cp -r ssl static $out/share/sonota
cp ${core} $out/share/sonota/static/image_arduino.bin
runHook postInstall
'';
meta = with lib; {
description = "Flash Itead Sonoff devices with custom firmware via original OTA mechanism";
homepage = src.meta.homepage;
license = licenses.gpl2Plus;
maintainers = with maintainers; [ peterhoeg ];
mainProgram = "sonota";
};
}

View File

@@ -0,0 +1,20 @@
diff --git a/sonota.py b/sonota.py
index f67128b..9f2752e 100644
--- a/sonota.py
+++ b/sonota.py
@@ -475,14 +475,7 @@ def promptforval(msg):
return val
def resource_path(relative_path):
- """ Get absolute path to resource, works for dev and for PyInstaller """
- try:
- # PyInstaller creates a temp folder and stores path in _MEIPASS
- base_path = sys._MEIPASS
- except Exception:
- base_path = os.path.dirname(sys.argv[0])
-
- return os.path.join(base_path, relative_path)
+ return os.path.join("@out@/share/sonota", relative_path)
def checkargs():
# Make sure all of the binary files that are needed are there

View File

@@ -0,0 +1,89 @@
{
lib,
stdenv,
fetchFromGitHub,
fetchpatch,
cmake,
pkg-config,
bluez,
dbus,
glew,
glfw,
imgui,
makeDesktopItem,
copyDesktopItems,
}:
stdenv.mkDerivation rec {
pname = "SonyHeadphonesClient";
version = "1.3.2";
src = fetchFromGitHub {
owner = "Plutoberth";
repo = "SonyHeadphonesClient";
tag = "v${version}";
hash = "sha256-vhI97KheKzr87exCh4xNN7NDefcagdMu1tWSt67vLiU=";
fetchSubmodules = true;
};
patches = [
(fetchpatch {
name = "include-cstdint-to-fix-gcc-compiling.patch";
url = "https://github.com/Plutoberth/SonyHeadphonesClient/commit/4da8a12b22f8a45e79aa53d4cae88ca99b51d41f.patch";
stripLen = 2;
extraPrefix = "";
hash = "sha256-IZR/Znj40pUEC9gmNJDMPWuZOM2ueAgykZFn5DVn6es=";
})
];
nativeBuildInputs = [
cmake
pkg-config
copyDesktopItems
];
buildInputs = [
bluez
dbus
glew
glfw
imgui
];
sourceRoot = "${src.name}/Client";
cmakeFlags = [ "-Wno-dev" ];
postPatch = ''
substituteInPlace Constants.h \
--replace "UNKNOWN = -1" "// UNKNOWN removed since it doesn't fit in char"
'';
installPhase = ''
runHook preInstall
install -Dm755 -t $out/bin SonyHeadphonesClient
runHook postInstall
'';
desktopItems = [
(makeDesktopItem {
name = "SonyHeadphonesClient";
exec = "SonyHeadphonesClient";
icon = "SonyHeadphonesClient";
desktopName = "Sony Headphones Client";
comment = "A client recreating the functionality of the Sony Headphones app";
categories = [
"Audio"
"Mixer"
];
})
];
meta = with lib; {
description = "Client recreating the functionality of the Sony Headphones app";
homepage = "https://github.com/Plutoberth/SonyHeadphonesClient";
license = licenses.mit;
maintainers = with maintainers; [ stunkymonkey ];
platforms = platforms.linux;
mainProgram = "SonyHeadphonesClient";
};
}

View File

@@ -0,0 +1,81 @@
{
lib,
stdenv,
fetchFromGitHub,
autoreconfHook,
pkg-config,
which,
libtool,
liblo,
libxml2,
libjack2,
libsndfile,
wxGTK32,
libsigcxx,
libsamplerate,
rubberband,
gettext,
ncurses,
alsa-lib,
fftw,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sooperlooper";
version = "1.7.9";
src = fetchFromGitHub {
owner = "essej";
repo = "sooperlooper";
rev = "v${finalAttrs.version}";
sha256 = "sha256-bPu/VWTJLSIMoJSEQb+/nqtTpkPtCNVuXA17XsnFSP0=";
};
autoreconfPhase = ''
patchShebangs ./autogen.sh
./autogen.sh
'';
nativeBuildInputs = [
autoreconfHook
pkg-config
which
libtool
];
buildInputs = [
liblo
libxml2
libjack2
libsndfile
wxGTK32
libsigcxx
libsamplerate
rubberband
gettext
ncurses
alsa-lib
fftw
];
# see https://bugs.gentoo.org/925275
CPPFLAGS = "-fpermissive";
enableParallelBuilding = true;
meta = {
description = "Live looping sampler capable of immediate loop recording, overdubbing, multiplying, reversing and more";
longDescription = ''
It allows for multiple simultaneous multi-channel loops limited only by your computer's available memory.
The application is a standalone JACK client with an engine controllable via OSC and MIDI.
It also includes a GUI which communicates with the engine via OSC (even over a network) for user-friendly control on a desktop.
However, this kind of live performance looping tool is most effectively used via hardware (midi footpedals, etc)
and the engine can be run standalone on a computer without a monitor.
'';
homepage = "https://sonosaurus.com/sooperlooper/";
downloadPage = "https://github.com/essej/sooperlooper";
license = lib.licenses.gpl2;
maintainers = with lib.maintainers; [ magnetophon ];
platforms = lib.platforms.linux;
};
})

View File

@@ -0,0 +1,89 @@
{
lib,
clangStdenv,
fetchFromGitHub,
fetchpatch,
libxml2,
openssl,
openldap,
mariadb,
libmysqlclient,
libpq,
gnustep-make,
gnustep-base,
}:
clangStdenv.mkDerivation rec {
pname = "sope";
version = "5.12.3";
src = fetchFromGitHub {
owner = "Alinto";
repo = "sope";
rev = "SOPE-${version}";
hash = "sha256-GeJ1o8Juw7jm3/pkfuMqVpfMxKewU6hQmBoPmb0HgTc=";
};
patches = [
(fetchpatch {
name = "CVE-2025-53603.patch";
url = "https://github.com/Alinto/sope/commit/e954ab0cd254dc1837af690329b04504410cbe63.patch";
hash = "sha256-F/dexphHH8S90njmTDvm+NZChbKekv78tUgB+VFOsSY=";
})
];
nativeBuildInputs = lib.optional (libpq != null) [ libpq.pg_config ];
buildInputs = [
gnustep-base
libxml2
openssl
]
++ lib.optional (openldap != null) openldap
++ lib.optionals (mariadb != null) [
libmysqlclient
mariadb
]
++ lib.optional (libpq != null) libpq;
# Configure directories where files are installed to. Everything is automatically
# put into $out (thanks GNUstep) apart from the makefiles location which is where
# makefiles are read from during build but also where the SOPE makefiles are
# installed to in the install phase. We move them over after the installation.
preConfigure = ''
mkdir -p /build/Makefiles
ln -s ${gnustep-make}/share/GNUstep/Makefiles/* /build/Makefiles
cat <<EOF > /build/GNUstep.conf
GNUSTEP_MAKEFILES=/build/Makefiles
EOF
'';
configureFlags = [
"--prefix="
"--disable-debug"
"--enable-xml"
"--with-ssl=ssl"
]
++ lib.optional (openldap != null) "--enable-openldap"
++ lib.optional (mariadb != null) "--enable-mysql"
++ lib.optional (libpq != null) "--enable-postgresql";
env = {
GNUSTEP_CONFIG_FILE = "/build/GNUstep.conf";
NIX_CFLAGS_COMPILE = "-Wno-error=incompatible-pointer-types -Wno-error=int-conversion";
};
# Move over the makefiles (see comment over preConfigure)
postInstall = ''
mkdir -p $out/share/GNUstep/Makefiles
find /build/Makefiles -mindepth 1 -maxdepth 1 -not -type l -exec cp -r '{}' $out/share/GNUstep/Makefiles \;
'';
meta = {
description = "Extensive set of frameworks which form a complete Web application server environment";
license = lib.licenses.lgpl2Plus;
homepage = "https://github.com/Alinto/sope";
platforms = lib.platforms.linux;
maintainers = with lib.maintainers; [ jceb ];
knownVulnerabilities = [ ];
};
}

View File

@@ -0,0 +1,45 @@
{
lib,
stdenv,
eigen,
fmt,
fetchFromGitHub,
cmake,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "sophus";
version = "1.24.6";
src = fetchFromGitHub {
owner = "strasdat";
repo = "Sophus";
rev = finalAttrs.version;
hash = "sha256-k5t3kSUrH6B1f60dtqq3Ai4R4D2h+Ld+6Cpljl/AN0w=";
};
nativeBuildInputs = [
cmake
];
buildInputs = [
eigen
fmt
];
cmakeFlags = [
(lib.cmakeBool "BUILD_SOPHUS_TESTS" false)
(lib.cmakeBool "BUILD_SOPHUS_EXAMPLES" false)
];
meta = {
description = "C++ implementation of Lie Groups using Eigen";
homepage = "https://github.com/strasdat/Sophus";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [
locochoco
acowley
];
platforms = lib.platforms.all;
};
})

View File

@@ -0,0 +1,33 @@
{
lib,
stdenv,
cmake,
fetchFromGitHub,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "soplex";
version = "713";
src = fetchFromGitHub {
owner = "scipopt";
repo = "soplex";
rev = "release-${builtins.replaceStrings [ "." ] [ "" ] finalAttrs.version}";
hash = "sha256-qI7VGPAm3ALzeiD/OgvlZ1w2GzHRYdBajTW5XdIN9pU=";
};
nativeBuildInputs = [ cmake ];
strictDeps = true;
doCheck = true;
meta = {
homepage = "https://scipopt.org";
description = "Sequential object-oriented simPlex";
license = with lib.licenses; [ asl20 ];
mainProgram = "soplex";
maintainers = with lib.maintainers; [ david-r-cox ];
platforms = lib.platforms.unix;
};
})

View File

@@ -0,0 +1,19 @@
#!/usr/bin/env bash
# based on https://github.com/urfave/cli/blob/v2.3.0/autocomplete/bash_autocomplete
_cli_bash_autocomplete() {
if [[ "${COMP_WORDS[0]}" != "source" ]]; then
local cur opts
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
if [[ "$cur" == "-"* ]]; then
opts=$("${COMP_WORDS[@]:0:$COMP_CWORD}" "${cur}" --generate-bash-completion)
else
opts=$("${COMP_WORDS[@]:0:$COMP_CWORD}" --generate-bash-completion)
fi
IFS=$'\n' read -d '' -ra COMPREPLY < <(compgen -W "${opts}" -- "${cur}")
return 0
fi
}
complete -o bashdefault -o default -o nospace -F _cli_bash_autocomplete sops

View File

@@ -0,0 +1,73 @@
{
lib,
buildGoModule,
fetchFromGitHub,
installShellFiles,
versionCheckHook,
nix-update-script,
makeWrapper,
runCommand,
age,
}:
buildGoModule (final: {
pname = "sops";
version = "3.11.0";
src = fetchFromGitHub {
owner = "getsops";
repo = final.pname;
tag = "v${final.version}";
hash = "sha256-AAnrZvNkBgliHdk1lAoFrJdISNWteFdBUorRycKsptU=";
};
vendorHash = "sha256-9bB3MbE03KEaxUp0VvCnNVKUY4zSUoam8h2cDlAz7RY=";
subPackages = [ "cmd/sops" ];
ldflags = [
"-s"
"-w"
"-X github.com/getsops/sops/v3/version.Version=${final.version}"
];
nativeBuildInputs = [
installShellFiles
makeWrapper
];
postInstall = ''
installShellCompletion --cmd sops --bash ${./bash_autocomplete}
installShellCompletion --cmd sops --zsh ${./zsh_autocomplete}
'';
nativeInstallCheckInputs = [ versionCheckHook ];
versionCheckProgramArg = "--version";
doInstallCheck = true;
passthru.updateScript = nix-update-script { };
# wrap sops with age plugins
passthru.withAgePlugins =
filter:
runCommand "sops-${final.version}-with-age-plugins"
{
nativeBuildInputs = [ makeWrapper ];
}
''
makeWrapper ${lib.getBin final.finalPackage}/bin/sops $out/bin/sops \
--prefix PATH : "${lib.makeBinPath (filter age.passthru.plugins)}"
'';
meta = {
homepage = "https://getsops.io/";
description = "Simple and flexible tool for managing secrets";
changelog = "https://github.com/getsops/sops/blob/v${final.version}/CHANGELOG.rst";
mainProgram = "sops";
maintainers = with lib.maintainers; [
Scrumplex
mic92
];
license = lib.licenses.mpl20;
};
})

View File

@@ -0,0 +1,25 @@
#compdef sops
## based on https://github.com/urfave/cli/blob/v2.3.0/autocomplete/zsh_autocomplete
_cli_zsh_autocomplete() {
local -a opts
local cur
cur=${words[-1]}
if [[ "$cur" == "-"* ]]; then
opts=("${(@f)$(_CLI_ZSH_AUTOCOMPLETE_HACK=1 ${words[@]:0:#words[@]-1} ${cur} --generate-bash-completion)}")
else
opts=("${(@f)$(_CLI_ZSH_AUTOCOMPLETE_HACK=1 ${words[@]:0:#words[@]-1} --generate-bash-completion)}")
fi
if [[ "${opts[1]}" != "" ]]; then
_describe 'values' opts
else
_files
fi
return
}
compdef _cli_zsh_autocomplete sops

View File

@@ -0,0 +1,42 @@
{
lib,
stdenv,
fetchFromGitHub,
glib,
SDL2,
libGL,
pkg-config,
autoreconfHook,
}:
stdenv.mkDerivation rec {
pname = "sopwith";
version = "2.8.0";
src = fetchFromGitHub {
owner = "fragglet";
repo = "sdl-sopwith";
tag = "sdl-sopwith-${version}";
hash = "sha256-s7npLid3GYZArQmctSwOu8zeC+mSfTiiiOaOEa9dcrg=";
};
nativeBuildInputs = [
autoreconfHook
pkg-config
];
buildInputs = [
glib
SDL2
libGL
];
meta = with lib; {
homepage = "https://github.com/fragglet/sdl-sopwith";
description = "Classic biplane shoot em-up game";
license = licenses.gpl2Plus;
mainProgram = "sopwith";
maintainers = with maintainers; [ evilbulgarian ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,53 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
coin3d,
qt6,
testers,
nix-update-script,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "soqt";
version = "1.6.4";
src = fetchFromGitHub {
owner = "coin3d";
repo = "soqt";
tag = "v${finalAttrs.version}";
hash = "sha256-H904mFfrELjB6ZVhypaKJd+pu5y+aVV4foryrsN7IqE=";
fetchSubmodules = true;
};
nativeBuildInputs = [
cmake
];
propagatedBuildInputs = [
coin3d
qt6.qtbase
];
dontWrapQtApps = true;
passthru = {
tests = {
cmake-config = testers.hasCmakeConfigModules {
moduleNames = [ "soqt" ];
package = finalAttrs.finalPackage;
nativeBuildInputs = [ qt6.wrapQtAppsHook ];
};
};
updateScript = nix-update-script { };
};
meta = {
homepage = "https://github.com/coin3d/soqt";
license = lib.licenses.bsd3;
description = "Glue between Coin high-level 3D visualization library and Qt";
maintainers = [ ];
platforms = lib.platforms.unix;
};
})

View File

@@ -0,0 +1,56 @@
{
lib,
stdenv,
fetchFromGitHub,
boost,
cairomm,
cmake,
libsndfile,
lv2,
ntk,
pkg-config,
}:
stdenv.mkDerivation rec {
pname = "sorcer";
version = "1.1.3";
src = fetchFromGitHub {
owner = "openAVproductions";
repo = "openAV-Sorcer";
rev = "release-${version}";
sha256 = "1x7pi77nal10717l02qpnhrx6d7w5nqrljkn9zx5w7gpb8fpb3vp";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
boost
cairomm
libsndfile
lv2
ntk
];
postPatch = ''
# Fix build with lv2 1.18: https://github.com/brummer10/guitarix/commit/c0334c72
find . -type f -exec fgrep -q LV2UI_Descriptor {} \; \
-exec sed -i {} -e 's/const struct _\?LV2UI_Descriptor/const LV2UI_Descriptor/' \;
'';
installPhase = ''
make install
cp -a ../presets/* "$out/lib/lv2"
'';
meta = with lib; {
broken = (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64);
homepage = "http://openavproductions.com/sorcer/";
description = "Wavetable LV2 plugin synth, targeted at the electronic / dubstep genre";
license = licenses.gpl3Plus;
maintainers = [ maintainers.magnetophon ];
platforms = platforms.linux;
};
}

View File

@@ -0,0 +1,58 @@
{
lib,
stdenv,
doxygen,
fetchFromGitHub,
meson,
ninja,
pcre2,
pkg-config,
python3,
serd,
zix,
}:
stdenv.mkDerivation rec {
pname = "sord";
version = "0.16.18";
src = fetchFromGitHub {
owner = "drobilla";
repo = "sord";
rev = "v${version}";
hash = "sha256-cFobmmO2RHJdfCgTyGigzsdLpj7YF6U3r71i267Azks=";
};
outputs = [
"out"
"dev"
"doc"
"man"
];
nativeBuildInputs = [
doxygen
meson
ninja
pkg-config
python3
];
buildInputs = [ pcre2 ];
propagatedBuildInputs = [
serd
zix
];
doCheck = true;
meta = with lib; {
homepage = "http://drobilla.net/software/sord";
description = "Lightweight C library for storing RDF data in memory";
license = with licenses; [
bsd0
isc
];
maintainers = [ ];
platforms = platforms.unix;
};
}

View File

@@ -0,0 +1,61 @@
{
stdenv,
fetchurl,
lib,
}:
stdenv.mkDerivation rec {
pname = "sorted-grep";
version = "1.0";
src = fetchurl {
url = "mirror://sourceforge/sgrep/sgrep-${version}.tgz";
hash = "sha256-3F7cXrZnB38YwE1sHYm/CIGKmG+1c0QU+Pk3Y53a0T4=";
};
postPatch = ''
# Its Makefile is missing compiler flags and an install step
rm -f Makefile
'';
buildPhase = ''
runHook preBuild
${stdenv.cc.targetPrefix}cc -Wall -O2 -o sgrep sgrep.c
runHook postBuild
'';
installPhase = ''
runHook preInstall
install -D sgrep "$out/bin/sgrep"
runHook postInstall
'';
installCheckPhase = ''
runHook preInstallCheck
set +o pipefail
$out/bin/sgrep 2>&1 | grep ^Usage:
runHook postInstallCheck
'';
doInstallCheck = true;
meta = with lib; {
homepage = "https://sgrep.sourceforge.net/";
description = "Sgrep (sorted grep) searches sorted input files for lines that match a search key";
mainProgram = "sgrep";
longDescription = ''
Sgrep (sorted grep) searches sorted input files for lines that match a search
key and outputs the matching lines. When searching large files sgrep is much
faster than traditional Unix grep, but with significant restrictions.
'';
platforms = platforms.unix;
license = licenses.gpl3Plus;
maintainers = with maintainers; [ ivan ];
};
}

View File

@@ -0,0 +1,72 @@
{
lib,
stdenv,
cmake,
rocksdb_8_3,
rapidjson,
pkg-config,
fetchFromGitHub,
zlib,
}:
let
rocksdb = rocksdb_8_3;
concurrentqueue = fetchFromGitHub {
owner = "cameron314";
repo = "concurrentqueue";
tag = "v1.0.4";
hash = "sha256-MkhlDme6ZwKPuRINhfpv7cxliI2GU3RmTfC6O0ke/IQ=";
};
in
stdenv.mkDerivation rec {
pname = "sortmerna";
version = "4.3.7";
src = fetchFromGitHub {
owner = "sortmerna";
repo = "sortmerna";
tag = "v${version}";
hash = "sha256-oxwZBkeW3usEcJE1XLu1UigKsgOsljwGFTpb7U3845I=";
};
nativeBuildInputs = [
cmake
pkg-config
];
buildInputs = [
zlib
rocksdb
rapidjson
];
cmakeFlags = [
"-DPORTABLE=off"
"-DRAPIDJSON_HOME=${rapidjson}"
"-DROCKSDB_HOME=${rocksdb}"
"-DCONCURRENTQUEUE_HOME=${concurrentqueue}"
"-DROCKSDB_STATIC=off"
"-DZLIB_STATIC=off"
];
postPatch = ''
# Fix missing pthread dependency for the main binary.
substituteInPlace src/sortmerna/CMakeLists.txt \
--replace-fail "target_link_libraries(sortmerna" \
"target_link_libraries(sortmerna Threads::Threads"
# Fix gcc-13 build by adding missing <cstdint> includes:
# https://github.com/sortmerna/sortmerna/issues/412
sed -e '1i #include <cstdint>' -i include/kseq_load.hpp
'';
meta = {
description = "Tools for filtering, mapping, and OTU-picking from shotgun genomics data";
mainProgram = "sortmerna";
license = lib.licenses.lgpl3;
platforms = lib.platforms.x86_64;
homepage = "https://bioinfo.lifl.fr/RNA/sortmerna/";
maintainers = with lib.maintainers; [ luispedro ];
broken = stdenv.hostPlatform.isDarwin;
};
}

View File

@@ -0,0 +1,40 @@
{
lib,
fetchFromGitHub,
stdenvNoCC,
}:
stdenvNoCC.mkDerivation {
pname = "sorts-mill-goudy";
version = "2011-05-25";
src = fetchFromGitHub {
owner = "theleagueof";
repo = "sorts-mill-goudy";
rev = "06072890c7b05f274215a24f17449655ccb2c8af";
hash = "sha256-NEfLBJatUmdUL5gJEimJHZfOd1OtI7pxTN97eWMODyM=";
};
installPhase = ''
runHook preInstall
install -D -m444 -t $out/share/fonts/truetype $src/*.ttf
install -D -m444 -t $out/share/fonts/opentype $src/*.otf
runHook postInstall
'';
meta = {
description = "revival of Goudy Oldstyle and Italic";
longDescription = ''
A 'revival' of Goudy Oldstyle and Italic, with features including small
capitals (in the roman only), oldstyle and lining figures, superscripts
and subscripts, fractions, ligatures, class-based kerning, case-sensitive
forms, and capital spacing. There is support for many languages using
latin scripts.
'';
homepage = "https://www.theleagueofmoveabletype.com/sorts-mill-goudy";
license = lib.licenses.ofl;
maintainers = with lib.maintainers; [ minijackson ];
};
}

View File

@@ -0,0 +1,47 @@
{
lib,
python3Packages,
fetchFromGitHub,
gettext,
}:
python3Packages.buildPythonPackage rec {
pname = "sosreport";
version = "4.9.1";
pyproject = true;
src = fetchFromGitHub {
owner = "sosreport";
repo = "sos";
tag = version;
hash = "sha256-97S8b4PfjUN8uzvp01PGCLs4J3CbwpJsgBKtY8kI0HE=";
};
build-system = [ python3Packages.setuptools ];
nativeBuildInputs = [
gettext
];
dependencies = with python3Packages; [
packaging
pexpect
pyyaml
];
# requires avocado-framework 94.0, latest version as of writing is 96.0
doCheck = false;
preCheck = ''
export PYTHONPATH=$PWD/tests:$PYTHONPATH
'';
pythonImportsCheck = [ "sos" ];
meta = {
description = "Unified tool for collecting system logs and other debug information";
homepage = "https://github.com/sosreport/sos";
license = lib.licenses.gpl2Plus;
maintainers = [ ];
};
}

View File

@@ -0,0 +1,62 @@
{
lib,
rustPlatform,
fetchFromGitHub,
pkg-config,
wrapGAppsHook4,
cairo,
gdk-pixbuf,
glib,
gtk4,
pango,
polkit,
}:
let
version = "0.2.0";
in
rustPlatform.buildRustPackage {
pname = "soteria";
inherit version;
src = fetchFromGitHub {
owner = "imvaskel";
repo = "soteria";
tag = "v${version}";
hash = "sha256-bZhxz6aycx7J3itInSsl2glbIs6OpIEkfSp3nYfPojk=";
};
cargoHash = "sha256-rxZRDx+5srBbMTVLMNH8liOqjyg90FvTaTT7g+3fq7E=";
nativeBuildInputs = [
pkg-config
wrapGAppsHook4
];
buildInputs = [
cairo
gdk-pixbuf
glib
gtk4
pango
];
# From upstream packaging:
# Takes advantage of nixpkgs manually editing PACKAGE_PREFIX by grabbing it from
# the binary itself.
# https://github.com/NixOS/nixpkgs/blob/9b5328b7f761a7bbdc0e332ac4cf076a3eedb89b/pkgs/development/libraries/polkit/default.nix#L142
# https://github.com/polkit-org/polkit/blob/d89c3604e2a86f4904566896c89e1e6b037a6f50/src/polkitagent/polkitagentsession.c#L599
preBuild = ''
export POLKIT_AGENT_HELPER_PATH="$(strings ${polkit.out}/lib/libpolkit-agent-1.so | grep "polkit-agent-helper-1")"
'';
meta = {
description = "Polkit authentication agent written in GTK designed to be used with any desktop environment";
homepage = "https://github.com/ImVaskel/soteria";
license = lib.licenses.asl20;
mainProgram = "soteria";
maintainers = with lib.maintainers; [
NotAShelf
];
inherit (polkit.meta) platforms;
};
}

Some files were not shown because too many files have changed in this diff Show More