mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-20 15:41:16 +00:00
ghc: fix c++ linkage and c standard for < 9.10 on darwin
This commit is contained in:
@@ -696,6 +696,11 @@ stdenv.mkDerivation (
|
||||
configureFlags = [
|
||||
"--datadir=$doc/share/doc/ghc"
|
||||
]
|
||||
# ghc 9.10 and later use c17 by default. we use gnu17 on darwin for older
|
||||
# ghc versions to match this and fix build issues with newer clang.
|
||||
++ lib.optionals (hostPlatform.isDarwin && lib.versionOlder version "9.10") [
|
||||
"CFLAGS=-std=gnu17"
|
||||
]
|
||||
++ lib.optionals enableTerminfo [
|
||||
"--with-curses-includes=${lib.getDev targetLibs.ncurses}/include"
|
||||
"--with-curses-libraries=${lib.getLib targetLibs.ncurses}/lib"
|
||||
|
||||
@@ -501,6 +501,11 @@ stdenv.mkDerivation (
|
||||
configureFlags = [
|
||||
"--datadir=$doc/share/doc/ghc"
|
||||
]
|
||||
# ghc 9.10 and later use c17 by default. we use gnu17 on darwin for older
|
||||
# ghc versions to match this and fix build issues with newer clang.
|
||||
++ lib.optionals (hostPlatform.isDarwin && lib.versionOlder version "9.10") [
|
||||
"CFLAGS=-std=gnu17"
|
||||
]
|
||||
++ lib.optionals enableTerminfo [
|
||||
"--with-curses-includes=${lib.getDev targetLibs.ncurses}/include"
|
||||
"--with-curses-libraries=${lib.getLib targetLibs.ncurses}/lib"
|
||||
|
||||
Reference in New Issue
Block a user