libngspice: fix build on Darwin with Clang

Apply patch to remove redundant is_compound specialization in cppduals.
This resolves a compilation error on macOS where the specialization
conflicts with the standard library's type traits.
This commit is contained in:
Andreas Wendleder
2026-02-03 08:28:10 +01:00
parent b6804236c3
commit bd907828ad
+18
View File
@@ -21,6 +21,24 @@ stdenv.mkDerivation (finalAttrs: {
hash = "sha256-8arYq6woKKe3HaZkEd6OQGUk518wZuRnVUOcSQRC1zQ=";
};
patches = [
(builtins.toFile "fix-cppduals.patch" ''
--- a/src/include/cppduals/duals/dual
+++ b/src/include/cppduals/duals/dual
@@ -485,10 +485,6 @@ struct is_arithmetic<duals::dual<T>> : is_arithmetic<T> {};
#endif // CPPDUALS_ENABLE_IS_ARITHMETIC
-/// Duals are compound types.
-template <class T>
-struct is_compound<duals::dual<T>> : true_type {};
-
// Modification of std::numeric_limits<> per
// C++03 17.4.3.1/1, and C++11 18.3.2.3/1.
template <class T>
'')
];
nativeBuildInputs = [
flex
bison