diff options
author | Jennifer Averett <jennifer.averett@oarcorp.com> | 2023-05-05 13:17:41 -0500 |
---|---|---|
committer | Jeff Johnston <jjohnstn@redhat.com> | 2023-05-05 14:49:48 -0400 |
commit | 742b8db95d93e4edba52bbf84afe64c9324ce89b (patch) | |
tree | f1ae0be3f0beec26a5afbeebab692900a1db0820 /newlib/libm/math | |
parent | 3bee68248fc8e164a8bb6bba3f105b10fdec8a71 (diff) | |
download | newlib-742b8db95d93e4edba52bbf84afe64c9324ce89b.zip newlib-742b8db95d93e4edba52bbf84afe64c9324ce89b.tar.gz newlib-742b8db95d93e4edba52bbf84afe64c9324ce89b.tar.bz2 |
Move signgm.c from libc/reent to libm/math
Diffstat (limited to 'newlib/libm/math')
-rw-r--r-- | newlib/libm/math/Makefile.inc | 1 | ||||
-rw-r--r-- | newlib/libm/math/signgam.c | 16 |
2 files changed, 17 insertions, 0 deletions
diff --git a/newlib/libm/math/Makefile.inc b/newlib/libm/math/Makefile.inc index 1b61d6d..d2a45bf 100644 --- a/newlib/libm/math/Makefile.inc +++ b/newlib/libm/math/Makefile.inc @@ -15,6 +15,7 @@ %D%/w_scalb.c %D%/w_sinh.c %D%/w_sqrt.c \ %D%/w_sincos.c \ %D%/w_drem.c \ + %D%/signgam.c \ %D%/s_asinh.c %D%/s_atan.c %D%/s_ceil.c \ %D%/s_cos.c %D%/s_erf.c %D%/s_fabs.c %D%/s_floor.c \ %D%/s_frexp.c %D%/s_ldexp.c \ diff --git a/newlib/libm/math/signgam.c b/newlib/libm/math/signgam.c new file mode 100644 index 0000000..b1017d8 --- /dev/null +++ b/newlib/libm/math/signgam.c @@ -0,0 +1,16 @@ +/* The signgam variable is stored in the reentrancy structure. This + function returns its address for use by the macro signgam defined in + math.h. */ + +#include <math.h> +#include <reent.h> + +#ifndef _REENT_ONLY + +int * +__signgam (void) +{ + return &_REENT_SIGNGAM(_REENT); +} + +#endif |