aboutsummaryrefslogtreecommitdiffstats
path: root/community/openlibm/aarch64_fixes.patch
blob: 4fc7b0fb2a4889feb8a0ba526d5fea84b8436ab6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
From 238a90959fff053458767dd16f193204869387c0 Mon Sep 17 00:00:00 2001
From: Yichao Yu <yyc1992@gmail.com>
Date: Sat, 21 Oct 2017 09:50:50 -0400
Subject: [PATCH] Fix compilation on AArch64

The 128bit double directory is missing and was never used....
---
 Make.inc         |  6 +++++-
 Makefile         |  5 +++++
 ld128/Make.files | 14 +++++++++++++-
 3 files changed, 23 insertions(+), 2 deletions(-)

diff --git a/Make.inc b/Make.inc
index db84d07..b1d43a7 100644
--- a/Make.inc
+++ b/Make.inc
@@ -125,8 +125,12 @@ SFLAGS_add  += $(SFLAGS_arch)
 LDFLAGS_add += $(LDFLAGS_arch)
 
 CFLAGS_add += -std=c99 -Wall -I$(OPENLIBM_HOME) -I$(OPENLIBM_HOME)/include -I$(OPENLIBM_HOME)/$(ARCH) -I$(OPENLIBM_HOME)/src -DASSEMBLER -D__BSD_VISIBLE -Wno-implicit-function-declaration
-ifneq ($(filter $(ARCH),i387 amd64 aarch64 powerpc),)
+ifneq ($(filter $(ARCH),i387 amd64 powerpc),)
 CFLAGS_add += -I$(OPENLIBM_HOME)/ld80
+else
+ifneq ($(filter $(ARCH),aarch64),)
+CFLAGS_add += -I$(OPENLIBM_HOME)/ld128
+endif
 endif
 
 
diff --git a/Makefile b/Makefile
index 1834610..e4324a9 100644
--- a/Makefile
+++ b/Makefile
@@ -5,6 +5,11 @@ SUBDIRS = src $(ARCH) bsdsrc
 # Add ld80 directory on x86 and x64
 ifneq ($(filter $(ARCH),i387 amd64),)
 SUBDIRS += ld80
+else
+ifneq ($(filter $(ARCH),aarch64),)
+SUBDIRS += ld128
+else
+endif
 endif
 
 define INC_template
diff --git a/ld128/Make.files b/ld128/Make.files
index 0eab034..1198cfb 100644
--- a/ld128/Make.files
+++ b/ld128/Make.files
@@ -1 +1,13 @@
-SRCS = invtrig.c k_cosl.c k_sinl.c k_tanl.c # s_nanl.c s_exp2l.c 
+$(CUR_SRCS) += 	invtrig.c \
+            e_acoshl.c     e_powl.c       k_tanl.c       s_exp2l.c \
+            e_atanhl.c     e_lgammal_r.c  e_sinhl.c      s_asinhl.c     s_expm1l.c \
+            e_coshl.c      e_log10l.c     e_tgammal.c \
+            e_expl.c       e_log2l.c      k_cosl.c       s_log1pl.c     s_tanhl.c \
+            e_logl.c       k_sinl.c       s_erfl.c
+
+#           s_remquol.c    e_fmodl.c      s_truncl.c
+#           e_hypotl.c     s_floorl.c     s_nextafterl.c s_ceill.c      s_modfl.c
+
+ifneq ($(OS), WINNT)
+$(CUR_SRCS) += s_nanl.c
+endif