diff --git a/nix/default-arm64.nix b/nix/default-arm64.nix index fc6cdd6f..1b19cb94 100644 --- a/nix/default-arm64.nix +++ b/nix/default-arm64.nix @@ -3,25 +3,12 @@ let crossSystem = { config = "aarch64-unknown-linux-gnu"; }; - overlays = [ - (final: pkg: { - pcre = (static pkg.pcre).overrideAttrs (x: { - configureFlags = x.configureFlags ++ [ - "--enable-static" - ]; - }); - }) - ]; config = { packageOverrides = pkg: { - autogen = (static pkg.autogen); - e2fsprogs = (static pkg.e2fsprogs); - gnupg = (static pkg.gnupg); gpgme = (static pkg.gpgme); libassuan = (static pkg.libassuan); libgpgerror = (static pkg.libgpgerror); libseccomp = (static pkg.libseccomp); - libuv = (static pkg.libuv); glib = (static pkg.glib).overrideAttrs (x: { outputs = [ "bin" "out" "dev" ]; mesonFlags = [ @@ -38,18 +25,18 @@ let -i "$dev"/include/glib-2.0/gobject/gobjectnotifyqueue.c ''; }); - gnutls = (static pkg.gnutls).overrideAttrs (x: { - configureFlags = (x.configureFlags or [ ]) ++ [ - "--disable-non-suiteb-curves" - "--disable-openssl-compatibility" - "--disable-rpath" - "--enable-local-libopts" - "--without-p11-kit" + pcsclite = (static pkg.pcsclite).overrideAttrs (x: { + configureFlags = [ + "--enable-confdir=/etc" + "--enable-usbdropdir=/var/lib/pcsc/drivers" + "--disable-libsystemd" ]; + buildInputs = [ pkgs.python3 pkgs.udev pkgs.dbus pkgs.systemd ]; }); systemd = (static pkg.systemd).overrideAttrs (x: { outputs = [ "out" "dev" ]; mesonFlags = x.mesonFlags ++ [ + "-Dglib=false" "-Dstatic-libsystemd=true" ]; }); @@ -75,7 +62,7 @@ let doCheck = false; enableParallelBuilding = true; outputs = [ "out" ]; - nativeBuildInputs = [ bash go-md2man installShellFiles makeWrapper pcre pkg-config which ]; + nativeBuildInputs = [ bash gitMinimal go-md2man pkg-config which ]; buildInputs = [ glibc glibc.static glib gpgme libassuan libgpgerror libseccomp ]; prePatch = '' export CFLAGS='-static -pthread' diff --git a/nix/default.nix b/nix/default.nix index 5dc711ef..e7aaa040 100644 --- a/nix/default.nix +++ b/nix/default.nix @@ -1,25 +1,12 @@ { system ? builtins.currentSystem }: let pkgs = (import ./nixpkgs.nix { - overlays = [ - (final: pkg: { - pcre = (static pkg.pcre).overrideAttrs (x: { - configureFlags = x.configureFlags ++ [ - "--enable-static" - ]; - }); - }) - ]; config = { packageOverrides = pkg: { - autogen = (static pkg.autogen); - e2fsprogs = (static pkg.e2fsprogs); - gnupg = (static pkg.gnupg); gpgme = (static pkg.gpgme); libassuan = (static pkg.libassuan); libgpgerror = (static pkg.libgpgerror); libseccomp = (static pkg.libseccomp); - libuv = (static pkg.libuv); glib = (static pkg.glib).overrideAttrs (x: { outputs = [ "bin" "out" "dev" ]; mesonFlags = [ @@ -36,18 +23,18 @@ let -i "$dev"/include/glib-2.0/gobject/gobjectnotifyqueue.c ''; }); - gnutls = (static pkg.gnutls).overrideAttrs (x: { - configureFlags = (x.configureFlags or [ ]) ++ [ - "--disable-non-suiteb-curves" - "--disable-openssl-compatibility" - "--disable-rpath" - "--enable-local-libopts" - "--without-p11-kit" + pcsclite = (static pkg.pcsclite).overrideAttrs (x: { + configureFlags = [ + "--enable-confdir=/etc" + "--enable-usbdropdir=/var/lib/pcsc/drivers" + "--with-systemdsystemunitdir=${placeholder "bin"}/lib/systemd/system" ]; + buildInputs = [ pkgs.python3 pkgs.udev pkgs.dbus pkgs.systemd ]; }); systemd = (static pkg.systemd).overrideAttrs (x: { outputs = [ "out" "dev" ]; mesonFlags = x.mesonFlags ++ [ + "-Dglib=false" "-Dstatic-libsystemd=true" ]; }); @@ -73,7 +60,7 @@ let doCheck = false; enableParallelBuilding = true; outputs = [ "out" ]; - nativeBuildInputs = [ bash go-md2man installShellFiles makeWrapper pcre pkg-config which ]; + nativeBuildInputs = [ bash gitMinimal go-md2man pkg-config which ]; buildInputs = [ glibc glibc.static glib gpgme libassuan libgpgerror libseccomp ]; prePatch = '' export CFLAGS='-static -pthread' diff --git a/nix/nixpkgs.json b/nix/nixpkgs.json index 799ea6f5..a9771ead 100644 --- a/nix/nixpkgs.json +++ b/nix/nixpkgs.json @@ -1,9 +1,9 @@ { "url": "https://github.com/nixos/nixpkgs", - "rev": "eaba7870ffc3400eca4407baa24184b7fe337ec1", - "date": "2021-06-02T10:22:59+02:00", - "path": "/nix/store/lcr7kwnx934b1z6wmb1zlqjycdlbaw9x-nixpkgs", - "sha256": "115disiz4b08iw46cidc7lm0advrxn5g2ldmlrxd53zf03skyb2w", + "rev": "60cce7e5e1fdf62421ef6d4184ee399b46209366", + "date": "2021-06-09T01:18:50-04:00", + "path": "/nix/store/fixgn194626rb7gf99l9jaqm0hbqn2ix-nixpkgs", + "sha256": "100xrb925cana1kfd0c7gwkjjalq891vfgr0rn1gl9j8gp3l3gx6", "fetchSubmodules": false, "deepClone": false, "leaveDotGit": false diff --git a/nix/nixpkgs.nix b/nix/nixpkgs.nix index 21e7f17a..11c20380 100644 --- a/nix/nixpkgs.nix +++ b/nix/nixpkgs.nix @@ -5,4 +5,5 @@ let url = "${json.url}/archive/${json.rev}.tar.gz"; inherit (json) sha256; }); -in nixpkgs +in +nixpkgs