20 lines
588 B
Diff
20 lines
588 B
Diff
|
diff --git a/rts/LinkerInternals.h b/rts/LinkerInternals.h
|
||
|
--- a/rts/LinkerInternals.h
|
||
|
+++ b/rts/LinkerInternals.h
|
||
|
@@ -303,4 +303,14 @@
|
||
|
# define OBJFORMAT_MACHO
|
||
|
#endif
|
||
|
|
||
|
+/* In order to simplify control flow a bit, some references to mmap-related
|
||
|
+ definitions are blocked off by a C-level if statement rather than a CPP-level
|
||
|
+ #if statement. Since those are dead branches when !RTS_LINKER_USE_MMAP, we
|
||
|
+ just stub out the relevant symbols here
|
||
|
+*/
|
||
|
+#if !RTS_LINKER_USE_MMAP
|
||
|
+#define munmap(x,y) /* nothing */
|
||
|
+#define MAP_ANONYMOUS 0
|
||
|
+#endif
|
||
|
+
|
||
|
#endif /* LINKERINTERNALS_H */
|
||
|
|