lang/erlang-runtime{20,21}: Add patch to fix build on i386

Those two ports fail to build on FreeBSD/i386 (all versions) for quite
some time. The Erlang/OTP team provided a patch after Dewayne Geraghty
reported the issue upstream.

Here is the entry in the Erlang/OTP bug tracker:
https://bugs.erlang.org/browse/ERL-677

The patch was successfully tested on FreeBSD 10.4 and 11.1, both i386
and amd64. Dewayne also confirmed success on FreeBSD 11.2.

PR:		229600
Reported by:	Dewayne Geraghty <dewayne@heuristicsystems.com.au>
Obtained from:	https://bugs.erlang.org/browse/ERL-677
MFH:		2018Q3
This commit is contained in:
Jean-Sébastien Pédron 2018-07-30 09:14:40 +00:00
parent 53bf8dcb20
commit 6b337ae478
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=475871
4 changed files with 24 additions and 0 deletions

View File

@ -3,6 +3,7 @@
PORTNAME= erlang
PORTVERSION= 20.3.8.3
PORTREVISION= 1
CATEGORIES= lang parallel java
MASTER_SITES= http://www.erlang.org/download/:erlangorg \
http://erlang.stacken.kth.se/download/:erlangorg \

View File

@ -0,0 +1,11 @@
--- erts/emulator/beam/erl_alloc.c.orig 2018-03-13 20:11:05 UTC
+++ erts/emulator/beam/erl_alloc.c
@@ -122,7 +122,7 @@ typedef union {
char align_afa[ERTS_ALC_CACHE_LINE_ALIGN_SIZE(sizeof(AFAllctr_t))];
AOFFAllctr_t aoffa;
char align_aoffa[ERTS_ALC_CACHE_LINE_ALIGN_SIZE(sizeof(AOFFAllctr_t))];
-} ErtsAllocatorState_t;
+} ErtsAllocatorState_t erts_align_attribute(ERTS_CACHE_LINE_SIZE);
static ErtsAllocatorState_t std_alloc_state;
static ErtsAllocatorState_t ll_alloc_state;

View File

@ -3,6 +3,7 @@
PORTNAME= erlang
PORTVERSION= 21.0.4
PORTREVISION= 1
CATEGORIES= lang parallel java
MASTER_SITES= http://www.erlang.org/download/:erlangorg \
http://erlang.stacken.kth.se/download/:erlangorg \

View File

@ -0,0 +1,11 @@
--- erts/emulator/beam/erl_alloc.c.orig 2018-06-19 07:07:55 UTC
+++ erts/emulator/beam/erl_alloc.c
@@ -114,7 +114,7 @@ typedef union {
char align_afa[ERTS_ALC_CACHE_LINE_ALIGN_SIZE(sizeof(AFAllctr_t))];
AOFFAllctr_t aoffa;
char align_aoffa[ERTS_ALC_CACHE_LINE_ALIGN_SIZE(sizeof(AOFFAllctr_t))];
-} ErtsAllocatorState_t;
+} ErtsAllocatorState_t erts_align_attribute(ERTS_CACHE_LINE_SIZE);
static ErtsAllocatorState_t std_alloc_state;
static ErtsAllocatorState_t ll_alloc_state;