Skip to content

Commit 9ecf223

Browse files
committed
Get the ld80 routines from OpenBSD to build on mac and linux.
Bump version number and SO major version, since we have introduced new long double APIs.
1 parent 52c901a commit 9ecf223

35 files changed

Lines changed: 377 additions & 50 deletions

Make.inc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
OS := $(shell uname)
44
# Do not forget to bump SOMINOR when changing VERSION,
55
# and SOMAJOR when breaking ABI in a backward-incompatible way
6-
VERSION = 0.4
7-
SOMAJOR = 1
6+
VERSION = 0.5
7+
SOMAJOR = 2
88
SOMINOR = 0
99
DESTDIR =
1010
prefix = /usr/local
@@ -64,7 +64,7 @@ endif
6464

6565
ifeq ($(ARCH),x86_64)
6666
override ARCH := amd64
67-
endif
67+
endif
6868

6969
ifneq (,$(findstring MINGW,$(OS)))
7070
override OS=WINNT

ld80/Make.files

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
$(CUR_SRCS) += invtrig.c \
2-
e_acoshl.c e_hypotl.c e_powl.c k_tanl.c s_exp2l.c s_nanl.c \
2+
e_acoshl.c e_powl.c k_tanl.c s_exp2l.c \
33
e_atanhl.c e_lgammal.c e_sinhl.c s_asinhl.c s_expm1l.c \
4-
e_coshl.c e_log10l.c e_tgammal.c s_floorl.c s_nextafterl.c \
5-
e_expl.c e_log2l.c k_cosl.c s_ceill.c s_log1pl.c s_tanhl.c \
6-
e_fmodl.c e_logl.c k_sinl.c s_erfl.c s_modfl.c s_truncl.c
7-
# s_remquol.c
4+
e_coshl.c e_log10l.c e_tgammal.c \
5+
e_expl.c e_log2l.c k_cosl.c s_log1pl.c s_tanhl.c \
6+
e_logl.c k_sinl.c s_erfl.c
7+
8+
# s_remquol.c e_fmodl.c s_truncl.c
9+
# e_hypotl.c s_floorl.c s_nextafterl.c s_ceill.c s_modfl.c
810

911
ifneq ($(OS), WINNT)
1012
$(CUR_SRCS) += s_nanl.c

ld80/e_acoshl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
* acoshl(NaN) is NaN without signal.
2525
*/
2626

27-
#include <math.h>
27+
#include <openlibm.h>
2828

2929
#include "math_private.h"
3030

ld80/e_atanhl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
*
2929
*/
3030

31-
#include <math.h>
31+
#include <openlibm.h>
3232

3333
#include "math_private.h"
3434

ld80/e_coshl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
* only coshl(0)=1 is exact for finite x.
3232
*/
3333

34-
#include "math.h"
34+
#include "openlibm.h"
3535
#include "math_private.h"
3636

3737
static const long double one = 1.0, half=0.5, huge = 1.0e4900L;

ld80/e_expl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272

7373
/* Exponential function */
7474

75-
#include <math.h>
75+
#include <openlibm.h>
7676

7777
#include "math_private.h"
7878

ld80/e_hypotl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
* than 1 ulps (units in the last place)
4343
*/
4444

45-
#include <math.h>
45+
#include <openlibm.h>
4646

4747
#include "math_private.h"
4848

ld80/e_lgammal.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,10 @@
8686
*
8787
*/
8888

89-
#include <math.h>
89+
#include <openlibm.h>
9090

9191
#include "math_private.h"
92+
extern int signgam;
9293

9394
static const long double
9495
half = 0.5L,

ld80/e_log10l.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
* log domain: x < 0; returns MINLOG
6464
*/
6565

66-
#include <math.h>
66+
#include <openlibm.h>
6767

6868
#include "math_private.h"
6969

ld80/e_log2l.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
* log domain: x < 0; returns NAN
6464
*/
6565

66-
#include <math.h>
66+
#include <openlibm.h>
6767

6868
#include "math_private.h"
6969

0 commit comments

Comments
 (0)