Skip to content

Commit

Permalink
arti: move to by-name, modernize derivation and add rapiteanu as main…
Browse files Browse the repository at this point in the history
…tainer (NixOS#343720)
  • Loading branch information
wegank authored Sep 29, 2024
2 parents aa4c638 + 71fd6fe commit 61e26f8
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 20 deletions.
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
{ lib
, stdenv
, rustPlatform
, fetchFromGitLab
, pkg-config
, sqlite
, openssl
, CoreServices
{
lib,
stdenv,
rustPlatform,
fetchFromGitLab,
pkg-config,
sqlite,
openssl,
darwin,
}:

rustPlatform.buildRustPackage rec {
Expand All @@ -25,26 +26,41 @@ rustPlatform.buildRustPackage rec {

nativeBuildInputs = lib.optionals stdenv.hostPlatform.isLinux [ pkg-config ];

buildInputs = [ sqlite ]
++ lib.optionals stdenv.hostPlatform.isLinux [ openssl ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ CoreServices ];
buildInputs =
[ sqlite ]
++ lib.optionals stdenv.isLinux [ openssl ]
++ lib.optionals stdenv.isDarwin (
with darwin.apple_sdk.frameworks;
[
CoreServices
]
);

cargoBuildFlags = [ "--package" "arti" ];
cargoBuildFlags = [
"--package"
"arti"
];

cargoTestFlags = [ "--package" "arti" ];
cargoTestFlags = [
"--package"
"arti"
];

checkFlags = [
# problematic tests that were fixed after the release
"--skip=reload_cfg::test::watch_single_file"
"--skip=reload_cfg::test::watch_multiple"
];

meta = with lib; {
meta = {
description = "Implementation of Tor in Rust";
mainProgram = "arti";
homepage = "https://arti.torproject.org/";
changelog = "https://gitlab.torproject.org/tpo/core/arti/-/blob/${src.rev}/CHANGELOG.md";
license = with licenses; [ asl20 /* or */ mit ];
maintainers = [ ];
license = with lib.licenses; [
asl20
mit
];
maintainers = with lib.maintainers; [ rapiteanu ];
};
}
4 changes: 0 additions & 4 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -293,10 +293,6 @@ with pkgs;

ares-rs = callPackage ../tools/security/ares-rs { };

arti = callPackage ../tools/security/arti {
inherit (darwin.apple_sdk.frameworks) CoreServices;
};

asn1c = callPackage ../development/compilers/asn1c { };

authz0 = callPackage ../tools/security/authz0 { };
Expand Down

0 comments on commit 61e26f8

Please sign in to comment.