2 Copyright © 1995-2006, The AROS Development Team. All rights reserved.
5 Desc: Init of 68k/FPU mathieeedoubtrans.library
8 #include <aros/symbolsets.h>
9 #include <aros/libcall.h>
10 #include <utility/utility.h> /* this must be before mathieeedoubtrans_intern.h */
12 #include "mathieeedoubtrans_intern.h"
14 #define SetFunc(a,b) SetFunction((struct Library *)lh, a * -LIB_VECTSIZE, AROS_SLIB_ENTRY(b,MathIeeeDoubTrans,a))
16 extern void AROS_SLIB_ENTRY(ATan_6888x
,MathIeeeDoubTrans
,5)(void);
17 extern void AROS_SLIB_ENTRY(Sin_6888x
,MathIeeeDoubTrans
,6)(void);
18 extern void AROS_SLIB_ENTRY(Cos_6888x
,MathIeeeDoubTrans
,7)(void);
19 extern void AROS_SLIB_ENTRY(Tan_6888x
,MathIeeeDoubTrans
,8)(void);
20 extern void AROS_SLIB_ENTRY(Sincos_6888x
,MathIeeeDoubTrans
,9)(void);
21 extern void AROS_SLIB_ENTRY(Sinh_6888x
,MathIeeeDoubTrans
,10)(void);
22 extern void AROS_SLIB_ENTRY(Cosh_6888x
,MathIeeeDoubTrans
,11)(void);
23 extern void AROS_SLIB_ENTRY(Tanh_6888x
,MathIeeeDoubTrans
,12)(void);
24 extern void AROS_SLIB_ENTRY(Exp_6888x
,MathIeeeDoubTrans
,13)(void);
25 extern void AROS_SLIB_ENTRY(Log_6888x
,MathIeeeDoubTrans
,14)(void);
26 extern void AROS_SLIB_ENTRY(Pow_6888x
,MathIeeeDoubTrans
,15)(void);
27 extern void AROS_SLIB_ENTRY(Sqrt_6888x
,MathIeeeDoubTrans
,16)(void);
28 extern void AROS_SLIB_ENTRY(Tieee_6888x
,MathIeeeDoubTrans
,17)(void);
29 extern void AROS_SLIB_ENTRY(Fieee_6888x
,MathIeeeDoubTrans
,18)(void);
30 extern void AROS_SLIB_ENTRY(Asin_6888x
,MathIeeeDoubTrans
,19)(void);
31 extern void AROS_SLIB_ENTRY(Acos_6888x
,MathIeeeDoubTrans
,20)(void);
32 extern void AROS_SLIB_ENTRY(Log10_6888x
,MathIeeeDoubTrans
,21)(void);
34 struct Library
*MathIeeeDoubBasBase
;
36 static int IEEEDPT_Init(struct MathIeeeDoubTransBase
*lh
)
38 MathIeeeDoubBasBase
= OpenLibrary("mathieeedoubbas.library", 39);
39 if (!MathIeeeDoubBasBase
)
42 if (SysBase
->AttnFlags
& (AFF_68881
| AFF_68882
| AFF_FPU40
)) {
43 SetFunc(5, ATan_6888x
);
44 SetFunc(6, Sin_6888x
);
45 SetFunc(7, Cos_6888x
);
46 SetFunc(8, Tan_6888x
);
47 SetFunc(9, Sincos_6888x
);
48 SetFunc(10, Sinh_6888x
);
49 SetFunc(11, Cosh_6888x
);
50 SetFunc(12, Tanh_6888x
);
51 SetFunc(13, Exp_6888x
);
52 SetFunc(14, Log_6888x
);
53 /* SetFunc(15, Pow_6888x); */
54 SetFunc(16, Sqrt_6888x
);
55 SetFunc(17, Tieee_6888x
);
56 SetFunc(18, Fieee_6888x
);
57 SetFunc(19, Asin_6888x
);
58 SetFunc(20, Acos_6888x
);
59 SetFunc(21, Log10_6888x
);
64 static int IEEEDPT_Expunge(struct Library
*lh
)
66 if (MathIeeeDoubBasBase
)
67 CloseLibrary (MathIeeeDoubBasBase
);
71 ADD2INITLIB(IEEEDPT_Init
, 0)
72 ADD2EXPUNGELIB(IEEEDPT_Expunge
, 0);