mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-03 10:44:18 +00:00
llvmPackages_{12,13,14,15,16,17,18,git}: Allow overriding dependencies
... consistently. Further to #307211, allow overriding arguments through llvmPackages.override. This makes it possible to override any dependency of LLVM or clang by overriding it on `llvmPackages.override { <dependency> = ...; }`. This is useful in development or customization where sometimes it is desirable to turn features on or off. Without this patch the only way to for example override ncurses was to do `overriddenLLVM = llvmPackages.llvm.override { ncurses }`, but then you would have to thread `overriddenLLVM` as dependencies into clang and other packages, which results in quite a difficult expression to write correctly in cross compilation scenarios. Signed-off-by: Peter Waller <p@pwaller.net>
This commit is contained in:
parent
683aa7c4e3
commit
40a7f218c5
@ -1,7 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, substitute, substituteAll, fetchFromGitHub, fetchpatch
|
||||
, libxml2, python3, isl, fetchurl, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub, fetchpatch, fetchurl
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -17,6 +17,10 @@
|
||||
then null
|
||||
else pkgs.bintools
|
||||
, darwin
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
let
|
||||
|
@ -1,7 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, fetchpatch
|
||||
, libxml2, python3, isl, fetchFromGitHub, substitute, substituteAll, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub, fetchpatch
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -40,7 +40,10 @@
|
||||
# to you to make sure that the LLVM repo given matches the release configuration
|
||||
# specified.
|
||||
, monorepoSrc ? null
|
||||
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
assert
|
||||
|
@ -1,6 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, libxml2, python3, fetchFromGitHub, substitute, substituteAll, fetchpatch, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub, fetchpatch
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -39,6 +40,10 @@
|
||||
# to you to make sure that the LLVM repo given matches the release configuration
|
||||
# specified.
|
||||
, monorepoSrc ? null
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
assert
|
||||
|
@ -1,6 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake, ninja
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, libxml2, python3, fetchFromGitHub, fetchpatch, substitute, substituteAll, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub, fetchpatch
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -39,6 +40,10 @@
|
||||
# to you to make sure that the LLVM repo given matches the release configuration
|
||||
# specified.
|
||||
, monorepoSrc ? null
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
assert
|
||||
|
@ -1,6 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake, ninja
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, libxml2, python3, fetchFromGitHub, substituteAll, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -39,6 +40,10 @@
|
||||
# to you to make sure that the LLVM repo given matches the release configuration
|
||||
# specified.
|
||||
, monorepoSrc ? null
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
assert
|
||||
|
@ -1,6 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake, ninja
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, libxml2, python3, fetchFromGitHub, fetchpatch, substituteAll, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub, fetchpatch
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -39,6 +40,10 @@
|
||||
# to you to make sure that the LLVM repo given matches the release configuration
|
||||
# specified.
|
||||
, monorepoSrc ? null
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
assert
|
||||
|
@ -1,6 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake, ninja
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, libxml2, python3, fetchFromGitHub, substituteAll, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -39,6 +40,10 @@
|
||||
# to you to make sure that the LLVM repo given matches the release configuration
|
||||
# specified.
|
||||
, monorepoSrc ? null
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
assert
|
||||
|
@ -1,6 +1,7 @@
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv, cmake, ninja
|
||||
{ lowPrio, newScope, pkgs, lib, stdenv
|
||||
, preLibcCrossHeaders
|
||||
, libxml2, python3, fetchFromGitHub, substituteAll, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, substitute, substituteAll, fetchFromGitHub, fetchpatch
|
||||
, overrideCC, wrapCCWith, wrapBintoolsWith
|
||||
, buildLlvmTools # tools, but from the previous stage, for cross
|
||||
, targetLlvmLibraries # libraries, but from the next stage, for cross
|
||||
, targetLlvm
|
||||
@ -44,6 +45,10 @@
|
||||
# to you to make sure that the LLVM repo given matches the release configuration
|
||||
# specified.
|
||||
, monorepoSrc ? null
|
||||
# Allows passthrough to packages via newScope. This makes it possible to
|
||||
# do `(llvmPackages.override { <someLlvmDependency> = bar; }).clang` and get
|
||||
# an llvmPackages whose packages are overridden in an internally consistent way.
|
||||
, ...
|
||||
}@args:
|
||||
|
||||
assert
|
||||
|
Loading…
Reference in New Issue
Block a user