Commit 4af1e76c authored by Austin Seipp's avatar Austin Seipp
Browse files

Add Windows to NoSharedLibsPlatformList

We're punting on full -dynamic and -dynamic-too support for Windows
right now, since it's still unstable. Also, ensure "Support dynamic-too"
in `ghc --info` is set to "NO" for Cabal.

See issues #7134, #8228, and #5987
Signed-off-by: default avatarAustin Seipp <>
parent 6494de1f
......@@ -3563,7 +3563,7 @@ compilerInfo dflags
("Support SMP", cGhcWithSMP),
("Tables next to code", cGhcEnableTablesNextToCode),
("RTS ways", cGhcRTSWays),
("Support dynamic-too", "YES"),
("Support dynamic-too", if isWindows then "NO" else "YES"),
("Support parallel --make", "YES"),
("Dynamic by default", if dYNAMIC_BY_DEFAULT dflags
then "YES" else "NO"),
......@@ -3574,6 +3574,8 @@ compilerInfo dflags
("LibDir", topDir dflags),
("Global Package DB", systemPackageConfig dflags)
isWindows = platformOS (targetPlatform dflags) == OSMinGW32
#include "../includes/dist-derivedconstants/header/GHCConstantsHaskellWrappers.hs"
......@@ -94,22 +94,11 @@ else
TargetElf = YES
# Currently, on Windows, we artificially limit the unfolding creation
# threshold to minimize the number of exported symbols on Windows
# platforms in the stage2 DLL. This avoids a hard limit of 2^16
# exported symbols in the windows dynamic linker.
# This is a pitifully low threshold (the default is 750,) but it
# reduced the symbol count by about ~7,000, bringing us back under the
# limit (for now.)
# See #5987
ifeq "$(TargetOS_CPP)" "mingw32"
GhcStage2HcOpts += -funfolding-creation-threshold=100
# Some platforms don't support shared libraries
NoSharedLibsPlatformList = arm-unknown-linux powerpc-unknown-linux
NoSharedLibsPlatformList = arm-unknown-linux \
powerpc-unknown-linux \
x86_64-unknown-mingw32 \
NoSharedLibsPlatformList += i386-unknown-solaris2
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment