forked from mirrors/nixpkgs
72d161f548
* ppc64le enablement * gcc, glibc: properly handle __float128 * lib/systems, stdenv: syntax cleanup * gcc7: remove ugly hack * gcc: add/update __float128 flags * stdenv: add another pair of quotes for consistency * gcc: move __float128 flag for ppc64le-glibc into common/platform-flags.nix
17 lines
582 B
Nix
17 lines
582 B
Nix
{ lib, targetPlatform }:
|
|
|
|
let
|
|
p = targetPlatform.platform.gcc or {}
|
|
// targetPlatform.parsed.abi;
|
|
in lib.concatLists [
|
|
(lib.optional (p ? arch) "--with-arch=${p.arch}")
|
|
(lib.optional (p ? cpu) "--with-cpu=${p.cpu}")
|
|
(lib.optional (p ? abi) "--with-abi=${p.abi}")
|
|
(lib.optional (p ? fpu) "--with-fpu=${p.fpu}")
|
|
(lib.optional (p ? float) "--with-float=${p.float}")
|
|
(lib.optional (p ? mode) "--with-mode=${p.mode}")
|
|
(lib.optional
|
|
(let tp = targetPlatform; in tp.isPower && tp.libc == "glibc" && tp.is64bit && tp.isLittleEndian)
|
|
"--with-long-double-128")
|
|
]
|