diff --git a/nixos/modules/services/computing/boinc/client.nix b/nixos/modules/services/computing/boinc/client.nix index 1879fef9666f..51475171bf3f 100644 --- a/nixos/modules/services/computing/boinc/client.nix +++ b/nixos/modules/services/computing/boinc/client.nix @@ -31,6 +31,7 @@ in type = types.package; default = pkgs.boinc; defaultText = literalExpression "pkgs.boinc"; + example = literalExpression "pkgs.boinc-headless"; description = lib.mdDoc '' Which BOINC package to use. ''; diff --git a/pkgs/applications/science/misc/boinc/default.nix b/pkgs/applications/science/misc/boinc/default.nix index 625de3a3a8b3..f806be834bca 100644 --- a/pkgs/applications/science/misc/boinc/default.nix +++ b/pkgs/applications/science/misc/boinc/default.nix @@ -22,6 +22,7 @@ , libnotify , libX11 , libxcb +, headless ? false }: stdenv.mkDerivation rec { @@ -40,6 +41,9 @@ stdenv.mkDerivation rec { buildInputs = [ curl + sqlite + patchelf + ] ++ lib.optionals (!headless) [ libGLU libGL libXmu @@ -47,17 +51,15 @@ stdenv.mkDerivation rec { freeglut libjpeg wxGTK32 - sqlite gtk3 libXScrnSaver libnotify - patchelf libX11 libxcb xcbutil ]; - NIX_LDFLAGS = "-lX11"; + NIX_LDFLAGS = lib.optionalString (!headless) "-lX11"; preConfigure = '' ./_autosetup @@ -66,7 +68,7 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; - configureFlags = [ "--disable-server" ]; + configureFlags = [ "--disable-server" ] ++ lib.optionals headless [ "--disable-manager" ]; postInstall = '' install --mode=444 -D 'client/scripts/boinc-client.service' "$out/etc/systemd/system/boinc.service" diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 2fb56fc4fde8..29b9e859b92b 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -39410,6 +39410,8 @@ with pkgs; boinc = callPackage ../applications/science/misc/boinc { }; + boinc-headless = callPackage ../applications/science/misc/boinc { headless = true; }; + celestia = callPackage ../applications/science/astronomy/celestia { autoreconfHook = buildPackages.autoreconfHook269; inherit (gnome2) gtkglext;