Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dash: add libedit support, enable parallel building #118491

Merged
merged 3 commits into from Apr 4, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 11 additions & 3 deletions pkgs/shells/dash/default.nix
@@ -1,4 +1,4 @@
{ lib, stdenv, buildPackages, autoreconfHook, fetchurl }:
{ lib, stdenv, buildPackages, autoreconfHook, fetchurl, libedit }:

stdenv.mkDerivation rec {
pname = "dash";
Expand All @@ -11,17 +11,25 @@ stdenv.mkDerivation rec {

hardeningDisable = [ "format" ];

# Temporary fix until a proper one is accepted upstream
patches = [
(fetchurl {
# Dash executes code when noexec ("-n") is specified
# https://www.openwall.com/lists/oss-security/2020/11/11/3
url = "https://git.kernel.org/pub/scm/utils/dash/dash.git/patch/?id=29d6f2148f10213de4e904d515e792d2cf8c968e";
sha256 = "08q90bx36ixwlcj331dh7420qyj8i0qh1cc1gljrhd83fhl9w0y5";
})
] ++ lib.optional stdenv.isDarwin ./0001-fix-dirent64-et-al-on-darwin.patch;
] ++ lib.optionals stdenv.isDarwin [
# Temporary fix until a proper one is accepted upstream
./0001-fix-dirent64-et-al-on-darwin.patch
];

depsBuildBuild = [ buildPackages.stdenv.cc ];
nativeBuildInputs = lib.optional stdenv.isDarwin autoreconfHook;
buildInputs = [ libedit ];

configureFlags = [ "--with-libedit" ];

enableParallelBuilding = true;

meta = with lib; {
homepage = "http://gondor.apana.org.au/~herbert/dash/";
Expand Down