Opened 7 years ago

Last modified 8 weeks ago

#5291 new bug

GhcDynamic build fails on Windows: can't find DLLs

Reported by: batterseapower Owned by:
Priority: low Milestone:
Component: Build System (make) Version: 7.0.3
Keywords: Cc:
Operating System: Windows Architecture: Unknown/Multiple
Type of failure: Building GHC failed Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


Enabling GhcDynamic causes the Windows build to fail:

"inplace/bin/ghc-stage2.exe"   -H64m -O0 -fasm     -i -iutils/ghctags/. -iutils/ghctags/dist-install/build -iutils/ghctags/dist-install/build/autogen -Iutils/ghctags/dist-install/build -Iutils/ghctags/dist-install/build/autogen        -package ghc -no-user-package-conf -rtsopts     -odir utils/ghctags/dist-install/build -hidir utils/ghctags/dist-install/build -stubdir utils/ghctags/dist-install/build -hisuf hi -osuf  o -hcsuf hc -c utils/ghctags/./Main.hs -o utils/ghctags/dist-install/build/Main.o
/home/Max/Programming/Checkouts/ghc.shared/inplace/bin/ghc-stage2.exe: error while loading shared libraries: libHSprocess- cannot open shared object file: No such file or directory

The reason is that Windows searches for DLLs in the application directory, and the DLLs that a dynamic GHC depends on are not placed in that directory. (See

Presumably the fix is to have the build system copy the dependent DLLs into inplace/bin as the final act of the stage2 build. (I'm not sure what happens after GHC is installed - presumably the DLLs are put into System32 or something?)

Change History (11)

comment:1 Changed 7 years ago by guest

Concerning after GHC is installed: DLLs should never go into System32, it's considered pollution/bad practice. DLLs shipped with GHC should be under the GHC install directory if they belong to GHC.

comment:2 Changed 7 years ago by igloo

Milestone: 7.4.1

comment:3 Changed 7 years ago by igloo

Priority: normallow

comment:4 Changed 6 years ago by igloo


comment:5 Changed 4 years ago by thoughtpolice


Moving to 7.10.1.

comment:6 Changed 4 years ago by thoughtpolice


Moving to 7.12.1 milestone; if you feel this is an error and should be addressed sooner, please move it back to the 7.10.1 milestone.

comment:7 Changed 3 years ago by thoughtpolice


Milestone renamed

comment:8 Changed 3 years ago by thomie

Milestone: 8.0.1

comment:9 Changed 2 years ago by Phyx-

Milestone: 8.4.1

comment:10 Changed 11 months ago by bgamari

Milestone: 8.4.1

These tasks won't happen for 8.4 and have been sitting at low priority for quite some time. Consequently I am un-milestoning them. Don't let this stop you, the interested reader, from picking one up, however.

comment:11 Changed 8 weeks ago by bgamari

Component: Build SystemBuild System (make)

The new Hadrian build system has been merged. Relabeling the tickets concerning the legacy make build system to prevent confusion.

Note: See TracTickets for help on using tickets.