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,42 @@
{
lib,
stdenv,
fetchzip,
python3,
help2man,
}:
stdenv.mkDerivation rec {
pname = "fead";
version = "1.0.0";
src = fetchzip {
url = "https://trong.loang.net/~cnx/fead/snapshot/fead-${version}.tar.gz";
hash = "sha256-cbU379Zz+mwRqEHiDUlGvWheLkkr0YidHeVs/1Leg38=";
};
nativeBuildInputs = [ help2man ];
buildInputs = [ python3 ];
# Needed for man page generation in build phase
postPatch = ''
patchShebangs src/fead.py
'';
makeFlags = [ "PREFIX=$(out)" ];
# Already done in postPatch phase
dontPatchShebangs = true;
# The package has no tests.
doCheck = false;
meta = {
description = "Advert generator from web feeds";
homepage = "https://trong.loang.net/~cnx/fead";
license = lib.licenses.agpl3Plus;
changelog = "https://trong.loang.net/~cnx/fead/tag?h=${version}";
maintainers = with lib.maintainers; [ McSinyx ];
mainProgram = "fead";
};
}

View File

@@ -0,0 +1,97 @@
{
lib,
stdenv,
cmake,
fetchFromGitHub,
pkg-config,
python3,
freetype,
glfw,
gtk3,
libGL,
libpng,
lunasvg,
nlohmann_json,
plutovg,
xorg,
zlib,
nativeFileDialog ? null,
python3Packages ? null,
enableNFD ? false,
enablePython ? false,
enableTests ? false,
enableExamples ? false,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "feather-tk";
version = "0.3.0";
src = fetchFromGitHub {
owner = "darbyjohnston";
repo = "feather-tk";
tag = finalAttrs.version;
fetchSubmodules = true;
hash = "sha256-776V1nMsAatGkYNBq7QFRX28cI3/NU/2YRSbhfezr0g=";
};
nativeBuildInputs = [
cmake
pkg-config
python3
];
buildInputs = [
freetype
glfw
lunasvg
plutovg
nlohmann_json
libpng
zlib
libGL
]
++ lib.optionals (enableNFD && nativeFileDialog != null) [
nativeFileDialog
]
++ lib.optionals (enableNFD && stdenv.isLinux) [
gtk3
]
++ lib.optionals enablePython [
python3Packages.pybind11
];
cmakeFlags = [
(lib.cmakeFeature "CMAKE_BUILD_TYPE" "Release")
(lib.cmakeBool "feather_tk_UI_LIB" true)
(lib.cmakeFeature "feather_tk_API" "GL_4_1")
(lib.cmakeBool "feather_tk_nfd" enableNFD)
(lib.cmakeBool "feather_tk_PYTHON" enablePython)
(lib.cmakeBool "feather_tk_TESTS" enableTests)
(lib.cmakeBool "feather_tk_EXAMPLES" enableExamples)
(lib.cmakeFeature "feather_tk_BUILD" "default")
];
doCheck = enableTests;
nativeCheckInputs = lib.optionals (enableTests && stdenv.isLinux) [
xorg.xvfb-run
];
checkPhase = lib.optionalString enableTests ''
runHook preCheck
cd feather-tk/src/feather-tk-build
${if stdenv.isLinux then "xvfb-run" else ""} ctest --verbose -C Release
runHook postCheck
'';
meta = {
description = "Lightweight toolkit for building cross-platform applications";
homepage = "https://github.com/darbyjohnston/feather-tk";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ liberodark ];
platforms = lib.platforms.linux ++ lib.platforms.darwin;
};
})

View File

@@ -0,0 +1,90 @@
{
bc-ur,
boost186,
cmake,
fetchFromGitHub,
hidapi,
lib,
libsodium,
libusb1,
openssl,
pkg-config,
protobuf,
python3,
qrencode,
qt6,
readline,
stdenv,
testers,
tor,
unbound,
zxing-cpp,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "feather";
version = "2.8.1";
src = fetchFromGitHub {
owner = "feather-wallet";
repo = "feather";
tag = finalAttrs.version;
hash = "sha256-DZBRZBcoba32Z/bFThn/9siC8VESg5gdfoFO4Nw8JqM=";
fetchSubmodules = true;
};
nativeBuildInputs = [
cmake
pkg-config
python3
qt6.wrapQtAppsHook
];
buildInputs = [
bc-ur
boost186
hidapi
libsodium
libusb1
openssl
protobuf
qrencode
unbound
zxing-cpp
]
++ (with qt6; [
qtbase
qtmultimedia
qtsvg
qttools
qtwayland
qtwebsockets
]);
cmakeFlags = [
"-DProtobuf_INCLUDE_DIR=${lib.getDev protobuf}/include"
"-DProtobuf_PROTOC_EXECUTABLE=${lib.getExe protobuf}"
"-DReadline_INCLUDE_DIR=${lib.getDev readline}/include/readline"
"-DReadline_LIBRARY=${lib.getLib readline}/lib/libreadline.so"
"-DReadline_ROOT_DIR=${lib.getDev readline}"
"-DTOR_DIR=${lib.makeBinPath [ tor ]}"
"-DTOR_VERSION=${tor.version}"
];
passthru.tests.version = testers.testVersion {
package = finalAttrs.finalPackage;
command = ''
QT_QPA_PLATFORM=minimal ${finalAttrs.finalPackage.meta.mainProgram} --version
'';
};
meta = with lib; {
description = "Free Monero desktop wallet";
homepage = "https://featherwallet.org/";
changelog = "https://featherwallet.org/changelog/#${finalAttrs.version}%20changelog";
platforms = platforms.linux;
license = licenses.bsd3;
mainProgram = "feather";
maintainers = with maintainers; [ surfaceflinger ];
};
})

View File

@@ -0,0 +1,42 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
qt6,
hunspell,
pkg-config,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "featherpad";
version = "1.6.2";
src = fetchFromGitHub {
owner = "tsujan";
repo = "FeatherPad";
tag = "V${finalAttrs.version}";
hash = "sha256-G47ltOiyNEk/NrFWoXpft/rCJ18t0FTZrc5ReEJL6TU=";
};
nativeBuildInputs = [
cmake
pkg-config
qt6.qttools
qt6.wrapQtAppsHook
];
buildInputs = [
hunspell
qt6.qtbase
qt6.qtsvg
];
meta = {
description = "Lightweight Qt5 Plain-Text Editor for Linux";
homepage = "https://github.com/tsujan/FeatherPad";
platforms = lib.platforms.linux;
maintainers = [ lib.maintainers.flosse ];
license = lib.licenses.gpl3Plus;
};
})

View File

@@ -0,0 +1,14 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7ad2c68eb2..0e3e978bd9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -449,6 +449,9 @@
set_property(TARGET ${FBS_BIN_NAME} PROPERTY AUTOGEN_BUILD_DIR ${CMAKE_BINARY_DIR}/CMakeFiles/AutoGen/FEBioStudio_autogen)
endif()
+include(GNUInstallDirs)
+install(TARGETS ${FBS_BIN_NAME} BUNDLE DESTINATION Applications)
+
macro(addLib name)
add_library(${name} ${HDR_${name}} ${SRC_${name}})
set_property(TARGET ${name} PROPERTY AUTOGEN_BUILD_DIR ${CMAKE_BINARY_DIR}/CMakeFiles/AutoGen/${name}_autogen)

View File

@@ -0,0 +1,85 @@
{
lib,
stdenv,
fetchFromGitHub,
cmake,
ninja,
zlib,
libGLU,
qt6Packages,
febio,
glew,
fetchpatch,
sshSupport ? true,
openssl,
libssh,
tetgenSupport ? true,
tetgen,
ffmpegSupport ? true,
ffmpeg,
dicomSupport ? false,
dcmtk,
withModelRepo ? true,
withCadFeatures ? false,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "febio-studio";
version = "2.8.1";
src = fetchFromGitHub {
owner = "febiosoftware";
repo = "FEBioStudio";
rev = "v${finalAttrs.version}";
hash = "sha256-ynKo7WK529146Tk//PO5tMsqvfKM4nq3fgPXMGjWwIk=";
};
patches = [
./cmake-install.patch
# Fix qt 6.8 compile, can be removed after next release
(fetchpatch {
url = "https://github.com/febiosoftware/FEBioStudio/commit/15524d958a6f5ef81ccee58b4efa1ea25de91543.patch";
hash = "sha256-LRToK1/RQC+bLXgroDTQOV6H8pI+IZ38Y0nsl/Fz1WE=";
})
];
cmakeFlags = [
(lib.cmakeFeature "Qt_Root" "${qt6Packages.qtbase}")
]
++ lib.optional sshSupport "-DUSE_SSH=On"
++ lib.optional tetgenSupport "-DUSE_TETGEN=On"
++ lib.optional ffmpegSupport "-DUSE_FFMPEG=On"
++ lib.optional dicomSupport "-DUSE_DICOM=On"
++ lib.optional withModelRepo "-DMODEL_REPO=On"
++ lib.optional withCadFeatures "-DCAD_FEATURES=On";
nativeBuildInputs = [
cmake
ninja
qt6Packages.wrapQtAppsHook
];
buildInputs = [
zlib
libGLU
glew
qt6Packages.qtbase
febio
]
++ lib.optionals sshSupport [
openssl
libssh
]
++ lib.optional tetgenSupport tetgen
++ lib.optional ffmpegSupport ffmpeg
++ lib.optional dicomSupport dcmtk;
meta = {
description = "FEBio Suite Solver";
mainProgram = "FEBioStudio";
license = with lib.licenses; [ mit ];
homepage = "https://febio.org/";
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ Scriptkiddi ];
};
})

View File

@@ -0,0 +1,71 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c1bc953edf..f6aaf92fb5 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,6 +2,7 @@
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
mark_as_advanced(FORCE CMAKE_INSTALL_PREFIX)
+include(GNUInstallDirs)
project(FEBio)
set(FEBIO_LIBS FEBioFluid FEBioLib FEBioMech FEBioMix FEBioOpt FECore NumCore FEAMR FEBioRVE FEImgLib)
@@ -51,7 +52,7 @@
find_library(TEMP NAMES ${libName}.lib ${ARGV3}.lib ${ARGV4}.lib ${ARGV5}.lib ${ARGV6}.lib
PATHS ${${libDir}} NO_DEFAULT_PATH)
else()
- find_library(TEMP NAMES lib${libName}.a lib${ARGV3}.a lib${ARGV4}.a lib${ARGV5}.a lib${ARGV6}.a
+ find_library(TEMP NAMES lib${libName}.a lib${ARGV3}.a lib${ARGV4}.a lib${ARGV5}.a lib${ARGV6}.a lib${libName}@so@ lib${ARGV3}@so@ lib${ARGV4}@so@ lib${ARGV5}@so@ lib${ARGV6}@so@
PATHS ${${libDir}} NO_DEFAULT_PATH)
endif()
@@ -154,7 +155,7 @@
##### Find Source Files #####
macro(findHdrSrc name)
- file(GLOB HDR_${name} "${name}/*.h")
+ file(GLOB HDR_${name} "${name}/*.h" "${name}/*.hpp")
file(GLOB SRC_${name} "${name}/*.cpp")
endmacro()
@@ -171,8 +172,9 @@
macro(addLib name TYPE)
string(TOLOWER ${name} lname)
- add_library(${lname} ${TYPE} ${HDR_${name}} ${SRC_${name}})
+ add_library(${lname} ${TYPE} ${SRC_${name}})
set_property(TARGET ${lname} PROPERTY AUTOGEN_BUILD_DIR ${CMAKE_BINARY_DIR}/CMakeFiles/AutoGen/${name}_autogen)
+ target_sources(${lname} PUBLIC FILE_SET HEADERS TYPE HEADERS FILES ${HDR_${name}})
if(NOT WIN32)
set_property(TARGET ${lname} PROPERTY POSITION_INDEPENDENT_CODE ON)
@@ -181,6 +183,8 @@
if(APPLE)
target_link_libraries(${lname} PRIVATE "-undefined dynamic_lookup")
endif()
+
+ install(TARGETS ${lname} FILE_SET HEADERS)
endmacro()
foreach(name IN LISTS FEBIO_LIBS)
@@ -194,6 +198,7 @@
##### Set up executable compilation #####
file(GLOB SOURCES "FEBio/*.cpp")
add_executable (febio4 ${SOURCES})
+install(TARGETS febio4)
if(WIN32)
target_compile_options(febio4 PRIVATE /openmp)
@@ -269,7 +274,6 @@
mark_as_advanced(EXTRA_INC)
##### Setup includes, defnitions, and linking options #####
-include_directories(${PROJECT_SOURCE_DIR})
# Link LEVMAR
if(USE_LEVMAR)
@@ -438,3 +442,4 @@
file(WRITE ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/febio.xml "${filedata}")
endif()
+install(FILES ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/febio.xml TYPE BIN)

View File

@@ -0,0 +1,58 @@
{
lib,
stdenv,
fetchFromGitHub,
fetchpatch2,
replaceVars,
cmake,
ninja,
zlib,
mklSupport ? true,
mkl,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "FEBio";
version = "4.8";
src = fetchFromGitHub {
owner = "febiosoftware";
repo = "FEBio";
rev = "v${finalAttrs.version}";
hash = "sha256-x2QYnMMiGd2x2jvBMLBK7zdJv3yzYHkJ6a+0xes6OOk=";
};
patches = [
# Fix library searching and installation
(replaceVars ./fix-cmake.patch {
so = stdenv.hostPlatform.extensions.sharedLibrary;
})
# Fixed missing header include for strcpy
# https://github.com/febiosoftware/FEBio/pull/92
(fetchpatch2 {
url = "https://github.com/febiosoftware/FEBio/commit/ad9e80e2aa8737828855458a703822f578db2fd3.patch?full_index=1";
hash = "sha256-/uLnJB/oAwLQnsZtJnUlaAEpyZVLG6o2riRwwMCH8rI=";
})
];
cmakeFlags = lib.optionals mklSupport [
(lib.cmakeBool "USE_MKL" true)
(lib.cmakeFeature "MKLROOT" "${mkl}")
];
nativeBuildInputs = [
cmake
ninja
];
buildInputs = [ zlib ] ++ lib.optionals mklSupport [ mkl ];
meta = {
description = "Software tool for nonlinear finite element analysis in biomechanics and biophysics";
license = with lib.licenses; [ mit ];
homepage = "https://febio.org/";
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ Scriptkiddi ];
};
})

View File

@@ -0,0 +1,56 @@
{
lib,
fetchFromGitHub,
python3,
stdenv,
}:
python3.pkgs.buildPythonApplication rec {
pname = "fedifetcher";
version = "7.1.16";
format = "other";
src = fetchFromGitHub {
owner = "nanos";
repo = "FediFetcher";
tag = "v${version}";
hash = "sha256-8eSzXstOOEx+yzwjcSgQfv8c0d+1gsVemzGG/U1TWEo=";
};
propagatedBuildInputs = with python3.pkgs; [
defusedxml
python-dateutil
requests
xxhash
];
installPhase = ''
runHook preInstall
install -vD find_posts.py $out/bin/fedifetcher
runHook postInstall
'';
checkPhase = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
runHook preCheck
$out/bin/fedifetcher --help>/dev/null
runHook postCheck
'';
meta = with lib; {
description = "Tool for Mastodon that automatically fetches missing replies and posts from other fediverse instances";
longDescription = ''
FediFetcher is a tool for Mastodon that automatically fetches missing
replies and posts from other fediverse instances, and adds them to your
own Mastodon instance.
'';
homepage = "https://blog.thms.uk/fedifetcher";
changelog = "https://github.com/nanos/FediFetcher/releases/tag/${src.tag}";
license = licenses.mit;
teams = [ teams.c3d2 ];
mainProgram = "fedifetcher";
};
}

View File

@@ -0,0 +1,44 @@
{
lib,
fetchFromGitea,
rustPlatform,
pkg-config,
git,
openssl,
}:
rustPlatform.buildRustPackage rec {
pname = "fedigroups";
version = "0.4.6";
src = fetchFromGitea {
domain = "git.ondrovo.com";
owner = "MightyPork";
repo = "group-actor";
rev = "v${version}";
hash = "sha256-Sq22CwLLR10yrN3+dR2KDoS8r99+LWOH7+l+D3RWlKw=";
forceFetchGit = true; # Archive generation is disabled on this gitea instance
leaveDotGit = true; # git command in build.rs
};
cargoHash = "sha256-6UijHshvKANtMMfNADWDViDrh6bGlPvFz4xqJeWdqB0=";
nativeBuildInputs = [
pkg-config
git
];
buildInputs = [
openssl
];
meta = with lib; {
homepage = "https://git.ondrovo.com/MightyPork/group-actor#fedi-groups";
downloadPage = "https://git.ondrovo.com/MightyPork/group-actor/releases";
description = "Approximation of groups usable with Fediverse software that implements the Mastodon client API";
license = licenses.mit;
maintainers = with maintainers; [ fgaz ];
platforms = platforms.all;
mainProgram = "fedigroups";
};
}

View File

@@ -0,0 +1,84 @@
{
lib,
buildPackages,
fetchFromGitHub,
openssl,
pkg-config,
protobuf,
rustPlatform,
version ? "0.7.1",
hash ? "sha256-7meBYUN7sG1OAtMEm6I66+ptf4EfsbA+dm5/4P3IRV4=",
cargoHash ? "sha256-4cFuasH2hvrnzTBTFifHEMtXZKsBv7OVpuwPlV19GGw=",
}:
rustPlatform.buildRustPackage rec {
pname = "fedimint";
inherit version;
src = fetchFromGitHub {
owner = "fedimint";
repo = "fedimint";
rev = "v${version}";
inherit hash;
};
inherit cargoHash;
nativeBuildInputs = [
protobuf
pkg-config
rustPlatform.bindgenHook
];
buildInputs = [
openssl
];
outputs = [
"out"
"fedimintCli"
"fedimint"
"gateway"
"gatewayCli"
"devimint"
];
postInstall = ''
mkdir -p $fedimint/bin $fedimintCli/bin $gateway/bin $gatewayCli/bin $devimint/bin
# delete fuzzing targets and other binaries no one cares about
binsToKeep=(fedimint-cli fedimint-dbtool recoverytool fedimintd gatewayd gateway-cli devimint)
keepPattern=$(printf "|%s" "''${binsToKeep[@]}")
keepPattern=''${keepPattern:1}
find "$out/bin" -maxdepth 1 -type f | grep -Ev "(''${keepPattern})" | xargs rm -f
cp -a $releaseDir/fedimint-cli $fedimintCli/bin/
cp -a $releaseDir/fedimint-dbtool $fedimintCli/bin/
cp -a $releaseDir/fedimint-recoverytool $fedimintCli/bin/
cp -a $releaseDir/fedimintd $fedimint/bin/
cp -a $releaseDir/gateway-cli $gatewayCli/bin/
cp -a $releaseDir/gatewayd $gateway/bin/
cp -a $releaseDir/devimint $devimint/bin/
'';
PROTOC = "${buildPackages.protobuf}/bin/protoc";
PROTOC_INCLUDE = "${protobuf}/include";
OPENSSL_DIR = openssl.dev;
FEDIMINT_BUILD_FORCE_GIT_HASH = "0000000000000000000000000000000000000000";
# currently broken, will require some upstream fixes
doCheck = false;
meta = {
description = "Federated E-Cash Mint";
homepage = "https://github.com/fedimint/fedimint";
license = [ lib.licenses.mit ];
maintainers = with lib.maintainers; [ dpc ];
mainProgram = "fedimint-cli";
};
}

View File

@@ -0,0 +1,87 @@
{
lib,
stdenvNoCC,
fetchFromGitHub,
nix-update-script,
pnpm_10,
nodejs,
rustPlatform,
cargo-tauri,
wrapGAppsHook4,
pkg-config,
glib-networking,
webkitgtk_4_1,
openssl,
}:
let
pnpm = pnpm_10;
in
rustPlatform.buildRustPackage (finalAttrs: {
pname = "fedistar";
version = "1.11.3";
src = fetchFromGitHub {
owner = "h3poteto";
repo = "fedistar";
tag = "v${finalAttrs.version}";
hash = "sha256-Q2j6K4ys/z77+n3kdGJ15rWbFlbbIHBWB9hOARsgg2A=";
};
cargoRoot = "src-tauri";
buildAndTestSubdir = "src-tauri";
cargoHash = "sha256-ZJgyrFDtzAH3XqDdnJ27Yn+WsTMrZR2+lnkZ6bw6hzg=";
pnpmDeps = pnpm.fetchDeps {
inherit (finalAttrs) pname version src;
fetcherVersion = 1;
hash = "sha256-xXVsjAXmrsOp+mXrYAxSKz4vX5JApLZ+Rh6hrYlnJDI=";
};
nativeBuildInputs = [
cargo-tauri.hook
pnpm.configHook
pnpm
nodejs
pkg-config
wrapGAppsHook4
];
buildInputs = [
openssl
]
++ lib.optionals stdenvNoCC.hostPlatform.isLinux [
glib-networking
webkitgtk_4_1
];
doCheck = false; # This version's tests do not pass
# A fix for a problem with Tauri (tauri-apps/tauri#9304)
preFixup = ''
gappsWrapperArgs+=(
--set-default WEBKIT_DISABLE_DMABUF_RENDERER 1
)
'';
passthru.updateScript = nix-update-script {
extraArgs = [
"--subpackage"
"fedistar-frontend"
];
};
meta = {
description = "Multi-column Fediverse client application for desktop";
homepage = "https://fedistar.net/";
mainProgram = "fedistar";
license = lib.licenses.gpl3Only;
maintainers = with lib.maintainers; [ noodlez1232 ];
changelog = "https://github.com/h3poteto/fedistar/releases/tag/v${finalAttrs.version}";
};
})

View File

@@ -0,0 +1,38 @@
{
lib,
fetchFromGitHub,
buildNpmPackage,
}:
let
version = "1.4.0";
in
buildNpmPackage {
pname = "fediwall";
inherit version;
src = fetchFromGitHub {
owner = "defnull";
repo = "fediwall";
tag = "v${version}";
hash = "sha256-aEY6mO7Es+H6CNE4shj/jz47nUeEIxGijKbUscIp0pM=";
};
npmDepsHash = "sha256-0VQ/CBqpQNqjg3lug+AQfFVbh0KhEaGwd+cEakBr/Dc=";
installPhase = ''
runHook preInstall
cp -r dist $out
runHook postInstall
'';
meta = {
description = "Social media wall for the Fediverse";
homepage = "https://fediwall.social";
license = lib.licenses.agpl3Plus;
platforms = lib.platforms.all;
maintainers = with lib.maintainers; [ transcaffeine ];
};
}

View File

@@ -0,0 +1,25 @@
{
lib,
stdenv,
fediwall-unwrapped,
conf ? { },
}:
if (conf == { }) then
fediwall-unwrapped
else
stdenv.mkDerivation {
pname = "fediwall";
inherit (fediwall-unwrapped) version meta;
dontUnpack = true;
installPhase = ''
runHook preInstall
mkdir -p $out
ln -s ${fediwall-unwrapped}/* $out
echo ${lib.escapeShellArg (builtins.toJSON conf)} \
> "$out/wall-config.json"
runHook postInstall
'';
}

View File

@@ -0,0 +1,39 @@
{
lib,
buildGoModule,
fetchFromGitHub,
}:
buildGoModule rec {
pname = "feed2imap-go";
version = "1.8.0";
src = fetchFromGitHub {
owner = "Necoro";
repo = "feed2imap-go";
rev = "v${version}";
sha256 = "sha256-7ce2G2t+7P+7Ga+BLyGF4lW4BB2yaE9rV/dxBFvdPEU=";
};
ldflags = [
"-s"
"-w"
"-X github.com/Necoro/feed2imap-go/pkg/version.version=${version}"
"-X github.com/Necoro/feed2imap-go/pkg/version.commit=nixpkgs"
];
vendorHash = "sha256-3z3SPJ5xsz0LRjzOeOQnAuCpIAAtEkn9itoslvJhmTo=";
# The print-cache tool is not an end-user tool (https://github.com/Necoro/feed2imap-go/issues/94)
postInstall = ''
rm -f $out/bin/print-cache
'';
meta = with lib; {
description = "Uploads rss feeds as e-mails onto an IMAP server";
mainProgram = "feed2imap-go";
homepage = "https://github.com/Necoro/feed2imap-go";
license = licenses.gpl2;
maintainers = with maintainers; [ nomeata ];
};
}

View File

@@ -0,0 +1,56 @@
{
lib,
stdenv,
fetchFromGitLab,
meson,
ninja,
json-glib,
feedbackd,
nix-update-script,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "feedbackd-device-themes";
version = "0.8.6";
src = fetchFromGitLab {
domain = "gitlab.freedesktop.org";
owner = "agx";
repo = "feedbackd-device-themes";
rev = "v${finalAttrs.version}";
hash = "sha256-zRFp+857x5KpjjMLrIx/Ygfk4YtvlA9NLBG7HdTbPYw=";
};
nativeBuildInputs = [
meson
ninja
json-glib # Provides json-glib-validate
];
nativeCheckInputs = [
feedbackd # Provides fbd-theme-validate
];
mesonFlags = [
(lib.mesonOption "validate" (if finalAttrs.doCheck then "enabled" else "disabled"))
];
doCheck = true;
passthru = {
updateScript = nix-update-script { };
};
strictDeps = true;
meta = with lib; {
description = "Device specific feedback themes for Feedbackd";
homepage = "https://gitlab.freedesktop.org/agx/feedbackd-device-themes";
license = licenses.gpl3Plus;
maintainers = with maintainers; [
pacman99
Luflosi
];
platforms = platforms.linux;
};
})

View File

@@ -0,0 +1,127 @@
{
lib,
stdenv,
fetchFromGitLab,
docbook-xsl-nons,
docutils,
gi-docgen,
gobject-introspection,
gtk-doc,
libxslt,
meson,
ninja,
pkg-config,
vala,
wrapGAppsHook3,
glib,
gsound,
json-glib,
libgudev,
dbus,
gmobile,
umockdev,
feedbackd-device-themes,
udevCheckHook,
nix-update-script,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "feedbackd";
version = "0.8.5";
outputs = [
"out"
"dev"
"devdoc"
];
src = fetchFromGitLab {
domain = "gitlab.freedesktop.org";
owner = "agx";
repo = "feedbackd";
rev = "v${finalAttrs.version}";
hash = "sha256-m8jDn7gDrZOsdFl17IsIINgcpuHmmtNOCEEdQFwVj6g=";
};
depsBuildBuild = [
pkg-config
];
nativeBuildInputs = [
docbook-xsl-nons
docutils # for rst2man
gi-docgen
gobject-introspection
gtk-doc
libxslt
meson
ninja
pkg-config
vala
wrapGAppsHook3
udevCheckHook
];
buildInputs = [
glib
gsound
json-glib
libgudev
gmobile
];
mesonFlags = [
"-Dgtk_doc=true"
"-Dman=true"
# Make compiling work when doCheck = false
"-Dtests=${lib.boolToString finalAttrs.finalPackage.doCheck}"
];
nativeCheckInputs = [
dbus
umockdev
];
doCheck = true;
postInstall = ''
mkdir -p $out/lib/udev/rules.d
sed "s|/usr/libexec/|$out/libexec/|" < $src/data/90-feedbackd.rules > $out/lib/udev/rules.d/90-feedbackd.rules
'';
postFixup = ''
# Move developer documentation to devdoc output.
# Cannot be in postInstall, otherwise _multioutDocs hook in preFixup will move right back.
if [[ -d "$out/share/doc" ]]; then
find -L "$out/share/doc" -type f -regex '.*\.devhelp2?' -print0 \
| while IFS= read -r -d ''' file; do
moveToOutput "$(dirname "''${file/"$out/"/}")" "$devdoc"
done
fi
'';
doInstallCheck = true;
passthru = {
updateScript = nix-update-script { };
};
strictDeps = true;
meta = with lib; {
description = "Theme based Haptic, Visual and Audio Feedback";
homepage = "https://gitlab.freedesktop.org/agx/feedbackd/";
license = with licenses; [
# feedbackd
gpl3Plus
# libfeedback library
lgpl21Plus
];
maintainers = with maintainers; [
pacman99
Luflosi
];
platforms = platforms.linux;
};
})

View File

@@ -0,0 +1,84 @@
{
lib,
fetchFromGitHub,
makeWrapper,
makeFontsConf,
freefont_ttf,
gnuplot,
perl,
perlPackages,
stdenv,
shortenPerlShebang,
installShellFiles,
}:
let
fontsConf = makeFontsConf { fontDirectories = [ freefont_ttf ]; };
in
perlPackages.buildPerlPackage rec {
pname = "feedgnuplot";
version = "1.61";
src = fetchFromGitHub {
owner = "dkogan";
repo = "feedgnuplot";
rev = "v${version}";
sha256 = "sha256-r5rszxr65lSozkUNaqfBn4I4XjLtvQ6T/BG366JXLRM=";
};
outputs = [ "out" ];
nativeBuildInputs = [
makeWrapper
installShellFiles
]
++ lib.optional stdenv.hostPlatform.isDarwin shortenPerlShebang;
buildInputs = [
gnuplot
perl
]
++ (with perlPackages; [
ListMoreUtils
IPCRun
StringShellQuote
]);
# Fontconfig error: Cannot load default config file
FONTCONFIG_FILE = fontsConf;
postPatch = ''
patchShebangs .
'';
# Tests require gnuplot 4.6.4 and are completely skipped with gnuplot 5.
doCheck = false;
postInstall =
lib.optionalString stdenv.hostPlatform.isDarwin ''
shortenPerlShebang $out/bin/feedgnuplot
''
+ ''
wrapProgram $out/bin/feedgnuplot \
--prefix "PATH" ":" "$PATH" \
--prefix "PERL5LIB" ":" "$PERL5LIB"
installShellCompletion --bash --name feedgnuplot.bash completions/bash/feedgnuplot
installShellCompletion --zsh completions/zsh/_feedgnuplot
'';
meta = with lib; {
description = "General purpose pipe-oriented plotting tool";
homepage = "https://github.com/dkogan/feedgnuplot/";
license = with licenses; [
artistic1
gpl1Plus
];
platforms = platforms.unix;
maintainers = with maintainers; [ mnacamura ];
mainProgram = "feedgnuplot";
};
}

View File

@@ -0,0 +1,81 @@
{
lib,
stdenv,
fetchFromGitHub,
makeWrapper,
xorg,
imlib2Full,
libjpeg,
libpng,
curl,
libexif,
jpegexiforient,
perl,
enableAutoreload ? !stdenv.hostPlatform.isDarwin,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "feh";
version = "3.11.2";
src = fetchFromGitHub {
owner = "derf";
repo = "feh";
rev = finalAttrs.version;
hash = "sha256-bwp/hzkuwQTgPakE0zkNtBWrNUkVWt9btTD8MVx+Xq4=";
};
outputs = [
"out"
"man"
"doc"
];
nativeBuildInputs = [ makeWrapper ];
buildInputs = [
xorg.libXt
xorg.libX11
xorg.libXinerama
imlib2Full
libjpeg
libpng
curl
libexif
];
makeFlags = [
"PREFIX=${placeholder "out"}"
"exif=1"
]
++ lib.optional stdenv.hostPlatform.isDarwin "verscmp=0"
++ lib.optional enableAutoreload "inotify=1";
installTargets = [ "install" ];
postInstall = ''
wrapProgram "$out/bin/feh" --prefix PATH : "${
lib.makeBinPath [
libjpeg
jpegexiforient
]
}" \
--add-flags '--theme=feh'
'';
nativeCheckInputs = lib.singleton (perl.withPackages (p: [ p.TestCommand ]));
doCheck = true;
meta = with lib; {
description = "Light-weight image viewer";
homepage = "https://feh.finalrewind.org/";
# released under a variant of the MIT license
# https://spdx.org/licenses/MIT-feh.html
license = licenses.mit-feh;
maintainers = with maintainers; [
gepbird
globin
];
platforms = platforms.unix;
mainProgram = "feh";
};
})

View File

@@ -0,0 +1,46 @@
{
lib,
stdenv,
pkg-config,
gtk3,
glib,
keybinder3,
fetchFromGitea,
}:
stdenv.mkDerivation {
pname = "fehlstart";
version = "0.5-unstable-2025-01-12";
src = fetchFromGitea {
domain = "codeberg.org";
owner = "chuvok";
repo = "fehlstart";
rev = "cf08d6c3964da9abc8d1af0725894fef62352064";
hash = "sha256-qq0IhLzSvYnooPb4w+lno8P/tbedrDKTk27HGtQlp2I=";
};
patches = [ ./use-nix-profiles.patch ];
strictDeps = true;
nativeBuildInputs = [ pkg-config ];
buildInputs = [
gtk3
keybinder3
];
env.NIX_CFLAGS_COMPILE = "-I${lib.getDev glib}/include/gio-unix-2.0";
makeFlags = [ "PREFIX=$(out)" ];
meta = {
description = "Small desktop application launcher with reasonable memory footprint";
homepage = "https://codeberg.org/Chuvok/fehlstart";
license = lib.licenses.gpl3Only;
maintainers = [ lib.maintainers.mounium ];
platforms = lib.platforms.linux;
mainProgram = "fehlstart";
};
}

View File

@@ -0,0 +1,21 @@
diff --git a/fehlstart.c b/fehlstart.c
index b33c8ff..ce467b5 100644
--- a/fehlstart.c
+++ b/fehlstart.c
@@ -802,6 +802,16 @@ static void* update_all(void* user_data)
add_launchers(APPLICATIONS_DIR_0);
add_launchers(APPLICATIONS_DIR_1);
add_launchers(USER_APPLICATIONS_DIR);
+ const char* nixprofiles = getenv("NIX_PROFILES");
+ if(nixprofiles != NULL) {
+ const char* pch = strtok(nixprofiles, " ");
+ while (pch != NULL)
+ {
+ char* nix_dir = g_strconcat(pch, "/share/applications", NULL);
+ add_launchers(nix_dir);
+ pch = strtok(NULL, " ");
+ }
+ }
return NULL;
}

View File

@@ -0,0 +1,158 @@
{
lib,
stdenv,
buildNpmPackage,
fetchFromGitHub,
electron_36,
darwin,
copyDesktopItems,
makeDesktopItem,
}:
let
pname = "feishin";
version = "0.12.6";
src = fetchFromGitHub {
owner = "jeffvli";
repo = "feishin";
rev = "v${version}";
hash = "sha256-cnlPks/sJdcxHdIppHn8Q8d2tkwVlPMofQxjdAlBreg=";
};
electron = electron_36;
in
buildNpmPackage {
inherit pname version;
inherit src;
npmDepsHash = "sha256-lThh29prT/cHRrp2mEtUW4eeVfCtkk+54EPNUyGHyq8=";
npmFlags = [ "--legacy-peer-deps" ];
makeCacheWritable = true;
env.ELECTRON_SKIP_BINARY_DOWNLOAD = "1";
nativeBuildInputs =
lib.optionals (stdenv.hostPlatform.isLinux) [ copyDesktopItems ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.autoSignDarwinBinariesHook ];
postPatch = ''
# release/app dependencies are installed on preConfigure
substituteInPlace package.json \
--replace-fail "electron-builder install-app-deps &&" ""
# Don't check for updates.
substituteInPlace src/main/main.ts \
--replace-fail "autoUpdater.checkForUpdatesAndNotify();" ""
''
+ lib.optionalString stdenv.hostPlatform.isLinux ''
# https://github.com/electron/electron/issues/31121
substituteInPlace src/main/main.ts \
--replace-fail "process.resourcesPath" "'$out/share/feishin/resources'"
'';
preConfigure =
let
releaseAppDeps = buildNpmPackage {
pname = "${pname}-release-app";
inherit version;
src = "${src}/release/app";
npmDepsHash = "sha256-kEe5HH/oslH8vtAcJuWTOLc0ZQPxlDVMS4U0RpD8enE=";
npmFlags = [ "--ignore-scripts" ];
dontNpmBuild = true;
env.ELECTRON_SKIP_BINARY_DOWNLOAD = "1";
};
releaseNodeModules = "${releaseAppDeps}/lib/node_modules/feishin/node_modules";
in
''
for release_module_path in "${releaseNodeModules}"/*; do
rm -rf node_modules/"$(basename "$release_module_path")"
ln -s "$release_module_path" node_modules/
done
'';
postBuild =
lib.optionalString stdenv.hostPlatform.isDarwin ''
# electron-builder appears to build directly on top of Electron.app, by overwriting the files in the bundle.
cp -r ${electron.dist}/Electron.app ./
find ./Electron.app -name 'Info.plist' | xargs -d '\n' chmod +rw
# Disable code signing during build on macOS.
# https://github.com/electron-userland/electron-builder/blob/fa6fc16/docs/code-signing.md#how-to-disable-code-signing-during-the-build-process-on-macos
export CSC_IDENTITY_AUTO_DISCOVERY=false
sed -i "/afterSign/d" package.json
''
+ ''
npm exec electron-builder -- \
--dir \
-c.electronDist=${if stdenv.hostPlatform.isDarwin then "./" else electron.dist} \
-c.electronVersion=${electron.version} \
-c.npmRebuild=false
'';
installPhase = ''
runHook preInstall
''
+ lib.optionalString stdenv.hostPlatform.isDarwin ''
mkdir -p $out/{Applications,bin}
cp -r release/build/**/Feishin.app $out/Applications/
makeWrapper $out/Applications/Feishin.app/Contents/MacOS/Feishin $out/bin/feishin
''
+ lib.optionalString stdenv.hostPlatform.isLinux ''
mkdir -p $out/share/feishin
pushd release/build/*/
cp -r locales resources{,.pak} $out/share/feishin
popd
# Code relies on checking app.isPackaged, which returns false if the executable is electron.
# Set ELECTRON_FORCE_IS_PACKAGED=1.
# https://github.com/electron/electron/issues/35153#issuecomment-1202718531
makeWrapper ${lib.getExe electron} $out/bin/feishin \
--add-flags $out/share/feishin/resources/app.asar \
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime=true}}" \
--set ELECTRON_FORCE_IS_PACKAGED=1 \
--inherit-argv0
for size in 32 64 128 256 512 1024; do
mkdir -p $out/share/icons/hicolor/"$size"x"$size"/apps
ln -s \
$out/share/feishin/resources/assets/icons/"$size"x"$size".png \
$out/share/icons/hicolor/"$size"x"$size"/apps/feishin.png
done
''
+ ''
runHook postInstall
'';
desktopItems = [
(makeDesktopItem {
name = "feishin";
desktopName = "Feishin";
comment = "Full-featured Subsonic/Jellyfin compatible desktop music player";
icon = "feishin";
exec = "feishin %u";
categories = [
"Audio"
"AudioVideo"
];
mimeTypes = [ "x-scheme-handler/feishin" ];
})
];
meta = {
description = "Full-featured Subsonic/Jellyfin compatible desktop music player";
homepage = "https://github.com/jeffvli/feishin";
changelog = "https://github.com/jeffvli/feishin/releases/tag/v${version}";
sourceProvenance = with lib.sourceTypes; [ fromSource ];
license = lib.licenses.gpl3Plus;
platforms = lib.platforms.unix;
mainProgram = "feishin";
maintainers = with lib.maintainers; [
onny
jlbribeiro
];
};
}

View File

@@ -0,0 +1,235 @@
{
addDriverRunpath,
alsa-lib,
at-spi2-atk,
at-spi2-core,
atk,
autoPatchelfHook,
cairo,
cups,
dbus,
dpkg,
expat,
fetchurl,
fontconfig,
freetype,
gdk-pixbuf,
glib,
glibc,
gnutls,
gtk3,
lib,
libGL,
libX11,
libXScrnSaver,
libXcomposite,
libXcursor,
libXdamage,
libXext,
libXfixes,
libXi,
libXrandr,
libXrender,
libXtst,
libappindicator-gtk3,
libcxx,
libdbusmenu,
libdrm,
libgcrypt,
libglvnd,
libnotify,
libpulseaudio,
libuuid,
libxcb,
libxkbcommon,
libxkbfile,
libxshmfence,
makeShellWrapper,
libgbm,
nspr,
nss,
pango,
pciutils,
pipewire,
pixman,
stdenv,
systemd,
wayland,
xdg-utils,
writeScript,
# for custom command line arguments, e.g. "--use-gl=desktop"
commandLineArgs ? "",
}:
let
sources = {
x86_64-linux = fetchurl {
url = "https://sf3-cn.feishucdn.com/obj/ee-appcenter/1d078929/Feishu-linux_x64-7.50.13.deb";
sha256 = "sha256-wP3Uyz3KiWLADzUhZnPJori2gqdzEm5azUcGv8w1BXM=";
};
aarch64-linux = fetchurl {
url = "https://sf3-cn.feishucdn.com/obj/ee-appcenter/05ade0ea/Feishu-linux_arm64-7.50.13.deb";
sha256 = "sha256-9YTk3Jx1Ap5ym2N/GiN8YcB6XfyVElSWZV3/O6gJWNE=";
};
};
supportedPlatforms = [
"x86_64-linux"
"aarch64-linux"
];
rpath = lib.makeLibraryPath [
alsa-lib
at-spi2-atk
at-spi2-core
atk
cairo
cups
dbus
expat
fontconfig
freetype
gdk-pixbuf
glib
glibc
gnutls
libGL
libX11
libXScrnSaver
libXcomposite
libXcursor
libXdamage
libXext
libXfixes
libXi
libXrandr
libXrender
libXtst
libappindicator-gtk3
libcxx
libdbusmenu
libdrm
libgcrypt
libglvnd
libnotify
libpulseaudio
libuuid
libxcb
libxkbcommon
libxkbfile
libxshmfence
libgbm
nspr
nss
pango
pciutils
pipewire
pixman
stdenv.cc.cc
systemd
wayland
xdg-utils
];
in
stdenv.mkDerivation {
version = "7.50.13";
pname = "feishu";
src =
sources.${stdenv.hostPlatform.system}
or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
nativeBuildInputs = [
autoPatchelfHook
makeShellWrapper
dpkg
];
buildInputs = [
gtk3
# for autopatchelf
alsa-lib
cups
libXdamage
libXtst
libdrm
libgcrypt
libpulseaudio
libxshmfence
libgbm
nspr
nss
];
dontUnpack = true;
installPhase = ''
# This deb file contains a setuid binary,
# so 'dpkg -x' doesn't work here.
dpkg --fsys-tarfile $src | tar --extract
mkdir -p $out
mv usr/share $out/
mv opt/ $out/
substituteInPlace $out/share/applications/bytedance-feishu.desktop \
--replace /usr/bin/bytedance-feishu-stable $out/opt/bytedance/feishu/bytedance-feishu
# Wrap feishu and vulcan
# Feishu is the main executable, vulcan is the builtin browser
for executable in $out/opt/bytedance/feishu/{feishu,vulcan/vulcan}; do
# FIXME: Add back NIXOS_OZONE_WL support once upstream fixes the crash on native Wayland (see #318035)
wrapProgram $executable \
--prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH" \
--prefix LD_LIBRARY_PATH : ${rpath}:$out/opt/bytedance/feishu:${addDriverRunpath.driverLink}/share \
${lib.optionalString (
commandLineArgs != ""
) "--add-flags ${lib.escapeShellArg commandLineArgs}"}
done
mkdir -p $out/share/icons/hicolor
base="$out/opt/bytedance/feishu"
for size in 16 24 32 48 64 128 256; do
mkdir -p $out/share/icons/hicolor/''${size}x''${size}/apps
ln -s $base/product_logo_$size.png $out/share/icons/hicolor/''${size}x''${size}/apps/bytedance-feishu.png
done
mkdir -p $out/bin
ln -s $out/opt/bytedance/feishu/bytedance-feishu $out/bin/bytedance-feishu
'';
passthru = {
inherit sources;
updateScript = writeScript "update-feishu.sh" ''
#!/usr/bin/env nix-shell
#!nix-shell -i bash -p curl jq common-updater-scripts
for platform in ${lib.escapeShellArgs supportedPlatforms}; do
if [ $platform = "x86_64-linux" ]; then
platform_id=10
elif [ $platform = "aarch64-linux" ]; then
platform_id=12
else
echo "Unsupported platform: $platform"
exit 1
fi
package_info=$(curl -sf "https://www.feishu.cn/api/package_info?platform=$platform_id")
update_link=$(echo $package_info | jq -r '.data.download_link' | sed 's/lf[0-9]*-ug-sign.feishucdn.com/sf3-cn.feishucdn.com\/obj/;s/?.*$//')
new_version=$(echo $package_info | jq -r '.data.version_number' | sed -n 's/.*@V//p')
sha256_hash=$(nix-prefetch-url $update_link)
sri_hash=$(nix --extra-experimental-features nix-command hash to-sri --type sha256 $sha256_hash)
update-source-version feishu $new_version $sri_hash $update_link --system=$platform --ignore-same-version --source-key="sources.$platform"
done
'';
};
meta = {
description = "All-in-one collaboration suite";
homepage = "https://www.feishu.cn/en/";
downloadPage = "https://www.feishu.cn/en/#en_home_download_block";
license = lib.licenses.unfree;
platforms = supportedPlatforms;
maintainers = with lib.maintainers; [ billhuang ];
mainProgram = "bytedance-feishu";
};
}

View File

@@ -0,0 +1,60 @@
{
lib,
rustPlatform,
fetchFromGitHub,
pkg-config,
bzip2,
libgit2,
nix-update-script,
zlib,
zstd,
zoxide,
}:
rustPlatform.buildRustPackage rec {
pname = "felix";
version = "2.16.1";
src = fetchFromGitHub {
owner = "kyoheiu";
repo = "felix";
tag = "v${version}";
hash = "sha256-QslV0MVbIuiFDmd8A69+7nTPAUhDrn/dndZsIiNkeZ8=";
};
cargoHash = "sha256-1JjvfXyjGUHIwJJAlI2pB829kHcPrVmKOp+msDk5Qp4=";
nativeBuildInputs = [ pkg-config ];
buildInputs = [
bzip2
libgit2
zlib
zstd
];
nativeCheckInputs = [ zoxide ];
env = {
ZSTD_SYS_USE_PKG_CONFIG = true;
};
buildFeatures = [ "zstd/pkg-config" ];
checkFlags = [
# extra test files not shipped with the repository
"--skip=functions::tests::test_list_up_contents"
"--skip=state::tests::test_has_write_permission"
];
passthru.updateScript = nix-update-script { };
meta = {
description = "Tui file manager with vim-like key mapping";
homepage = "https://github.com/kyoheiu/felix";
changelog = "https://github.com/kyoheiu/felix/blob/v${version}/CHANGELOG.md";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ figsoda ];
mainProgram = "fx";
};
}

View File

@@ -0,0 +1,45 @@
{
lib,
stdenv,
fetchFromSourcehut,
unstableGitUpdater,
}:
stdenv.mkDerivation {
pname = "femtolisp";
version = "0-unstable-2024-06-18";
src = fetchFromSourcehut {
owner = "~ft";
repo = "femtolisp";
rev = "ee58f398fec62d3096b0e01da51a3969ed37a32d";
hash = "sha256-pfPD9TNLmrqhvJS/aVVmziMVApsiU5v1nAMqU+Kduzw=";
};
strictDeps = true;
enableParallelBuilding = true;
installPhase = ''
runHook preInstall
install -Dm755 -t $out/bin/ flisp
runHook postInstall
'';
passthru.updateScript = unstableGitUpdater { };
meta = {
description = "Compact interpreter for a minimal lisp/scheme dialect";
homepage = "https://git.sr.ht/~ft/femtolisp";
license = with lib.licenses; [
mit
bsd3
];
maintainers = with lib.maintainers; [ moody ];
broken = stdenv.hostPlatform.isDarwin;
platforms = lib.platforms.unix;
mainProgram = "flisp";
};
}

View File

@@ -0,0 +1,106 @@
{
lib,
fetchFromGitHub,
rustPlatform,
pandoc,
pkg-config,
openssl,
installShellFiles,
copyDesktopItems,
makeDesktopItem,
nix-update-script,
testers,
writeText,
runCommand,
fend,
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "fend";
version = "1.5.7";
src = fetchFromGitHub {
owner = "printfn";
repo = "fend";
tag = "v${finalAttrs.version}";
hash = "sha256-3qEKYb8uYsTZ+UkpJkCKeGmY3iRQz9VfklE4LmcdA2E=";
};
cargoHash = "sha256-HzmRO7MDSVJHkeOWIKrEnaFmq68rCBcmWvXwQWGzA/s=";
nativeBuildInputs = [
pandoc
installShellFiles
pkg-config
copyDesktopItems
];
buildInputs = [
pkg-config
openssl
];
postBuild = ''
patchShebangs --build ./documentation/build.sh
./documentation/build.sh
'';
preFixup = ''
installManPage documentation/fend.1
'';
doInstallCheck = true;
installCheckPhase = ''
[[ "$($out/bin/fend "1 km to m")" = "1000 m" ]]
'';
postInstall = ''
install -D -m 444 $src/icon/icon.svg $out/share/icons/hicolor/scalable/apps/fend.svg
'';
desktopItems = [
(makeDesktopItem {
name = "fend";
desktopName = "fend";
genericName = "Calculator";
comment = "Arbitrary-precision unit-aware calculator";
icon = "fend";
exec = "fend";
terminal = true;
categories = [
"Utility"
"Calculator"
"ConsoleOnly"
];
})
];
passthru = {
updateScript = nix-update-script { };
tests = {
version = testers.testVersion { package = fend; };
units = testers.testEqualContents {
assertion = "fend does simple math and unit conversions";
expected = writeText "expected" ''
36 kph
'';
actual = runCommand "actual" { } ''
${lib.getExe fend} '(100 meters) / (10 seconds) to kph' > $out
'';
};
};
};
meta = {
description = "Arbitrary-precision unit-aware calculator";
homepage = "https://github.com/printfn/fend";
changelog = "https://github.com/printfn/fend/releases/tag/${finalAttrs.src.tag}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [
djanatyn
liff
];
mainProgram = "fend";
};
})

View File

@@ -0,0 +1,39 @@
{
lib,
stdenv,
fetchFromSourcehut,
lua,
luaPackages,
pandoc,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "fennel-ls";
version = "0.2.1";
src = fetchFromSourcehut {
owner = "~xerool";
repo = "fennel-ls";
rev = finalAttrs.version;
hash = "sha256-6ZbGRTBBRktudGVBZ+UMn8l0+wKa8f5dg7UOwLhOT7E=";
};
buildInputs = [
lua
luaPackages.fennel
];
nativeBuildInputs = [ pandoc ];
makeFlags = [ "PREFIX=$(out)" ];
installFlags = [ "PREFIX=$(out)" ];
meta = {
description = "Language server for intelligent editing of the Fennel Programming Language";
homepage = "https://git.sr.ht/~xerool/fennel-ls/";
license = lib.licenses.mit;
changelog = "https://git.sr.ht/~xerool/fennel-ls/refs/${finalAttrs.version}";
maintainers = with lib.maintainers; [
luftmensch-luftmensch
yisraeldov
];
inherit (lua.meta) platforms;
mainProgram = "fennel-ls";
};
})

View File

@@ -0,0 +1,46 @@
{
lib,
fetchFromGitHub,
rustPlatform,
installShellFiles,
}:
rustPlatform.buildRustPackage rec {
pname = "ferium";
version = "4.7.1";
src = fetchFromGitHub {
owner = "gorilla-devs";
repo = "ferium";
rev = "v${version}";
hash = "sha256-eeQjezB6pRdnPADLgDLo8b+bUSP12gfBhFNt/uYCwHU=";
};
cargoHash = "sha256-3YKFKngyLg2ah4GY+LlbPbnVks7/xFawnMf3D1gjmwI=";
# Disable the GUI file picker so that GTK/XDG dependencies aren't used
buildNoDefaultFeatures = true;
# Requires an internet connection
doCheck = false;
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
for shell in bash fish zsh; do
$out/bin/ferium complete $shell > ferium.$shell
installShellCompletion ferium.$shell
done
'';
meta = with lib; {
description = "Fast and multi-source CLI program for managing Minecraft mods and modpacks from Modrinth, CurseForge, and GitHub Releases";
mainProgram = "ferium";
homepage = "https://github.com/gorilla-devs/ferium";
license = licenses.mpl20;
maintainers = with maintainers; [
leo60228
soupglasses
];
};
}

View File

@@ -0,0 +1,14 @@
--- old/src/import-ferm
+++ new/src/import-ferm
@@ -42,9 +42,9 @@
# find the main "ferm" program
my $ferm;
if ($0 =~ /^(.*)\//) {
- $ferm = "$1/ferm";
+ $ferm = "$1/.ferm-wrapped";
} else {
- $ferm = 'ferm';
+ $ferm = '.ferm-wrapped';
}
# Perl 5.24 requires this prefix or else it will only look in @INC

View File

@@ -0,0 +1,62 @@
{
lib,
stdenv,
fetchurl,
makeWrapper,
perl,
iptables,
nixosTests,
}:
let
inherit (lib.versions) majorMinor;
in
stdenv.mkDerivation rec {
version = "2.7";
pname = "ferm";
src = fetchurl {
url = "http://ferm.foo-projects.org/download/${majorMinor version}/ferm-${version}.tar.xz";
sha256 = "sha256-wA2RDVOU5pZ1YI617g9QTVz9pB6ZCi2akbqsbfk+P5I=";
};
patches = [
./import-ferm-wrapped.patch
];
# perl is used at build time to gather the ferm version.
nativeBuildInputs = [
makeWrapper
perl
];
buildInputs = [ perl ];
makeFlags = [
"PERL=perl"
"PREFIX=${placeholder "out"}"
];
postInstall = ''
rm -r $out/lib/systemd
for i in "$out/sbin/"*; do
wrapProgram "$i" --prefix PATH : "${lib.makeBinPath [ iptables ]}"
done
'';
passthru.tests.ferm = nixosTests.ferm;
meta = {
homepage = "http://ferm.foo-projects.org/";
description = "Tool to maintain complex firewalls";
longDescription = ''
ferm is a tool to maintain complex firewalls, without having the trouble to
rewrite the complex rules over and over again. ferm allows the entire
firewall rule set to be stored in a separate file, and to be loaded with one
command. The firewall configuration resembles structured programming-like
language, which can contain levels and lists.
'';
license = lib.licenses.gpl2Plus;
maintainers = with lib.maintainers; [ mic92 ];
platforms = lib.platforms.linux;
};
}

View File

@@ -0,0 +1,34 @@
{
config,
lib,
fetchFromGitHub,
zlib,
stdenv,
}:
stdenv.mkDerivation {
pname = "fermi2";
version = "0.1-unstable-2021-05-21";
src = fetchFromGitHub {
owner = "lh3";
repo = "fermi2";
rev = "cb1410972b2bd330883823116931ae67ead8b30f";
hash = "sha256-jDn1OBuGWDMEHI5A3R9meOykEGM6yjItSnUpx36DxgA=";
};
buildInputs = [ zlib ];
makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
installPhase = ''
runHook preInstall
install -Dm755 fermi2 -t $out/bin
runHook postInstall
'';
meta = {
homepage = "https://github.com/lh3/fermi2";
description = "Successor of fermi, a whole genome de novo assembler based on the FMD-index for large genomes";
mainProgram = "fermi2";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ apraga ];
platforms = lib.intersectLists lib.platforms.x86_64 lib.platforms.unix;
};
}

View File

@@ -0,0 +1,75 @@
{
lib,
stdenv,
fetchurl,
autoPatchelfHook,
gcc-unwrapped,
zlib,
}:
let
system = stdenv.hostPlatform.system;
platform =
{
x86_64-linux = "linux-amd64";
aarch64-linux = "linux-aarch64";
x86_64-darwin = "macos-amd64";
aarch64-darwin = "macos-aarch64";
}
.${system} or (throw "Unsupported system: ${system}");
# TODO: It'd be nice to write an update script that would update all of these
# hashes together.
packageHash =
{
x86_64-linux = "sha256-r/F3Tj3WeeL2R27ussX+ebFWpW+8z2e7tdBK4MHFMpk=";
aarch64-linux = "sha256-BSFxDJeY7fOOxDqAV+6FJf0hup1Y5IJ/czqwc4W7qSA=";
x86_64-darwin = "sha256-T6J9IjfXdt9DnZksndAmZRkYyH/5H60J7V6xU0ltD2A=";
aarch64-darwin = "sha256-6x+0PB5/2oqYDVNiNhc0xcs/ESCLvvSsWtm2KlTIeBo=";
}
.${system} or (throw "Unsupported system: ${system}");
in
stdenv.mkDerivation rec {
pname = "fermyon-spin";
version = "3.0.0";
# Use fetchurl rather than fetchzip as these tarballs are built by the project
# and not by GitHub (and thus are stable) - this simplifies the update script
# by allowing it to use the output of `nix store prefetch-file`.
src = fetchurl {
url = "https://github.com/fermyon/spin/releases/download/v${version}/spin-v${version}-${platform}.tar.gz";
hash = packageHash;
};
sourceRoot = ".";
nativeBuildInputs = lib.optionals stdenv.hostPlatform.isLinux [
autoPatchelfHook
];
buildInputs = [
gcc-unwrapped.lib
zlib
];
installPhase = ''
runHook preInstall
mkdir -p $out/bin
cp ./spin $out/bin
runHook postInstall
'';
meta = with lib; {
description = "Framework for building, deploying, and running fast, secure, and composable cloud microservices with WebAssembly";
homepage = "https://github.com/fermyon/spin";
sourceProvenance = with sourceTypes; [ binaryNativeCode ];
license = with licenses; [ asl20 ];
mainProgram = "spin";
maintainers = [ ];
platforms = platforms.linux ++ platforms.darwin;
};
}

View File

@@ -0,0 +1,31 @@
#!/usr/bin/env nix-shell
#!nix-shell -i bash -p jq
#shellcheck shell=bash
CURRENT_HASH=""
print_hash() {
OS="$1"
ARCH="$2"
VERSION="$3"
URL="https://github.com/fermyon/spin/releases/download/v${VERSION}/spin-v${VERSION}-${OS}-${ARCH}.tar.gz"
echo
CURRENT_HASH=$(nix store prefetch-file "$URL" --json | jq -r '.hash')
echo "${ARCH}-${OS}: $CURRENT_HASH"
}
if [[ -z "$VER" && -n "$1" ]]; then
VER="$1"
fi
if [[ -z "$VER" ]]; then
echo "No 'VER' environment variable provided, skipping"
else
print_hash "linux" "amd64" "$VER"
print_hash "linux" "aarch64" "$VER"
print_hash "macos" "amd64" "$VER"
print_hash "macos" "aarch64" "$VER"
fi

View File

@@ -0,0 +1,83 @@
{
lib,
stdenv,
rustPlatform,
fetchFromGitHub,
fetchYarnDeps,
fixup-yarn-lock,
python3,
jq,
yarn,
nodejs-slim,
}:
rustPlatform.buildRustPackage rec {
pname = "fernglas";
version = "0.2.1";
src = fetchFromGitHub {
owner = "wobcom";
repo = "fernglas";
rev = "fernglas-${version}";
hash = "sha256-0wj5AS8RLVr+S/QWWxCsMvmVjmXUWGfR9kPaZimJEss=";
};
nativeBuildInputs = [
yarn
nodejs-slim
fixup-yarn-lock
python3
jq
];
nlnog_communities = fetchFromGitHub {
owner = "NLNOG";
repo = "lg.ring.nlnog.net";
rev = "20f9a9f3da8b1bc9d7046e88c62df4b41b4efb99";
hash = "sha256-FlbOBX/+/LLmoqMJLvu59XuHYmiohIhDc1VjkZu4Wzo=";
};
cargoHash = "sha256-aY5/dIplV8yWaQ2IdWxxC7T1DoKeRjsN5eT+UxsaA1E=";
offlineCache = fetchYarnDeps {
yarnLock = src + "/frontend/yarn.lock";
hash = "sha256-/ubCAs4C5nG8xNC77jTH+cJVNgddSxqGGPEVLDH/Cdo=";
};
cargoBuildFlags =
lib.optionals (stdenv.hostPlatform.isMusl && stdenv.hostPlatform.isStatic) [
"--features"
"mimalloc"
]
++ [
"--features"
"embed-static"
];
preBuild = ''
python3 contrib/print_communities.py $nlnog_communities/communities | jq . > src/communities.json
pushd frontend
export HOME=$TMPDIR
yarn config --offline set yarn-offline-mirror $offlineCache
fixup-yarn-lock yarn.lock
yarn install --offline --frozen-lockfile --ignore-scripts --no-progress --non-interactive
patchShebangs node_modules/
FERNGLAS_VERSION=${version} FERNGLAS_COMMIT=${src.rev} node_modules/.bin/webpack
cp -r dist/ ../static
popd
'';
meta = {
description = "Looking glass for your network using BGP and BMP as data source";
homepage = "https://wobcom.github.io/fernglas/";
changelog = "https://github.com/wobcom/fernglas/releases/tag/fernglas-${version}";
license = lib.licenses.eupl12;
platforms = lib.platforms.linux;
teams = [ lib.teams.wdz ];
mainProgram = "fernglas";
};
}

View File

@@ -0,0 +1,52 @@
{
lib,
stdenv,
fetchFromGitHub,
openssl,
pkg-config,
rustPlatform,
nix-update-script,
versionCheckHook,
}:
rustPlatform.buildRustPackage rec {
pname = "feroxbuster";
version = "2.12.0";
src = fetchFromGitHub {
owner = "epi052";
repo = "feroxbuster";
tag = "v${version}";
hash = "sha256-uVRZp9r3888k//UsNUr7NKQcmFe2/RLmlIt/RgZ3Ips=";
};
cargoHash = "sha256-W6sNc8RVItOGHIw3vmtZlJayqrzvmuET2B2AIl7LAL4=";
OPENSSL_NO_VENDOR = true;
nativeBuildInputs = [
pkg-config
versionCheckHook
];
buildInputs = [ openssl ];
# Tests require network access
doCheck = false;
doInstallCheck = true;
versionCheckProgramArg = "--version";
passthru.updateScript = nix-update-script { };
meta = with lib; {
description = "Recursive content discovery tool";
homepage = "https://github.com/epi052/feroxbuster";
changelog = "https://github.com/epi052/feroxbuster/releases/tag/v${src.tag}";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
platforms = platforms.unix;
mainProgram = "feroxbuster";
};
}

View File

@@ -0,0 +1,53 @@
{
lib,
buildGoModule,
fetchFromGitHub,
nixosTests,
versionCheckHook,
}:
buildGoModule (finalAttrs: {
pname = "ferretdb";
version = "1.24.0";
src = fetchFromGitHub {
owner = "FerretDB";
repo = "FerretDB";
tag = "v${finalAttrs.version}";
hash = "sha256-WMejspnk2PvJhvNGi4h+DF+fzipuOMcS1QWim5DnAhQ=";
};
postPatch = ''
echo v${finalAttrs.version} > build/version/version.txt
echo nixpkgs > build/version/package.txt
'';
vendorHash = "sha256-GT6e9yd6LF6GFlGBWVAmcM6ysB/6cIGLbnM0hxfX5TE=";
env.CGO_ENABLED = 0;
subPackages = [ "cmd/ferretdb" ];
# tests in cmd/ferretdb are not production relevant
doCheck = false;
# the binary panics if something required wasn't set during compilation
doInstallCheck = true;
nativeInstallCheckInputs = [ versionCheckHook ];
versionCheckProgramArg = "--version";
passthru.tests = nixosTests.ferretdb;
meta = {
description = "Truly Open Source MongoDB alternative";
mainProgram = "ferretdb";
changelog = "https://github.com/FerretDB/FerretDB/releases/tag/v${finalAttrs.version}";
homepage = "https://www.ferretdb.com/";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [
dit7ya
noisersup
julienmalka
];
};
})

View File

@@ -0,0 +1,69 @@
{
lib,
stdenv,
rustPlatform,
fetchFromGitHub,
makeBinaryWrapper,
writableTmpDirAsHomeHook,
libGL,
libX11,
libxkbcommon,
libxcb,
wayland,
nix-update-script,
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "ferrishot";
version = "0.2.0";
src = fetchFromGitHub {
owner = "nik-rev";
repo = "ferrishot";
tag = "v${finalAttrs.version}";
hash = "sha256-QnIHLkxqL/4s6jgIbGmzR5tqCjH7yJcfpx0AhdxqVKc=";
};
cargoHash = "sha256-TJWS8LzLTQSr+0uw0x38mNJrjYvMzr90URYI8UcRQqc=";
nativeBuildInputs = [
makeBinaryWrapper
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# error: unable to open output file '/homeless-shelter/.cache/clang/ModuleCache/354UBE8EJRBZ3/Cocoa-31YYBL2V1XGQP.pcm': 'No such file or directory'
writableTmpDirAsHomeHook
];
buildInputs = lib.optionals stdenv.hostPlatform.isLinux [
libxcb
];
postInstall =
let
runtimeDeps = [
libGL
]
++ lib.optionals stdenv.hostPlatform.isLinux [
libX11
libxkbcommon
wayland
];
in
''
wrapProgram $out/bin/ferrishot \
--prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath runtimeDeps}"
'';
passthru = {
updateScript = nix-update-script { };
};
meta = {
description = "Screenshot app written in Rust";
homepage = "https://github.com/nik-rev/ferrishot";
changelog = "https://github.com/nik-rev/ferrishot/blob/v${finalAttrs.version}/CHANGELOG.md";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ GaetanLepage ];
mainProgram = "ferrishot";
};
})

View File

@@ -0,0 +1,57 @@
{
lib,
rustPlatform,
fetchFromGitHub,
pkg-config,
zstd,
versionCheckHook,
nix-update-script,
}:
rustPlatform.buildRustPackage (finalAttrs: {
pname = "ferron";
version = "1.3.5";
src = fetchFromGitHub {
owner = "ferronweb";
repo = "ferron";
tag = finalAttrs.version;
hash = "sha256-bBIhLkh9UV2MJKovQaFk3cC1rYafiyxknRlKWVQ5gwY=";
};
cargoHash = "sha256-xsJJglSq8hpWWi0zknPL03nle99GxznPI3HON2o8zco=";
nativeBuildInputs = [
pkg-config
];
buildInputs = [
zstd
];
env = {
ZSTD_SYS_USE_PKG_CONFIG = true;
};
nativeInstallCheckInputs = [
versionCheckHook
];
versionCheckProgramArg = "--version";
doInstallCheck = true;
passthru = {
updateScript = nix-update-script { };
};
meta = {
description = "Fast, memory-safe web server written in Rust";
homepage = "https://github.com/ferronweb/ferron";
changelog = "https://github.com/ferronweb/ferron/releases/tag/${finalAttrs.version}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [
_0x4A6F
GaetanLepage
];
mainProgram = "ferron";
};
})

View File

@@ -0,0 +1,39 @@
{
lib,
stdenvNoCC,
fetchzip,
}:
let
majorVersion = "0";
minorVersion = "200";
in
stdenvNoCC.mkDerivation {
pname = "ferrum";
version = "${majorVersion}.${minorVersion}";
src = fetchzip {
url = "https://dotcolon.net/download/fonts/ferrum_${majorVersion}${minorVersion}.zip";
hash = "sha256-NDJwgFWZgyhMkGRWlY55l2omEw6ju3e3dHCEsWNzQIc=";
stripRoot = false;
};
installPhase = ''
runHook preInstall
install -D -m444 -t $out/share/fonts/opentype $src/*.otf
runHook postInstall
'';
meta = with lib; {
homepage = "http://dotcolon.net/font/ferrum/";
description = "Decorative font";
platforms = platforms.all;
maintainers = with maintainers; [
leenaars
minijackson
];
license = licenses.cc0;
};
}

View File

@@ -0,0 +1,43 @@
{
lib,
python3,
fetchFromGitHub,
}:
python3.pkgs.buildPythonApplication rec {
pname = "fertilizer";
version = "0.3.0";
pyproject = true;
src = fetchFromGitHub {
owner = "moleculekayak";
repo = "fertilizer";
tag = "v${version}";
hash = "sha256-sDoAjEiKxHf+HtFLZr6RwuXN+rl0ZQnFUoQ09QiE6Xc=";
};
build-system = with python3.pkgs; [ setuptools ];
dependencies = with python3.pkgs; [
bencoder
colorama
flask
requests
];
nativeCheckInputs = with python3.pkgs; [
pytestCheckHook
requests-mock
];
pythonImportsCheck = [ "fertilizer" ];
meta = {
description = "Cross-seeding tool for music";
homepage = "https://github.com/moleculekayak/fertilizer";
changelog = "https://github.com/moleculekayak/fertilizer/releases";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ ambroisie ];
mainProgram = "fertilizer";
};
}

View File

@@ -0,0 +1,34 @@
{
stdenvNoCC,
lib,
fetchFromGitHub,
}:
stdenvNoCC.mkDerivation rec {
pname = "fet-sh";
version = "1.9";
src = fetchFromGitHub {
owner = "6gk";
repo = "fet.sh";
rev = "v${version}";
sha256 = "sha256-xhX2nVteC3T3IjQh++mYlm0btDJQbyQa6b8sGualV0E=";
};
postPatch = ''
patchShebangs fet.sh
'';
installPhase = ''
install -m755 -D fet.sh $out/bin/fet.sh
'';
meta = with lib; {
description = "Fetch written in posix shell without any external commands";
homepage = "https://github.com/6gk/fet.sh";
license = licenses.isc;
platforms = platforms.all;
maintainers = with maintainers; [ elkowar ];
mainProgram = "fet.sh";
};
}

View File

@@ -0,0 +1,37 @@
{
lib,
stdenv,
fetchFromGitHub,
guile,
}:
stdenv.mkDerivation rec {
pname = "fetch-scm";
version = "0.1.6";
src = fetchFromGitHub {
owner = "KikyTokamuro";
repo = "fetch.scm";
rev = "v${version}";
sha256 = "sha256-WdYi8EVxQ6xPtld8JyZlUmgpxroevBehtkRANovMh2E=";
};
dontBuild = true;
buildInputs = [ guile ];
installPhase = ''
runHook preInstall
install -Dm555 fetch.scm $out/bin/fetch-scm
runHook postInstall
'';
meta = with lib; {
description = "System information fetcher written in GNU Guile Scheme";
homepage = "https://github.com/KikyTokamuro/fetch.scm";
license = licenses.mit;
platforms = platforms.all;
maintainers = with maintainers; [ vel ];
mainProgram = "fetch-scm";
};
}

View File

@@ -0,0 +1,87 @@
{
lib,
stdenv,
buildGoModule,
fetchFromGitHub,
installShellFiles,
lvm2,
pkg-config,
}:
buildGoModule (finalAttrs: {
pname = "fetchit";
version = "0.0.1";
src = fetchFromGitHub {
owner = "containers";
repo = "fetchit";
tag = "v${finalAttrs.version}";
hash = "sha256-hxS/+/fbYOpMJ5VfvvG5l7wWKBUUR22rYn9X79DzUUk=";
};
vendorHash = "sha256-SyPd8P9s8R2YbGEPqFeztF98W1QyGSBumtirSdpm8VI=";
subPackages = [ "cmd/fetchit" ];
nativeBuildInputs = [
pkg-config
installShellFiles
];
buildInputs = [ lvm2 ];
# Flags are derived from
# https://github.com/containers/fetchit/blob/v0.0.1/Makefile#L20-L29
ldflags = [
"-X k8s.io/client-go/pkg/version.gitMajor=0"
"-X k8s.io/client-go/pkg/version.gitMinor=0"
"-X k8s.io/client-go/pkg/version.gitTreeState=clean"
"-X k8s.io/client-go/pkg/version.gitVersion=v0.0.0"
"-X k8s.io/component-base/version.gitMajor=0"
"-X k8s.io/component-base/version.gitMajor=0"
"-X k8s.io/component-base/version.gitMinor=0"
"-X k8s.io/component-base/version.gitTreeState=clean"
"-X k8s.io/component-base/version.gitVersion=v0.0.0"
"-s"
"-w"
];
tags = [
"containers_image_openpgp"
"exclude_graphdriver_btrfs"
"gssapi"
"include_gcs"
"include_oss"
"netgo"
"osusergo"
"providerless"
];
# There are no tests for cmd/fetchit.
doCheck = false;
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
for i in bash fish zsh; do
installShellCompletion --cmd fetchit \
--$i <($out/bin/fetchit completion $i)
done
'';
meta = {
description = "Tool to manage the life cycle and configuration of Podman containers";
mainProgram = "fetchit";
longDescription = ''
FetchIt allows for a GitOps based approach to manage containers running on
a single host or multiple hosts based on a git repository. This allows for
us to deploy a new host and provide the host a configuration value for
FetchIt and automatically any containers defined in the git repository and
branch will be deployed onto the host. This can be beneficial for
environments that do not require the complexity of Kubernetes to manage
the containers running on the host.
'';
homepage = "https://fetchit.readthedocs.io";
changelog = "https://github.com/containers/fetchit/releases/tag/v${finalAttrs.version}";
license = lib.licenses.agpl3Plus;
maintainers = with lib.maintainers; [ guylamar2006 ];
platforms = lib.platforms.linux;
};
})

View File

@@ -0,0 +1,41 @@
{
lib,
stdenvNoCC,
fetchFromGitHub,
bash,
scdoc,
}:
stdenvNoCC.mkDerivation {
pname = "fetchutils";
version = "unstable-2021-03-16";
src = fetchFromGitHub {
owner = "kiedtl";
repo = "fetchutils";
rev = "882781a297e86f4ad4eaf143e0777fb3e7c69526";
sha256 = "sha256-ONrVZC6GBV5v3TeBekW9ybZjDHF3FNyXw1rYknqKRbk=";
};
nativeBuildInputs = [
scdoc
];
buildInputs = [
bash
];
installFlags = [ "PREFIX=$(out)/" ];
postPatch = ''
patchShebangs --host src/*
'';
meta = with lib; {
description = "Collection of small shell utilities to fetch system information";
homepage = "https://github.com/lptstr/fetchutils";
license = licenses.mit;
platforms = platforms.unix;
maintainers = with maintainers; [ moni ];
};
}

View File

@@ -0,0 +1,7 @@
{
fex,
}:
fex.override {
withQt = false;
}

View File

@@ -0,0 +1,240 @@
{
lib,
llvmPackages,
fetchFromGitHub,
cmake,
ninja,
pkg-config,
python3,
nix-update-script,
xxHash,
fmt,
libxml2,
openssl,
range-v3,
catch2_3,
nasm,
buildEnv,
writeText,
pkgsCross,
libclang,
libllvm,
alsa-lib,
libdrm,
libGL,
wayland,
xorg,
withQt ? true,
qt6,
}:
let
# Headers required to build the ThunkLibs subtree
libForwardingInputs = lib.map lib.getInclude [
alsa-lib
libdrm
libGL
wayland
xorg.libX11
xorg.libxcb
xorg.libXrandr
xorg.libXrender
xorg.xorgproto
];
pkgsCross32 = pkgsCross.gnu32;
pkgsCross64 = pkgsCross.gnu64;
devRootFS = buildEnv {
name = "fex-dev-rootfs";
paths = [
pkgsCross64.stdenv.cc.libc_dev
pkgsCross32.stdenv.cc.libc_dev
pkgsCross64.stdenv.cc.cc
pkgsCross32.stdenv.cc.cc
]
++ libForwardingInputs;
ignoreCollisions = true;
pathsToLink = [
"/include"
"/lib"
];
postBuild = ''
mkdir -p $out/usr
ln -s $out/include $out/usr/
'';
};
toolchain32 = writeText "toolchain_nix_x86_32.txt" ''
set(CMAKE_EXE_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_MODULE_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_SHARED_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_SYSTEM_PROCESSOR i686)
set(CMAKE_C_COMPILER clang)
set(CMAKE_CXX_COMPILER clang++)
set(CMAKE_C_COMPILER ${pkgsCross32.buildPackages.clang}/bin/i686-unknown-linux-gnu-clang)
set(CMAKE_CXX_COMPILER ${pkgsCross32.buildPackages.clang}/bin/i686-unknown-linux-gnu-clang++)
set(CLANG_FLAGS "-nodefaultlibs -nostartfiles -target i686-linux-gnu -msse2 -mfpmath=sse --sysroot=${devRootFS} -iwithsysroot/usr/include")
set(CMAKE_C_FLAGS "''${CMAKE_C_FLAGS} ''${CLANG_FLAGS}")
set(CMAKE_CXX_FLAGS "''${CMAKE_CXX_FLAGS} ''${CLANG_FLAGS}")
'';
toolchain = writeText "toolchain_nix_x86_64.txt" ''
set(CMAKE_EXE_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_MODULE_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_SHARED_LINKER_FLAGS_INIT "-fuse-ld=lld")
set(CMAKE_SYSTEM_PROCESSOR x86_64)
set(CMAKE_C_COMPILER clang)
set(CMAKE_CXX_COMPILER clang++)
set(CMAKE_C_COMPILER ${pkgsCross64.buildPackages.clang}/bin/x86_64-unknown-linux-gnu-clang)
set(CMAKE_CXX_COMPILER ${pkgsCross64.buildPackages.clang}/bin/x86_64-unknown-linux-gnu-clang++)
set(CLANG_FLAGS "-nodefaultlibs -nostartfiles -target x86_64-linux-gnu --sysroot=${devRootFS} -iwithsysroot/usr/include")
set(CMAKE_C_FLAGS "''${CMAKE_C_FLAGS} ''${CLANG_FLAGS}")
set(CMAKE_CXX_FLAGS "''${CMAKE_CXX_FLAGS} ''${CLANG_FLAGS}")
'';
in
llvmPackages.stdenv.mkDerivation (finalAttrs: {
pname = "fex";
version = "2509.1";
src = fetchFromGitHub {
owner = "FEX-Emu";
repo = "FEX";
tag = "FEX-${finalAttrs.version}";
hash = "sha256-eTm1ee8eS+OwzEUoklrrQDRIAJVX0FWBaWi2/TJrx48=";
leaveDotGit = true;
postFetch = ''
cd $out
git reset
# Only fetch required submodules
git submodule update --init --depth 1 \
External/Vulkan-Headers \
External/drm-headers \
External/jemalloc \
External/jemalloc_glibc \
External/robin-map \
External/vixl \
Source/Common/cpp-optparse
find . -name .git -print0 | xargs -0 rm -rf
# Remove some more unnecessary directories
rm -r \
External/vixl/src/aarch32 \
External/vixl/test
'';
};
postPatch = ''
substituteInPlace ThunkLibs/GuestLibs/CMakeLists.txt ThunkLibs/HostLibs/CMakeLists.txt \
--replace-fail "/usr/include/libdrm" "${devRootFS}/include/libdrm" \
--replace-fail "/usr/include/wayland" "${devRootFS}/include/wayland"
# Add include paths for thunkgen invocation
substituteInPlace ThunkLibs/HostLibs/CMakeLists.txt \
--replace-fail "-- " "-- $(cat ${llvmPackages.stdenv.cc}/nix-support/libc-cflags) $(cat ${llvmPackages.stdenv.cc}/nix-support/libcxx-cxxflags) ${
lib.concatMapStrings (x: "-isystem " + x + "/include ") libForwardingInputs
}"
substituteInPlace ThunkLibs/GuestLibs/CMakeLists.txt \
--replace-fail "-- " "-- $(cat ${llvmPackages.stdenv.cc}/nix-support/libcxx-cxxflags) "
# Patch any references to library wrapper paths
substituteInPlace FEXCore/Source/Interface/Config/Config.json.in \
--replace-fail "ThunkGuestLibs" "UnusedThunkGuestLibs" \
--replace-fail "ThunkHostLibs" "UnusedThunkHostLibs"
substituteInPlace FEXCore/Source/Interface/Config/Config.cpp \
--replace-fail "FEXCore::Config::CONFIG_THUNKGUESTLIBS" "FEXCore::Config::CONFIG_UNUSEDTHUNKGUESTLIBS" \
--replace-fail "FEXCore::Config::CONFIG_THUNKHOSTLIBS" "FEXCore::Config::CONFIG_UNUSEDTHUNKHOSTLIBS"
substituteInPlace Source/Tools/LinuxEmulation/VDSO_Emulation.cpp \
--replace-fail "FEX_CONFIG_OPT(ThunkGuestLibs, THUNKGUESTLIBS);" "auto ThunkGuestLibs = []() { return \"$out/share/fex-emu/GuestThunks/\"; };"
substituteInPlace Source/Tools/LinuxEmulation/LinuxSyscalls/FileManagement.h \
--replace-fail "FEX_CONFIG_OPT(ThunkGuestLibs, THUNKGUESTLIBS);" "fextl::string ThunkGuestLibs() { return \"$out/share/fex-emu/GuestThunks/\"; }"
substituteInPlace Source/Tools/LinuxEmulation/Thunks.cpp \
--replace-fail "FEX_CONFIG_OPT(ThunkHostLibsPath, THUNKHOSTLIBS);" "fextl::string ThunkHostLibsPath() { return \"$out/lib/fex-emu/HostThunks/\"; }"
substituteInPlace Source/Tools/FEXConfig/main.qml \
--replace-fail "config: \"Thunk" "config: \"UnusedThunk" \
--replace-fail "title: qsTr(\"Library forwarding:\")" "visible: false; title: qsTr(\"Library forwarding:\")"
'';
nativeBuildInputs = [
cmake
ninja
pkg-config
llvmPackages.bintools
(python3.withPackages (
pythonPackages: with pythonPackages; [
setuptools
libclang
]
))
]
++ lib.optional withQt qt6.wrapQtAppsHook;
buildInputs = [
xxHash
fmt
libxml2
openssl
range-v3
pkgsCross64.buildPackages.clang
pkgsCross32.buildPackages.clang
libclang
libllvm
]
++ libForwardingInputs
++ lib.optionals withQt [
qt6.qtbase
qt6.qtdeclarative
];
cmakeFlags = [
(lib.cmakeFeature "USE_LINKER" "lld")
(lib.cmakeFeature "OVERRIDE_VERSION" finalAttrs.version)
(lib.cmakeBool "BUILD_TESTING" finalAttrs.finalPackage.doCheck)
(lib.cmakeBool "BUILD_THUNKS" true)
(lib.cmakeBool "BUILD_FEXCONFIG" withQt)
(lib.cmakeFeature "X86_32_TOOLCHAIN_FILE" "${toolchain32}")
(lib.cmakeFeature "X86_64_TOOLCHAIN_FILE" "${toolchain}")
(lib.cmakeFeature "X86_DEV_ROOTFS" "${devRootFS}")
];
strictDeps = true;
# Unsupported on non-4K page size kernels (e.g. Apple Silicon)
doCheck = true;
nativeCheckInputs = [ nasm ];
checkInputs = [ catch2_3 ];
# List not exhaustive, e.g. because they depend on an x86 compiler or some
# other difficult-to-build test binaries.
checkTarget = lib.concatStringsSep " " [
"asm_tests"
"api_tests"
"fexcore_apitests"
"emitter_tests"
];
# Avoid wrapping anything other than FEXConfig, since the wrapped executables
# don't seem to work when registered as binfmts.
dontWrapQtApps = true;
preFixup = lib.optionalString withQt ''
wrapQtApp $out/bin/FEXConfig
'';
passthru = {
updateScript = nix-update-script { };
};
meta = {
description = "Fast usermode x86 and x86-64 emulator for Arm64 Linux";
homepage = "https://fex-emu.com/";
changelog = "https://github.com/FEX-Emu/FEX/releases/tag/FEX-${finalAttrs.version}";
platforms = [ "aarch64-linux" ];
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ andre4ik3 ];
mainProgram = "FEXBash";
};
})