xref: /openbsd-src/lib/libm/src/w_lgamma.c (revision 2f2c00629eff6a304ebffb255fc56f4fa7a1833b)
1190a67d7Smartynas /* @(#)w_lgamma.c 5.1 93/09/24 */
2190a67d7Smartynas /*
3190a67d7Smartynas  * ====================================================
4190a67d7Smartynas  * Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved.
5190a67d7Smartynas  *
6190a67d7Smartynas  * Developed at SunPro, a Sun Microsystems, Inc. business.
7190a67d7Smartynas  * Permission to use, copy, modify, and distribute this
8190a67d7Smartynas  * software is freely granted, provided that this notice
9190a67d7Smartynas  * is preserved.
10190a67d7Smartynas  * ====================================================
11190a67d7Smartynas  */
12190a67d7Smartynas 
13190a67d7Smartynas /* double lgamma(double x)
14190a67d7Smartynas  * Return the logarithm of the Gamma function of x.
15190a67d7Smartynas  *
16190a67d7Smartynas  * Method: call lgamma_r
17190a67d7Smartynas  */
18190a67d7Smartynas 
1949393c00Smartynas #include <float.h>
2049393c00Smartynas #include <math.h>
2149393c00Smartynas 
22190a67d7Smartynas #include "math_private.h"
23190a67d7Smartynas 
24190a67d7Smartynas extern int signgam;
25190a67d7Smartynas 
26190a67d7Smartynas double
lgamma(double x)27190a67d7Smartynas lgamma(double x)
28190a67d7Smartynas {
29190a67d7Smartynas 	return lgamma_r(x,&signgam);
30190a67d7Smartynas }
31*2f2c0062Sguenther DEF_STD(lgamma);
32*2f2c0062Sguenther LDBL_MAYBE_CLONE(lgamma);
33