diff options
author | Ben Siraphob <bensiraphob@gmail.com> | 2021-01-22 18:25:31 +0700 |
---|---|---|
committer | Ben Siraphob <bensiraphob@gmail.com> | 2021-01-23 08:57:37 +0700 |
commit | acc5f7b18a60bc9b1024e5e1882bf7362e6492e6 (patch) | |
tree | 597dab74ebab3915ddff291ec6aa4913f4010c68 /pkgs/development/compilers/ldc | |
parent | bbaff89ceb389e9c21a90eefac60ebc9853144be (diff) |
pkgs/development/compilers: stdenv.lib -> lib
Diffstat (limited to 'pkgs/development/compilers/ldc')
-rw-r--r-- | pkgs/development/compilers/ldc/generic.nix | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/pkgs/development/compilers/ldc/generic.nix b/pkgs/development/compilers/ldc/generic.nix index 19dc140a7e172..4261c2b653341 100644 --- a/pkgs/development/compilers/ldc/generic.nix +++ b/pkgs/development/compilers/ldc/generic.nix @@ -1,5 +1,5 @@ { version, ldcSha256 }: -{ stdenv, fetchurl, cmake, ninja, llvm_11, curl, tzdata +{ lib, stdenv, fetchurl, cmake, ninja, llvm_11, curl, tzdata , libconfig, lit, gdb, unzip, darwin, bash , callPackage, makeWrapper, runCommand, targetPackages , ldcBootstrap ? callPackage ./bootstrap.nix { } @@ -37,7 +37,7 @@ stdenv.mkDerivation rec { # test depends on current year rm ldc-${version}-src/tests/d2/dmd-testsuite/compilable/ddocYear.d '' - + stdenv.lib.optionalString stdenv.hostPlatform.isDarwin '' + + lib.optionalString stdenv.hostPlatform.isDarwin '' # https://github.com/NixOS/nixpkgs/issues/34817 rm -r ldc-${version}-src/tests/plugins/addFuncEntryCall ''; @@ -46,20 +46,20 @@ stdenv.mkDerivation rec { # Setting SHELL=$SHELL when dmd testsuite is run doesn't work on Linux somehow substituteInPlace tests/d2/dmd-testsuite/Makefile --replace "SHELL=/bin/bash" "SHELL=${bash}/bin/bash" '' - + stdenv.lib.optionalString stdenv.hostPlatform.isLinux '' + + lib.optionalString stdenv.hostPlatform.isLinux '' substituteInPlace runtime/phobos/std/socket.d --replace "assert(ih.addrList[0] == 0x7F_00_00_01);" "" '' - + stdenv.lib.optionalString stdenv.hostPlatform.isDarwin '' + + lib.optionalString stdenv.hostPlatform.isDarwin '' substituteInPlace runtime/phobos/std/socket.d --replace "foreach (name; names)" "names = []; foreach (name; names)" ''; nativeBuildInputs = [ cmake ldcBootstrap lit lit.python llvm_11 makeWrapper ninja unzip ] - ++ stdenv.lib.optionals stdenv.hostPlatform.isDarwin [ + ++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.Foundation ] - ++ stdenv.lib.optionals (!stdenv.hostPlatform.isDarwin) [ + ++ lib.optionals (!stdenv.hostPlatform.isDarwin) [ # https://github.com/NixOS/nixpkgs/pull/36378#issuecomment-385034818 gdb ]; @@ -77,7 +77,7 @@ stdenv.mkDerivation rec { makeFlags = [ "DMD=$DMD" ]; - fixNames = stdenv.lib.optionalString stdenv.hostPlatform.isDarwin '' + fixNames = lib.optionalString stdenv.hostPlatform.isDarwin '' fixDarwinDylibNames() { local flags=() @@ -97,7 +97,7 @@ stdenv.mkDerivation rec { ''; # https://github.com/ldc-developers/ldc/issues/2497#issuecomment-459633746 - additionalExceptions = stdenv.lib.optionalString stdenv.hostPlatform.isDarwin + additionalExceptions = lib.optionalString stdenv.hostPlatform.isDarwin "|druntime-test-shared"; checkPhase = '' @@ -126,7 +126,7 @@ stdenv.mkDerivation rec { --set-default CC "${targetPackages.stdenv.cc}/bin/cc" ''; - meta = with stdenv.lib; { + meta = with lib; { description = "The LLVM-based D compiler"; homepage = "https://github.com/ldc-developers/ldc"; # from https://github.com/ldc-developers/ldc/blob/master/LICENSE |