Hi,
this patch unifies DATA only imports for different runtime-versions of
msvcr* import libraries.
Additionally it marks some functions to be in future DATA only, if
function is locally implemented in our crt.
This patch is done only for 32-bit for now. Of course for the 64-bit
version same thing needs to be done.
Any comment on this patch?
Kai
PS: Alexey, as told on IRC, this change needs to be tested pretty
intensive for 32-bit code, as in some context math changes.
From 6bf013efd04a88c909c4078dd5160b5e6a7e8ccb Mon Sep 17 00:00:00 2001
From: Kai Tietz <ktiet...@googlemail.com>
Date: Tue, 14 Oct 2014 12:51:09 +0200
Subject: Unify DATA only symbols imported from msvcr*
---
mingw-w64-crt/lib32/crtdll.def | 12 +++++-----
mingw-w64-crt/lib32/msvcr100.def.in | 15 +++++++++----
mingw-w64-crt/lib32/msvcr110.def.in | 39 +++++++++++++++++++---------------
mingw-w64-crt/lib32/msvcr80.def.in | 27 ++++++++++++++---------
mingw-w64-crt/lib32/msvcr90.def.in | 15 +++++++++----
mingw-w64-crt/lib32/msvcr90d.def.in | 25 +++++++++++++---------
mingw-w64-crt/lib32/msvcrt.def.in | 29 ++++++++++++++++---------
mingw-w64-crt/lib32/ntdll.def | 8 +++---
8 files changed, 101 insertions(+), 69 deletions(-)
diff --git a/mingw-w64-crt/lib32/crtdll.def b/mingw-w64-crt/lib32/crtdll.def
index 928f75e..df6d37b 100644
--- a/mingw-w64-crt/lib32/crtdll.def
+++ b/mingw-w64-crt/lib32/crtdll.def
@@ -511,9 +511,9 @@ abort
abs
acos
asctime
-asin
-atan
-atan2
+asin DATA
+atan DATA
+atan2 DATA
atexit DATA
atof
atoi
@@ -523,15 +523,15 @@ calloc
ceil
clearerr
clock
-cos
+cos DATA
cosh
ctime DATA
;_ctime32 = ctime
difftime
div
exit
-exp
-fabs
+exp DATA
+fabs DATA
fclose
feof
ferror
diff --git a/mingw-w64-crt/lib32/msvcr100.def.in
b/mingw-w64-crt/lib32/msvcr100.def.in
index 38498d4..e213f1a 100644
--- a/mingw-w64-crt/lib32/msvcr100.def.in
+++ b/mingw-w64-crt/lib32/msvcr100.def.in
@@ -1667,12 +1667,12 @@ _y1
_yn
abort
abs
-acos
+acos DATA
asctime
asctime_s
-asin
-atan
-atan2
+asin DATA
+atan DATA
+atan2 DATA
atexit DATA
atof
atoi
@@ -1686,6 +1686,7 @@ clearerr
clearerr_s
clock
cos DATA
+; If we implement cosh too, we can set it to DATA only.
cosh
div
exit
@@ -1715,6 +1716,7 @@ fread_s
free
freopen
freopen_s
+; If we implement frexp, we can set it to DATA only.
frexp
fscanf
fscanf_s
@@ -1767,6 +1769,7 @@ llabs DATA
lldiv DATA
localeconv
log DATA
+; If we implement log10, we can set it to DATA only.
log10
malloc
mblen
@@ -1810,6 +1813,7 @@ setlocale
setvbuf
signal
sin DATA
+; If we implenent sinh, we can set it to DATA only.
sinh
sprintf
sprintf_s
@@ -1849,7 +1853,8 @@ swprintf_s
swscanf
swscanf_s
system
-tan
+tan DATA
+; If we implement tanh, we can set it to DATA only.
tanh
tmpfile
tmpfile_s
diff --git a/mingw-w64-crt/lib32/msvcr110.def.in
b/mingw-w64-crt/lib32/msvcr110.def.in
index 5362b21..9034f49 100644
--- a/mingw-w64-crt/lib32/msvcr110.def.in
+++ b/mingw-w64-crt/lib32/msvcr110.def.in
@@ -1800,12 +1800,12 @@ _y1
_yn
abort ; Check!!! Couldn't determine function argument count. Function doesn't
return.
abs
-acos
+acos DATA
asctime
asctime_s
-asin
-atan
-atan2
+asin DATA
+atan DATA
+atan2 DATA
atexit DATA
atof
atoi
@@ -1814,16 +1814,17 @@ bsearch
bsearch_s
btowc
calloc
-ceil
+ceil DATA
clearerr
clearerr_s
clock
-cos
+cos DATA
+; If we implement cosh, we can set it to DATA only.
cosh
div
exit
-exp
-fabs
+exp DATA
+fabs DATA
fclose
feof
ferror
@@ -1833,8 +1834,8 @@ fgetpos
fgets
fgetwc
fgetws
-floor
-fmod
+floor DATA
+fmod DATA
fopen
fopen_s
fprintf
@@ -1848,6 +1849,7 @@ fread_s
free
freopen
freopen_s
+; If we implement frexp, we can set it to DATA only.
frexp
fscanf
fscanf_s
@@ -1894,12 +1896,13 @@ iswupper
iswxdigit
isxdigit
labs
-ldexp
+ldexp DATA
ldiv
llabs
lldiv
localeconv
-log
+log DATA
+; If we implement log10, we can set it to DATA only.
log10
malloc
mblen
@@ -1917,9 +1920,9 @@ memcpy_s
memmove
memmove_s
memset
-modf
+modf DATA
perror
-pow
+pow DATA
printf
printf_s
putc
@@ -1942,11 +1945,12 @@ setbuf
setlocale
setvbuf
signal
-sin
+sin DATA
+; If we implement sinh, we can set it to DATA only.
sinh
sprintf
sprintf_s
-sqrt
+sqrt DATA
srand
sscanf
sscanf_s
@@ -1982,7 +1986,8 @@ swprintf_s
swscanf
swscanf_s
system
-tan
+tan DATA
+; If we implement tanh, we can set it to DATA only.
tanh
tmpfile
tmpfile_s
diff --git a/mingw-w64-crt/lib32/msvcr80.def.in
b/mingw-w64-crt/lib32/msvcr80.def.in
index d61fafc..345f49d 100644
--- a/mingw-w64-crt/lib32/msvcr80.def.in
+++ b/mingw-w64-crt/lib32/msvcr80.def.in
@@ -536,11 +536,11 @@ _y1
_yn
abort
abs
-acos
+acos DATA
asctime
-asin
-atan
-atan2
+asin DATA
+atan DATA
+atan2 DATA
atexit DATA
atof
atoi
@@ -550,7 +550,8 @@ calloc
ceil DATA
clearerr
clock
-cos
+cos DATA
+; If we implement cosh, we can set it to DATA only.
cosh
_ctime32
ctime == _ctime32
@@ -558,7 +559,7 @@ difftime
div
exit
exp DATA
-fabs
+fabs DATA
fclose
feof
ferror
@@ -569,7 +570,7 @@ fgets
fgetwc
fgetws
floor DATA
-fmod
+fmod DATA
fopen
fprintf
fputc
@@ -579,6 +580,7 @@ fputws
fread
free
freopen
+; If we implement frexp, we can set it to DATA only.
frexp
fscanf
fseek
@@ -628,6 +630,7 @@ localeconv
localtime == _localtime32
_localtime32
log DATA
+; If we implement log10, we can set it to DATA only.
log10
malloc
mblen
@@ -640,9 +643,9 @@ memmove
memset
mktime == _mktime32
_mktime32
-modf
+modf DATA
perror
-;pow
+pow DATA
printf
putc
putchar
@@ -662,7 +665,8 @@ setbuf
setlocale
setvbuf
signal
-sin
+sin DATA
+; If we impelement sinh, we can set it to DATA only.
sinh
sprintf
sqrt DATA
@@ -692,7 +696,8 @@ strxfrm
swprintf
swscanf
system
-tan
+tan DATA
+; If we implement tanh, we can set it to DATA only.
tanh
_time32
time == _time32
diff --git a/mingw-w64-crt/lib32/msvcr90.def.in
b/mingw-w64-crt/lib32/msvcr90.def.in
index a66d831..e6481e5 100644
--- a/mingw-w64-crt/lib32/msvcr90.def.in
+++ b/mingw-w64-crt/lib32/msvcr90.def.in
@@ -1301,12 +1301,12 @@ _y1
_yn
abort
abs
-acos
+acos DATA
asctime
asctime_s
-asin
-atan
-atan2
+asin DATA
+atan DATA
+atan2 DATA
atexit DATA
atof
atoi
@@ -1320,6 +1320,7 @@ clearerr
clearerr_s
clock
cos DATA
+; If we have cosh implementation, we can set it to DATA only.
cosh
div
exit
@@ -1349,6 +1350,7 @@ fread_s
free
freopen
freopen_s
+; If we have frexp implementation too, we need to change this to DATA only
frexp
fscanf
fscanf_s
@@ -1399,6 +1401,7 @@ ldexp DATA
ldiv
localeconv
log DATA
+; If we have log10 implemtation too, we can set this to DATA only.
log10
malloc
mblen
@@ -1442,6 +1445,7 @@ setlocale
setvbuf
signal
sin DATA
+; If we have sinh implemtation, we can set it to DATA only.
sinh
sprintf
sprintf_s
@@ -1481,7 +1485,8 @@ swprintf_s
swscanf
swscanf_s
system
-tan
+tan DATA
+; If we have tanh implementation, we can set it to DATA only too.
tanh
tmpfile
tmpfile_s
diff --git a/mingw-w64-crt/lib32/msvcr90d.def.in
b/mingw-w64-crt/lib32/msvcr90d.def.in
index b9466da..9c2e81d 100644
--- a/mingw-w64-crt/lib32/msvcr90d.def.in
+++ b/mingw-w64-crt/lib32/msvcr90d.def.in
@@ -1373,12 +1373,12 @@ _y1
_yn
abort
abs
-acos
+acos DATA
asctime
asctime_s
-asin
-atan
-atan2
+asin DATA
+atan DATA
+atan2 DATA
atexit DATA
atof
atoi
@@ -1391,12 +1391,13 @@ ceil DATA
clearerr
clearerr_s
clock
-cos
+cos DATA
+; If we implement cosh too, we can set it to DATA only.
cosh
div
exit
exp DATA
-fabs
+fabs DATA
fclose
feof
ferror
@@ -1421,6 +1422,7 @@ fread_s
free
freopen
freopen_s
+; If we implement frexp too, we can set it to DATA only.
frexp
fscanf
fscanf_s
@@ -1471,6 +1473,7 @@ ldexp DATA
ldiv
localeconv
log DATA
+; If we implement log10 too, we can set this to DATA only.
log10
malloc
mblen
@@ -1488,9 +1491,9 @@ memcpy_s
memmove
memmove_s
memset
-modf
+modf DATA
perror
-pow
+pow DATA
printf
printf_s
putc
@@ -1513,7 +1516,8 @@ setbuf
setlocale
setvbuf
signal
-sin
+sin DATA
+; If we implement sinh too, we can set it to DATA only.
sinh
sprintf
sprintf_s
@@ -1553,7 +1557,8 @@ swprintf_s
swscanf
swscanf_s
system
-tan
+tan DATA
+; If we implement tanh too, we can set it to DATA only.
tanh
tmpfile
tmpfile_s
diff --git a/mingw-w64-crt/lib32/msvcrt.def.in
b/mingw-w64-crt/lib32/msvcrt.def.in
index b1ac1b7..d6a23e9 100644
--- a/mingw-w64-crt/lib32/msvcrt.def.in
+++ b/mingw-w64-crt/lib32/msvcrt.def.in
@@ -532,11 +532,11 @@ _y1
_yn
abort
abs
-acos
+acos DATA
asctime
-asin
-atan
-atan2
+asin DATA
+atan DATA
+atan2 DATA
atexit DATA
atof
atoi
@@ -546,7 +546,9 @@ calloc
ceil DATA
clearerr
clock
-cos
+cos DATA
+; Here we lack a cosh implementation. If we have, we need to change
+; this to DATA only, too
cosh
ctime
_ctime32 == ctime
@@ -554,7 +556,7 @@ difftime
div
exit
exp DATA
-fabs
+fabs DATA
fclose
feof
ferror
@@ -565,7 +567,7 @@ fgets
fgetwc
fgetws
floor DATA
-fmod
+fmod DATA
fopen
fprintf
fputc
@@ -575,6 +577,8 @@ fputws
fread
free
freopen
+; If we have frexp implementation too, we need to change this to DATA only
+; too.
frexp
fscanf
fseek
@@ -624,6 +628,7 @@ localeconv
localtime
_localtime32 == localtime
log DATA
+; If we have log10 implementation too, we need to set this to DATA only.
log10
malloc
mblen
@@ -636,9 +641,9 @@ memmove
memset
mktime
_mktime32 == mktime
-modf
+modf DATA
perror
-;pow
+pow DATA
printf
putc
putchar
@@ -658,7 +663,8 @@ setbuf
setlocale
setvbuf
signal
-sin
+sin DATA
+; If we have sinh implementation too, we can set it to DATA only.
sinh
sprintf
sqrt DATA
@@ -688,7 +694,8 @@ strxfrm
swprintf
swscanf
system
-tan
+tan DATA
+; If we have tanh implemtation too, we can set it to DATA only too.
tanh
time
tmpfile
diff --git a/mingw-w64-crt/lib32/ntdll.def b/mingw-w64-crt/lib32/ntdll.def
index 88de13e..d6837b1 100644
--- a/mingw-w64-crt/lib32/ntdll.def
+++ b/mingw-w64-crt/lib32/ntdll.def
@@ -1982,14 +1982,14 @@ _wtoi
_wtoi64
_wtol
abs
-atan
+atan DATA
atoi
atol
bsearch
ceil
-cos
-fabs
-floor
+cos DATA
+fabs DATA
+floor DATA
isalnum
isalpha
iscntrl
--
1.7.9
------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public