| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Adds quick-cross-ncg flavour.
- Fix windows wchar with `_s` for mingw
- Lookup windres, dllwrap and objdump
- Fix type.
Reviewers: bgamari, hvr, Phyx, erikd, simonmar
Reviewed By: bgamari
Subscribers: rwbarton, thomie, erikd, carter
Differential Revision: https://phabricator.haskell.org/D4430
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This calls out to the Win32 API `GetTempFileName` to generate
a temporary file. Using `uUnique = 0` guarantees that the file
we get back is unique and the file is "reserved" by creating it.
Test Plan:
./validate
I can't think of any sensible tests that shouldn't run for a while
to verify. So the example in #10731 was ran for a while and no
collisions in new code
Reviewers: hvr, bgamari, erikd
Reviewed By: bgamari
Subscribers: RyanGlScott, rwbarton, thomie, carter
GHC Trac Issues: #10731
Differential Revision: https://phabricator.haskell.org/D4278
|
|
|
|
|
|
|
| |
Simplify some preprocessor expressions involving `_MSC_VER` because
`_WIN32` is always defined when `_MSC_VER` is.
Differential Revision: https://phabricator.haskell.org/D981
|
|
|
|
|
|
|
|
|
|
| |
In Haskell files, replace `__MINGW32__` by `mingw32_HOST_OS`.
In .c and .h files, delete `__MINGW32__` when `_WIN32` is also tested
because `_WIN32` is always defined when `__MINGW32__` is. Also replace
`__MINGW32__` by `_WIN32` when used standalone for consistency.
Differential Revision: https://phabricator.haskell.org/D971
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes the output of throwGetLastError to include the system error
message, rather than the message of our fictitious errno.
It also adds several definitions to GHC.Windows, mostly from the Win32 package.
The exceptions are:
* getErrorMessage: returns a String, unlike in System.Win32.Types,
where it returns an LPWSTR.
* errCodeToIOError: new
* c_maperrno_func: new
|
|
|
|
|
|
| |
Windows returns an EACCES error instead of EEXIST when a call to `open`
fails due to an existing directory, so add a special case for this
situation.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
WriteFile() returns ERROR_NO_DATA when writing to a pipe that is
"closing", however by default the write() wrapper in the CRT maps this
to EINVAL so we get confusing things like
hPutChar: invalid argument (Invalid Argumnet)
when piping the output of a Haskell program into something that closes
the pipe early. This was happening in the testsuite in a few place.
The solution is to map ERROR_NO_DATA to EPIPE correctly, as we
explicitly check for EPIPE on stdout (in GHC.TopHandler) so we can
exit without an error in this case.
|
| |
|
| |
|
| |
|
|
Fixes #637. The test program in that report now works for me with
-threaded, but it doesn't work without -threaded (I don't know if
that's new behaviour or not, though).
|