summaryrefslogtreecommitdiff
path: root/rts/linker/LoadArchive.c
diff options
context:
space:
mode:
Diffstat (limited to 'rts/linker/LoadArchive.c')
-rw-r--r--rts/linker/LoadArchive.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/rts/linker/LoadArchive.c b/rts/linker/LoadArchive.c
index 3c4bd44a28..8c32585681 100644
--- a/rts/linker/LoadArchive.c
+++ b/rts/linker/LoadArchive.c
@@ -22,6 +22,7 @@
#include <string.h>
#include <stddef.h>
#include <ctype.h>
+#include <fs_rts.h>
#define FAIL(...) do {\
errorBelch("loadArchive: "__VA_ARGS__); \
@@ -260,7 +261,7 @@ static HsInt loadArchive_ (pathchar *path)
int misalignment = 0;
DEBUG_LOG("start\n");
- DEBUG_LOG("Loading archive `%" PATH_FMT" '\n", path);
+ DEBUG_LOG("Loading archive `%" PATH_FMT "'\n", path);
/* Check that we haven't already loaded this archive.
Ignore requests to load multiple times */
@@ -489,12 +490,7 @@ static HsInt loadArchive_ (pathchar *path)
DEBUG_LOG("Member is an object file...loading...\n");
-#if defined(mingw32_HOST_OS)
- // TODO: We would like to use allocateExec here, but allocateExec
- // cannot currently allocate blocks large enough.
- image = allocateImageAndTrampolines(path, fileName, f, memberSize,
- isThin);
-#elif defined(darwin_HOST_OS) || defined(ios_HOST_OS)
+#if defined(darwin_HOST_OS) || defined(ios_HOST_OS)
if (RTS_LINKER_USE_MMAP)
image = mmapForLinker(memberSize, MAP_ANONYMOUS, -1, 0);
else {
@@ -505,7 +501,7 @@ static HsInt loadArchive_ (pathchar *path)
image += misalignment;
}
-#else // not windows or darwin
+#else // not darwin
image = stgMallocBytes(memberSize, "loadArchive(image)");
#endif
if (isThin) {