2 * MSVCRT Unix interface
4 * Copyright 2020 Alexandre Julliard
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
26 #include "wine/port.h"
30 #define __USE_ISOC9X 1
31 #define __USE_ISOC99 1
38 #define WIN32_NO_STATUS
41 #include "wine/debug.h"
43 WINE_DEFAULT_DEBUG_CHANNEL(msvcrt
);
45 /*********************************************************************
48 static double CDECL
unix_cosh( double x
)
53 /*********************************************************************
56 static float CDECL
unix_coshf( float x
)
61 /*********************************************************************
64 static double CDECL
unix_exp( double x
)
69 /*********************************************************************
72 static float CDECL
unix_expf( float x
)
77 /*********************************************************************
80 static double CDECL
unix_exp2( double x
)
89 /*********************************************************************
92 static float CDECL
unix_exp2f( float x
)
101 /*********************************************************************
104 static double CDECL
unix_expm1(double x
)
113 /*********************************************************************
116 static float CDECL
unix_expm1f(float x
)
125 /*********************************************************************
128 static double CDECL
unix_fma( double x
, double y
, double z
)
137 /*********************************************************************
140 static float CDECL
unix_fmaf( float x
, float y
, float z
)
143 return fmaf(x
, y
, z
);
149 /*********************************************************************
152 static double CDECL
unix_frexp( double x
, int *exp
)
154 return frexp( x
, exp
);
157 /*********************************************************************
160 static float CDECL
unix_frexpf( float x
, int *exp
)
162 return frexpf( x
, exp
);
165 /*********************************************************************
168 static double CDECL
unix_hypot(double x
, double y
)
170 return hypot( x
, y
);
173 /*********************************************************************
176 static float CDECL
unix_hypotf(float x
, float y
)
178 return hypotf( x
, y
);
181 /*********************************************************************
184 static double CDECL
unix_ldexp(double num
, int exp
)
186 return ldexp( num
, exp
);
189 /*********************************************************************
192 static double CDECL
unix_lgamma(double x
)
197 FIXME( "not implemented\n" );
202 /*********************************************************************
205 static float CDECL
unix_lgammaf(float x
)
210 FIXME( "not implemented\n" );
215 /*********************************************************************
218 static double CDECL
unix_log( double x
)
223 /*********************************************************************
226 static float CDECL
unix_logf( float x
)
231 /*********************************************************************
234 static double CDECL
unix_log10( double x
)
239 /*********************************************************************
242 static float CDECL
unix_log10f( float x
)
247 /*********************************************************************
250 static double CDECL
unix_log1p(double x
)
259 /*********************************************************************
262 static float CDECL
unix_log1pf(float x
)
271 /*********************************************************************
274 static double CDECL
unix_log2(double x
)
279 return log(x
) / log(2);
283 /*********************************************************************
286 static float CDECL
unix_log2f(float x
)
295 /*********************************************************************
298 static double CDECL
unix_pow( double x
, double y
)
303 /*********************************************************************
306 static float CDECL
unix_powf( float x
, float y
)
311 /*********************************************************************
314 static double CDECL
unix_sinh( double x
)
319 /*********************************************************************
322 static float CDECL
unix_sinhf( float x
)
327 /*********************************************************************
330 static double CDECL
unix_tanh( double x
)
335 /*********************************************************************
338 static float CDECL
unix_tanhf( float x
)
343 /*********************************************************************
346 static double CDECL
unix_tgamma(double x
)
351 FIXME( "not implemented\n" );
356 /*********************************************************************
359 static float CDECL
unix_tgammaf(float x
)
364 FIXME( "not implemented\n" );
369 static const struct unix_funcs funcs
=
406 NTSTATUS CDECL
__wine_init_unix_lib( HMODULE module
, DWORD reason
, const void *ptr_in
, void *ptr_out
)
408 if (reason
!= DLL_PROCESS_ATTACH
) return STATUS_SUCCESS
;
410 *(const struct unix_funcs
**)ptr_out
= &funcs
;
411 return STATUS_SUCCESS
;