Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
69ad3c11
Commit
69ad3c11
authored
Apr 29, 2021
by
Piotr Caban
Committed by
Alexandre Julliard
Apr 29, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msvcrt: Import lround implementation from musl.
Signed-off-by:
Piotr Caban
<
piotr@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
7fa8b03c
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
8 additions
and
20 deletions
+8
-20
configure
configure
+0
-1
configure.ac
configure.ac
+0
-1
math.c
dlls/msvcrt/math.c
+8
-1
unixlib.c
dlls/msvcrt/unixlib.c
+0
-13
unixlib.h
dlls/msvcrt/unixlib.h
+0
-1
config.h.in
include/config.h.in
+0
-3
No files found.
configure
View file @
69ad3c11
...
@@ -19641,7 +19641,6 @@ for ac_func in \
...
@@ -19641,7 +19641,6 @@ for ac_func in \
log2f
\
log2f
\
lrint
\
lrint
\
lrintf
\
lrintf
\
lround
\
nearbyint
\
nearbyint
\
nearbyintf
\
nearbyintf
\
nexttoward
\
nexttoward
\
...
...
configure.ac
View file @
69ad3c11
...
@@ -2684,7 +2684,6 @@ AC_CHECK_FUNCS(\
...
@@ -2684,7 +2684,6 @@ AC_CHECK_FUNCS(\
log2f \
log2f \
lrint \
lrint \
lrintf \
lrintf \
lround \
nearbyint \
nearbyint \
nearbyintf \
nearbyintf \
nexttoward \
nexttoward \
...
...
dlls/msvcrt/math.c
View file @
69ad3c11
...
@@ -4360,10 +4360,17 @@ float CDECL roundf(float x)
...
@@ -4360,10 +4360,17 @@ float CDECL roundf(float x)
/*********************************************************************
/*********************************************************************
* lround (MSVCR120.@)
* lround (MSVCR120.@)
*
* Copied from musl: src/math/lround.c
*/
*/
__msvcrt_long
CDECL
lround
(
double
x
)
__msvcrt_long
CDECL
lround
(
double
x
)
{
{
return
unix_funcs
->
lround
(
x
);
double
d
=
round
(
x
);
if
(
d
!=
(
double
)(
__msvcrt_long
)
d
)
{
*
_errno
()
=
EDOM
;
return
0
;
}
return
d
;
}
}
/*********************************************************************
/*********************************************************************
...
...
dlls/msvcrt/unixlib.c
View file @
69ad3c11
...
@@ -766,18 +766,6 @@ static double CDECL unix_round(double x)
...
@@ -766,18 +766,6 @@ static double CDECL unix_round(double x)
}
}
/*********************************************************************
/*********************************************************************
* lround
*/
static
int
CDECL
unix_lround
(
double
x
)
{
#ifdef HAVE_LROUND
return
lround
(
x
);
#else
return
unix_round
(
x
);
#endif
}
/*********************************************************************
* sin
* sin
*/
*/
static
double
CDECL
unix_sin
(
double
x
)
static
double
CDECL
unix_sin
(
double
x
)
...
@@ -944,7 +932,6 @@ static const struct unix_funcs funcs =
...
@@ -944,7 +932,6 @@ static const struct unix_funcs funcs =
unix_logbf
,
unix_logbf
,
unix_lrint
,
unix_lrint
,
unix_lrintf
,
unix_lrintf
,
unix_lround
,
unix_modf
,
unix_modf
,
unix_modff
,
unix_modff
,
unix_nearbyint
,
unix_nearbyint
,
...
...
dlls/msvcrt/unixlib.h
View file @
69ad3c11
...
@@ -74,7 +74,6 @@ struct unix_funcs
...
@@ -74,7 +74,6 @@ struct unix_funcs
float
(
CDECL
*
logbf
)(
float
x
);
float
(
CDECL
*
logbf
)(
float
x
);
int
(
CDECL
*
lrint
)(
double
x
);
int
(
CDECL
*
lrint
)(
double
x
);
int
(
CDECL
*
lrintf
)(
float
x
);
int
(
CDECL
*
lrintf
)(
float
x
);
int
(
CDECL
*
lround
)(
double
x
);
double
(
CDECL
*
modf
)(
double
x
,
double
*
iptr
);
double
(
CDECL
*
modf
)(
double
x
,
double
*
iptr
);
float
(
CDECL
*
modff
)(
float
x
,
float
*
iptr
);
float
(
CDECL
*
modff
)(
float
x
,
float
*
iptr
);
double
(
CDECL
*
nearbyint
)(
double
num
);
double
(
CDECL
*
nearbyint
)(
double
num
);
...
...
include/config.h.in
View file @
69ad3c11
...
@@ -477,9 +477,6 @@
...
@@ -477,9 +477,6 @@
/* Define to 1 if you have the `lrintf' function. */
/* Define to 1 if you have the `lrintf' function. */
#undef HAVE_LRINTF
#undef HAVE_LRINTF
/* Define to 1 if you have the `lround' function. */
#undef HAVE_LROUND
/* Define to 1 if you have the `lstat' function. */
/* Define to 1 if you have the `lstat' function. */
#undef HAVE_LSTAT
#undef HAVE_LSTAT
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment