summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--rts/Linker.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/rts/Linker.c b/rts/Linker.c
index 483c76431e..307ca73f62 100644
--- a/rts/Linker.c
+++ b/rts/Linker.c
@@ -1923,19 +1923,23 @@ addSection (Section *s, SectionKind kind, SectionAlloc alloc,
#define UNUSED(x) (void)(x)
+#if defined(OBJFORMAT_ELF)
void * loadNativeObj (pathchar *path, char **errmsg)
{
-#if defined(OBJFORMAT_ELF)
ACQUIRE_LOCK(&linker_mutex);
void *r = loadNativeObj_ELF(path, errmsg);
RELEASE_LOCK(&linker_mutex);
return r;
+}
#else
+void * GNU_ATTRIBUTE(__noreturn__)
+loadNativeObj (pathchar *path, char **errmsg)
+{
UNUSED(path);
UNUSED(errmsg);
barf("loadNativeObj: not implemented on this platform");
-#endif
}
+#endif
HsInt unloadNativeObj (void *handle)
{