pkgsrc-wip/erlang/patches/patch-ao
Martti Kuparinen 4d05a286c8 Erlang is a programming language which has many features more commonly
associated with an operating system than with a programming language:
concurrent processes, scheduling, memory management, distribution,
networking, etc.

The initial open-source Erlang release contains the implementation of
Erlang, as well as a large part of Ericsson's middleware for building
distributed high-availability systems.
2008-04-16 06:11:48 +00:00

26 lines
769 B
Text

$NetBSD: patch-ao,v 1.1.1.1 2008/04/16 06:11:50 marttikuparinen Exp $
--- erts/emulator/hipe/hipe_sparc.c.orig 2008-02-05 08:38:06.000000000 -0500
+++ erts/emulator/hipe/hipe_sparc.c
@@ -112,6 +112,10 @@ static void atexit_alloc_code_stats(void
#define ALLOC_CODE_STATS(X) do{}while(0)
#endif
+#if !defined(MAP_ANONYMOUS) && defined(MAP_ANON)
+#define MAP_ANONYMOUS MAP_ANON
+#endif
+
static void morecore(unsigned int alloc_bytes)
{
unsigned int map_bytes;
@@ -135,8 +139,8 @@ static void morecore(unsigned int alloc_
map_start = mmap(map_hint, map_bytes,
PROT_EXEC|PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_ANONYMOUS
-#ifdef __x86_64__
- |MAP_32BIT
+#if defined(MMAP_MAP_FIXED)
+ | MAP_FIXED
#endif
,
-1, 0);