From 1009efb436c36100bfcc5ad9597b106198fb6764 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Isma=C3=ABl=20Bouya?= Date: Mon, 30 Aug 2021 23:14:00 +0200 Subject: [PATCH] Remove libspf2 flake for stock one --- flakes/libspf2/default.nix | 34 ------------------- flakes/libspf2/flake.lock | 42 ------------------------ flakes/libspf2/flake.nix | 28 ---------------- flakes/opendmarc/flake.lock | 39 ---------------------- flakes/opendmarc/flake.nix | 10 ++---- flakes/private/opendmarc/flake.lock | 51 +++-------------------------- flakes/private/opendmarc/flake.nix | 5 +-- overlays/default.nix | 1 - 8 files changed, 7 insertions(+), 203 deletions(-) delete mode 100644 flakes/libspf2/default.nix delete mode 100644 flakes/libspf2/flake.lock delete mode 100644 flakes/libspf2/flake.nix diff --git a/flakes/libspf2/default.nix b/flakes/libspf2/default.nix deleted file mode 100644 index d22c738..0000000 --- a/flakes/libspf2/default.nix +++ /dev/null @@ -1,34 +0,0 @@ -{ fetchpatch, file, fetchurl, libnsl, stdenv, lib }: -stdenv.mkDerivation rec { - pname = "libspf2"; - version = "1.2.10"; - - patches = [ - (fetchpatch { - name = "fix-variadic-macros.patch"; - url = "https://github.com/shevek/libspf2/commit/5852828582f556e73751076ad092f72acf7fc8b6.patch"; - sha256 = "00dqpcgjr9jy2qprgqv2qiyvq8y3wlz4yns9xzabf2064jzqh2ic"; - }) - ]; - preConfigure = '' - sed -i -e "s@/usr/bin/file@${file}/bin/file@" ./configure - ''; - configureFlags = [ - "--enable-static" - ]; - postInstall = '' - rm $out/bin/*_static - ''; - src = fetchurl { - url = "https://www.libspf2.org/spf/${pname}-${version}.tar.gz"; - sha256 = "1j91p0qiipzf89qxq4m1wqhdf01hpn1h5xj4djbs51z23bl3s7nr"; - }; - - buildInputs = [ libnsl ]; - - meta = { - description = "Sender Policy Framework record checking library"; - homepage = "https://www.libspf2.org/"; - platforms = lib.platforms.linux; - }; -} diff --git a/flakes/libspf2/flake.lock b/flakes/libspf2/flake.lock deleted file mode 100644 index a278bc0..0000000 --- a/flakes/libspf2/flake.lock +++ /dev/null @@ -1,42 +0,0 @@ -{ - "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1609246779, - "narHash": "sha256-eq6ZXE/VWo3EMC65jmIT6H/rrUc9UWOWVujkzav025k=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "08c7ad4a0844adc4a7f9f5bb3beae482e789afa4", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "nixpkgs": { - "locked": { - "lastModified": 1597943282, - "narHash": "sha256-G/VQBlqO7YeFOSvn29RqdvABZxmQBtiRYVA6kjqWZ6o=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "c59ea8b8a0e7f927e7291c14ea6cd1bd3a16ff38", - "type": "github" - }, - "original": { - "owner": "NixOS", - "repo": "nixpkgs", - "type": "github" - } - }, - "root": { - "inputs": { - "flake-utils": "flake-utils", - "nixpkgs": "nixpkgs" - } - } - }, - "root": "root", - "version": 7 -} diff --git a/flakes/libspf2/flake.nix b/flakes/libspf2/flake.nix deleted file mode 100644 index af1deea..0000000 --- a/flakes/libspf2/flake.nix +++ /dev/null @@ -1,28 +0,0 @@ -{ - description = "Sender Policy Framework record checking library"; - - inputs.flake-utils.url = "github:numtide/flake-utils"; - inputs.nixpkgs.url = "github:NixOS/nixpkgs"; - - outputs = { self, flake-utils, nixpkgs }: flake-utils.lib.eachSystem ["aarch64-linux" "i686-linux" "x86_64-linux"] (system: - let - pkgs = import nixpkgs { inherit system; overlays = []; }; - libspf2 = pkgs.callPackage ./. {}; - in rec { - packages.libspf2 = libspf2; - defaultPackage = libspf2; - legacyPackages.libfspf2 = libspf2; - apps.libspf2 = flake-utils.lib.mkApp { drv = libspf2; name = "spfquery"; }; - defaultApp = apps.libspf2; - checks.build = libspf2; - hydraJobs.build = libspf2; - } - ) // rec { - overlays = { - libspf2 = final: prev: { - libspf2 = self.defaultPackage."${final.system}"; - }; - }; - overlay = overlays.libspf2; - }; -} diff --git a/flakes/opendmarc/flake.lock b/flakes/opendmarc/flake.lock index 92551af..4503c79 100644 --- a/flakes/opendmarc/flake.lock +++ b/flakes/opendmarc/flake.lock @@ -15,44 +15,6 @@ "type": "github" } }, - "flake-utils_2": { - "locked": { - "lastModified": 1609246779, - "narHash": "sha256-eq6ZXE/VWo3EMC65jmIT6H/rrUc9UWOWVujkzav025k=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "08c7ad4a0844adc4a7f9f5bb3beae482e789afa4", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "libspf2": { - "inputs": { - "flake-utils": "flake-utils_2", - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "dir": "flakes/libspf2", - "lastModified": 1629758991, - "narHash": "sha256-J0mMj/lPMR+QaqvAzUpOUWELYoyKCpI20T4YZHerAEs=", - "ref": "master", - "rev": "5e2ec9fb8628136e7f9f618c68c0e42ab086b80e", - "revCount": 866, - "type": "git", - "url": "https://git.immae.eu/perso/Immae/Config/Nix.git" - }, - "original": { - "dir": "flakes/libspf2", - "type": "git", - "url": "https://git.immae.eu/perso/Immae/Config/Nix.git" - } - }, "myuids": { "locked": { "dir": "flakes/myuids", @@ -88,7 +50,6 @@ "root": { "inputs": { "flake-utils": "flake-utils", - "libspf2": "libspf2", "myuids": "myuids", "nixpkgs": "nixpkgs" } diff --git a/flakes/opendmarc/flake.nix b/flakes/opendmarc/flake.nix index 469cf74..f1877b6 100644 --- a/flakes/opendmarc/flake.nix +++ b/flakes/opendmarc/flake.nix @@ -6,18 +6,12 @@ type = "git"; dir = "flakes/myuids"; }; - inputs.libspf2 = { - url = "https://git.immae.eu/perso/Immae/Config/Nix.git"; - type = "git"; - dir = "flakes/libspf2"; - inputs.nixpkgs.follows = "nixpkgs"; - }; inputs.flake-utils.url = "github:numtide/flake-utils"; inputs.nixpkgs.url = "github:NixOS/nixpkgs"; - outputs = { self, myuids, libspf2, flake-utils, nixpkgs }: flake-utils.lib.eachSystem ["aarch64-linux" "i686-linux" "x86_64-linux"] (system: + outputs = { self, myuids, flake-utils, nixpkgs }: flake-utils.lib.eachSystem ["aarch64-linux" "i686-linux" "x86_64-linux"] (system: let - pkgs = import nixpkgs { inherit system; overlays = [ libspf2.overlay ]; }; + pkgs = import nixpkgs { inherit system; overlays = []; }; in rec { packages.opendmarc = pkgs.callPackage ./. {}; defaultPackage = packages.opendmarc; diff --git a/flakes/private/opendmarc/flake.lock b/flakes/private/opendmarc/flake.lock index 24df937..33e00a4 100644 --- a/flakes/private/opendmarc/flake.lock +++ b/flakes/private/opendmarc/flake.lock @@ -15,44 +15,6 @@ "type": "github" } }, - "flake-utils_2": { - "locked": { - "lastModified": 1609246779, - "narHash": "sha256-eq6ZXE/VWo3EMC65jmIT6H/rrUc9UWOWVujkzav025k=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "08c7ad4a0844adc4a7f9f5bb3beae482e789afa4", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "libspf2": { - "inputs": { - "flake-utils": "flake-utils_2", - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "dir": "flakes/libspf2", - "lastModified": 1629758991, - "narHash": "sha256-J0mMj/lPMR+QaqvAzUpOUWELYoyKCpI20T4YZHerAEs=", - "ref": "master", - "rev": "5e2ec9fb8628136e7f9f618c68c0e42ab086b80e", - "revCount": 866, - "type": "git", - "url": "https://git.immae.eu/perso/Immae/Config/Nix.git" - }, - "original": { - "dir": "flakes/libspf2", - "type": "git", - "url": "https://git.immae.eu/perso/Immae/Config/Nix.git" - } - }, "myuids": { "locked": { "dir": "flakes/myuids", @@ -72,11 +34,11 @@ }, "nix-lib": { "locked": { - "lastModified": 1629674054, - "narHash": "sha256-Vl4SmTN1Cwz9T8Te85Bkq11e9VPl4JRNO+Rzmxxop+c=", + "lastModified": 1630358951, + "narHash": "sha256-y6jh6YDWX6fX88tS9bSFOVSnckCL4qgt7UqUJhLPSx8=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "f118101266328f38241e266d30316cd3c50e43da", + "rev": "2d786792ca69c98a8655858464e53698ad7311e2", "type": "github" }, "original": { @@ -103,12 +65,11 @@ "opendmarc": { "inputs": { "flake-utils": "flake-utils", - "libspf2": "libspf2", "myuids": "myuids", "nixpkgs": "nixpkgs" }, "locked": { - "narHash": "sha256-co+AfUh+3SMGGFTQy5u8470UHXbLiPeAlDWRCdoNdFc=", + "narHash": "sha256-eIe5hzNsp1zz5m4ZMzORwdHuLkhEsKkS7WMpPOJE4ok=", "path": "../../opendmarc", "type": "path" }, @@ -120,10 +81,6 @@ "root": { "inputs": { "nix-lib": "nix-lib", - "nixpkgs": [ - "opendmarc", - "nixpkgs" - ], "opendmarc": "opendmarc" } } diff --git a/flakes/private/opendmarc/flake.nix b/flakes/private/opendmarc/flake.nix index 3d500a2..ae96c30 100644 --- a/flakes/private/opendmarc/flake.nix +++ b/flakes/private/opendmarc/flake.nix @@ -5,11 +5,8 @@ }; inputs.nix-lib.url = "github:NixOS/nixpkgs"; - # Necessary for dependencies - inputs.nixpkgs.follows = "opendmarc/nixpkgs"; - description = "Private configuration for opendmarc"; - outputs = { self, nix-lib, opendmarc, nixpkgs }: + outputs = { self, nix-lib, opendmarc }: let cfg = name': { config, lib, pkgs, name, ... }: lib.mkIf (name == name') { users.users."${config.services.opendmarc.user}".extraGroups = [ "keys" ]; diff --git a/overlays/default.nix b/overlays/default.nix index b01dd81..1f1528c 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -2,7 +2,6 @@ let flakeCompat = import ../lib/flake-compat.nix; flakes = builtins.foldl' (a: b: a // b) {} (map (n: (flakeCompat n).overlays) [ ../flakes/backports - ../flakes/libspf2 ../flakes/openarc ../flakes/opendmarc ../flakes/peertube -- 2.41.0