You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Windows: stack exec foo works, foo.exe does not #425
Most likely Windows is not able to find the necessary C++ libraries from the standard prompt because they're not on your PATH. stack exec works because it's modifying the PATH to include extra things. Options here would be:
Copy the relevant .dll files to something on your PATH
Modify your PATH to include extra directories
In theory, stack could copy some DLLs over to the output directory for you, but that seems out-of-scope for what it's doing.
Actually, they're not, they're shipped with GHC (and, theoretically in some cases, MSYS). The easiest way to find them is stack exec which. On my system, for instance:
>stack exec which libstdc++-6.dll
/c/Users/Michael/AppData/Local/Programs/stack/i386-windows/ghc-7.8.4/mingw/bin/libstdc++-6.dll
Activity
snoyberg commentedon Jun 26, 2015
Most likely Windows is not able to find the necessary C++ libraries from the standard prompt because they're not on your PATH.
stack execworks because it's modifying the PATH to include extra things. Options here would be:In theory, stack could copy some DLLs over to the output directory for you, but that seems out-of-scope for what it's doing.
rubenmoor commentedon Jun 26, 2015
Cool, thanks. I assume these libraries are created by stack during
stack build. Where are they stored, i.e. what directories to include in my PATH?snoyberg commentedon Jun 26, 2015
Actually, they're not, they're shipped with GHC (and, theoretically in some cases, MSYS). The easiest way to find them is
stack exec which. On my system, for instance:snoyberg commentedon Jun 26, 2015
If that turns out to resolve it for you, would you be able to add a FAQ entry on the Wiki about this?
radix commentedon Jun 26, 2015
perhaps an idea for a future plugin: bundle up a self-contained windows executable or installer?
snoyberg commentedon Jun 26, 2015
Sounds like what we're doing with docker. Mind opening as a separate issue?
I don't want to lose track of it.
On Fri, Jun 26, 2015, 6:28 PM Christopher Armstrong <
notifications@github.com> wrote:
rubenmoor commentedon Jun 28, 2015
Done
snoyberg commentedon Jun 28, 2015
Thanks!