Re: [Mingw-w64-public] [PATCH 1/3] crt: Add a def file for ucrtbase.dll
On Thu, 21 Sep 2017, Kai Tietz via Mingw-w64-public wrote: Hi, sorry for the late reply. I hope you already pushed it. For completeness: there are no objections from my POV. I actually hadn't pushed it yet, I have been distracted by other projects. But pushed it now - thanks for the reviews! Now I'll try to do a few minor simplification patches on top. // Martin -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] [PATCH 1/3] crt: Add a def file for ucrtbase.dll
Hi, sorry for the late reply. I hope you already pushed it. For completeness: there are no objections from my POV. Thanks, Kai 2017-09-13 10:40 GMT+02:00 Martin Storsjö: > On Mon, 11 Sep 2017, Martin Storsjö wrote: > >> On Mon, 11 Sep 2017, Jacek Caban wrote: >> >>> Hi Martin, >>> >>> On 11.09.2017 14:48, Martin Storsjö wrote: +_ctime32 +; _ctime32_s replaced by emu +_ctime64 +; _ctime64_s replaced by emu >>> >>> >>> >>> This doesn't look right, we should use .def file to expose those. I >>> noticed a few similar other cases in the patch. >>> >>> >>> In general, we should use as few compatibility tricks possible for >>> ucrtbase as much as since we can depend on those functions being present >>> in runtime. Having something like you're working on was actually the >>> main reason I moved a lot of compatibility code from mingwex into >>> libmsvcrt.a a few years ago. There are more things that could be moved >>> away from mingwex like that. From your other patch, for example, it >>> looks like we may not need mingw variants of printf/scanf family when >>> targetting ucrtbase, so maybe we could even move them to libmsvcrt.a as >>> well. I'm not sure. >> >> >> Yes, those shouldn't be needed any longer. They aren't used by default at >> all either, unless __USE_MINGW_ANSI_STDIO is defined. If it is, we still use >> our own routines for safety, but if others are ok with it, we can probably >> change it. But it might be easier to make each of those changes a separate >> patch/discussion later, after we've got a first common state merged. >> >>> Anyway, that doesn't have to block integration of your work, but it'd be >>> nice to take into account when doing design decisions. For this patch, >>> just please review those "replaced by emu" cases since they shouldn't be >>> needed for ucrtbase. >> >> >> Sure, I can try to have a look through those and see if I can figure out >> what the situation is. > > > Thanks for pointing these out; I went through all the functions that I had > commented out in this patch, and almost all of them were in replacements in > secapi/* that only was built into libmsvcrt.a but not into the numbered > ones. So after uncommenting those, only a few functions are uncommented > (that are replaced by libmingwex). > > If there's no other comments/objections, I'll push this patchset soon. > > > // Martin > -- > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > ___ > Mingw-w64-public mailing list > Mingw-w64-public@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/mingw-w64-public -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] [PATCH 1/3] crt: Add a def file for ucrtbase.dll
On Mon, 11 Sep 2017, Martin Storsjö wrote: On Mon, 11 Sep 2017, Jacek Caban wrote: Hi Martin, On 11.09.2017 14:48, Martin Storsjö wrote: +_ctime32 +; _ctime32_s replaced by emu +_ctime64 +; _ctime64_s replaced by emu This doesn't look right, we should use .def file to expose those. I noticed a few similar other cases in the patch. In general, we should use as few compatibility tricks possible for ucrtbase as much as since we can depend on those functions being present in runtime. Having something like you're working on was actually the main reason I moved a lot of compatibility code from mingwex into libmsvcrt.a a few years ago. There are more things that could be moved away from mingwex like that. From your other patch, for example, it looks like we may not need mingw variants of printf/scanf family when targetting ucrtbase, so maybe we could even move them to libmsvcrt.a as well. I'm not sure. Yes, those shouldn't be needed any longer. They aren't used by default at all either, unless __USE_MINGW_ANSI_STDIO is defined. If it is, we still use our own routines for safety, but if others are ok with it, we can probably change it. But it might be easier to make each of those changes a separate patch/discussion later, after we've got a first common state merged. Anyway, that doesn't have to block integration of your work, but it'd be nice to take into account when doing design decisions. For this patch, just please review those "replaced by emu" cases since they shouldn't be needed for ucrtbase. Sure, I can try to have a look through those and see if I can figure out what the situation is. Thanks for pointing these out; I went through all the functions that I had commented out in this patch, and almost all of them were in replacements in secapi/* that only was built into libmsvcrt.a but not into the numbered ones. So after uncommenting those, only a few functions are uncommented (that are replaced by libmingwex). If there's no other comments/objections, I'll push this patchset soon. // Martin -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] [PATCH 1/3] crt: Add a def file for ucrtbase.dll
On Mon, 11 Sep 2017, Jacek Caban wrote: Hi Martin, On 11.09.2017 14:48, Martin Storsjö wrote: +_ctime32 +; _ctime32_s replaced by emu +_ctime64 +; _ctime64_s replaced by emu This doesn't look right, we should use .def file to expose those. I noticed a few similar other cases in the patch. In general, we should use as few compatibility tricks possible for ucrtbase as much as since we can depend on those functions being present in runtime. Having something like you're working on was actually the main reason I moved a lot of compatibility code from mingwex into libmsvcrt.a a few years ago. There are more things that could be moved away from mingwex like that. From your other patch, for example, it looks like we may not need mingw variants of printf/scanf family when targetting ucrtbase, so maybe we could even move them to libmsvcrt.a as well. I'm not sure. Yes, those shouldn't be needed any longer. They aren't used by default at all either, unless __USE_MINGW_ANSI_STDIO is defined. If it is, we still use our own routines for safety, but if others are ok with it, we can probably change it. But it might be easier to make each of those changes a separate patch/discussion later, after we've got a first common state merged. Anyway, that doesn't have to block integration of your work, but it'd be nice to take into account when doing design decisions. For this patch, just please review those "replaced by emu" cases since they shouldn't be needed for ucrtbase. Sure, I can try to have a look through those and see if I can figure out what the situation is. // Martin -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
[Mingw-w64-public] [PATCH 1/3] crt: Add a def file for ucrtbase.dll
This def file is originally based on wine's spec file for this DLL, but with manual modifications made on top in the same style as the manual edits in msvcrt.def.in. Signed-off-by: Martin Storsjö--- v3: No changes. --- mingw-w64-crt/Makefile.am| 16 +- mingw-w64-crt/lib-common/ucrtbase.def.in | 2622 ++ 2 files changed, 2630 insertions(+), 8 deletions(-) create mode 100644 mingw-w64-crt/lib-common/ucrtbase.def.in diff --git a/mingw-w64-crt/Makefile.am b/mingw-w64-crt/Makefile.am index d3d5e8c..560e846 100644 --- a/mingw-w64-crt/Makefile.am +++ b/mingw-w64-crt/Makefile.am @@ -608,7 +608,7 @@ lib32_libmingwthrd_a_SOURCES = $(src_libmingwthrd) lib32_libmingwthrd_a_CPPFLAGS=$(CPPFLAGS32) $(sysincludes) processed_defs += lib32/msvcrt.def lib32/msvcr80.def lib32/msvcr90.def lib32/msvcr90d.def lib32/msvcr100.def lib32/msvcr110.def lib32/msvcr120.def lib32/msvcr120d.def \ - lib32/msvcr120_app.def lib32/msvcp120_app.def + lib32/msvcr120_app.def lib32/msvcp120_app.def lib32/ucrtbase.def endif @@ -617,7 +617,7 @@ include lib32/Makefile.am if !W32API lib32_DATA += lib32/libglut.a lib32/libmsvcp60.a lib32/libmsvcr80.a lib32/libmsvcr90.a lib32/libmsvcr90d.a lib32/libmsvcr100.a \ lib32/libmsvcr110.a lib32/libmsvcr120.a lib32/libmsvcr120d.a lib32/libcrtdll.a \ - lib32/libmsvcr120_app.a lib32/libmsvcp120_app.a + lib32/libmsvcr120_app.a lib32/libmsvcp120_app.a lib32/libucrtbase.a endif @@ -911,7 +911,7 @@ lib64_libmingwthrd_a_CPPFLAGS=$(CPPFLAGS64) $(sysincludes) processed_defs += lib64/msvcrt.def lib64/msvcr80.def lib64/msvcr90.def lib64/msvcr90d.def \ lib64/msvcr100.def lib64/msvcr110.def lib64/msvcr120.def lib64/msvcr120d.def \ - lib64/msvcr120_app.def lib64/msvcp120_app.def \ + lib64/msvcr120_app.def lib64/msvcp120_app.def lib64/ucrtbase.def \ lib64/advapi32.def lib64/clbcatq.def lib64/kernel32.def lib64/ole32.def \ lib64/oleaut32.def lib64/user32.def lib64/ws2_32.def @@ -922,7 +922,7 @@ include lib64/Makefile.am if !W32API lib64_DATA += lib64/libmsvcp60.a lib64/libmsvcr80.a lib64/libmsvcr90.a lib64/libmsvcr100.a lib64/libmsvcr90d.a \ lib64/libmsvcr110.a lib64/libmsvcr120.a lib64/libmsvcr120d.a lib64/libcrtdll.a \ - lib64/libmsvcr120_app.a lib64/libmsvcp120_app.a + lib64/libmsvcr120_app.a lib64/libmsvcp120_app.a lib64/libucrtbase.a endif lib64/libcrtdll.a lib64/libmsvcr80.a: lib64/lib%.a: lib64/%.def @@ -1208,7 +1208,7 @@ libarm32_LIBRARIES += libarm32/libmingwthrd.a libarm32_libmingwthrd_a_SOURCES = $(src_libmingwthrd) libarm32_libmingwthrd_a_CPPFLAGS=$(CPPFLAGSARM32) $(sysincludes) -processed_defs += libarm32/msvcrt.def libarm32/msvcr80.def libarm32/msvcr90.def libarm32/msvcr90d.def libarm32/msvcr100.def libarm32/msvcr110.def \ +processed_defs += libarm32/msvcrt.def libarm32/msvcr80.def libarm32/msvcr90.def libarm32/msvcr90d.def libarm32/msvcr100.def libarm32/msvcr110.def libarm32/ucrtbase.def \ libarm32/advapi32.def libarm32/clbcatq.def libarm32/kernel32.def libarm32/ole32.def libarm32/oleaut32.def \ libarm32/user32.def libarm32/ws2_32.def @@ -1217,7 +1217,7 @@ endif include libarm32/Makefile.am if !W32API -libarm32_DATA += libarm32/libmsvcp60.a libarm32/libmsvcr110.a +libarm32_DATA += libarm32/libmsvcp60.a libarm32/libmsvcr110.a libarm32/libucrtbase.a endif # combine these two rules with the ones for lib64 @@ -1459,7 +1459,7 @@ libarm64_LIBRARIES += libarm64/libmingwthrd.a libarm64_libmingwthrd_a_SOURCES = $(src_libmingwthrd) libarm64_libmingwthrd_a_CPPFLAGS=$(CPPFLAGSARM64) $(sysincludes) -processed_defs += libarm64/msvcrt.def \ +processed_defs += libarm64/msvcrt.def libarm64/ucrtbase.def \ libarm64/advapi32.def libarm64/clbcatq.def libarm64/kernel32.def libarm64/ole32.def libarm64/oleaut32.def \ libarm64/user32.def libarm64/ws2_32.def @@ -1468,7 +1468,7 @@ endif include libarm64/Makefile.am if !W32API -#libarm64_DATA += libarm64/libmsvcp60.a libarm64/libmsvcr110.a +libarm64_DATA += libarm64/libucrtbase.a endif libarm64/libcrtdll.a libarm64/libmsvcr80.a: libarm64/lib%.a: libarm64/%.def diff --git a/mingw-w64-crt/lib-common/ucrtbase.def.in b/mingw-w64-crt/lib-common/ucrtbase.def.in new file mode 100644 index 000..dfcb6cd --- /dev/null +++ b/mingw-w64-crt/lib-common/ucrtbase.def.in @@ -0,0 +1,2622 @@ +LIBRARY "ucrtbase.dll" +EXPORTS + +#include "func.def.in" +#include "msvcrt-common.def.in" + +#ifdef DEF_I386 +_CIacos +_CIasin +_CIatan +_CIatan2 +_CIcos +_CIcosh
[Mingw-w64-public] [PATCH 1/3] crt: Add a def file for ucrtbase.dll
This def file is originally based on wine's spec file for this DLL, but with manual modifications made on top in the same style as the manual edits in msvcrt.def.in. Signed-off-by: Martin Storsjö--- mingw-w64-crt/Makefile.am| 16 +- mingw-w64-crt/lib-common/ucrtbase.def.in | 2622 ++ 2 files changed, 2630 insertions(+), 8 deletions(-) create mode 100644 mingw-w64-crt/lib-common/ucrtbase.def.in diff --git a/mingw-w64-crt/Makefile.am b/mingw-w64-crt/Makefile.am index d3d5e8c..560e846 100644 --- a/mingw-w64-crt/Makefile.am +++ b/mingw-w64-crt/Makefile.am @@ -608,7 +608,7 @@ lib32_libmingwthrd_a_SOURCES = $(src_libmingwthrd) lib32_libmingwthrd_a_CPPFLAGS=$(CPPFLAGS32) $(sysincludes) processed_defs += lib32/msvcrt.def lib32/msvcr80.def lib32/msvcr90.def lib32/msvcr90d.def lib32/msvcr100.def lib32/msvcr110.def lib32/msvcr120.def lib32/msvcr120d.def \ - lib32/msvcr120_app.def lib32/msvcp120_app.def + lib32/msvcr120_app.def lib32/msvcp120_app.def lib32/ucrtbase.def endif @@ -617,7 +617,7 @@ include lib32/Makefile.am if !W32API lib32_DATA += lib32/libglut.a lib32/libmsvcp60.a lib32/libmsvcr80.a lib32/libmsvcr90.a lib32/libmsvcr90d.a lib32/libmsvcr100.a \ lib32/libmsvcr110.a lib32/libmsvcr120.a lib32/libmsvcr120d.a lib32/libcrtdll.a \ - lib32/libmsvcr120_app.a lib32/libmsvcp120_app.a + lib32/libmsvcr120_app.a lib32/libmsvcp120_app.a lib32/libucrtbase.a endif @@ -911,7 +911,7 @@ lib64_libmingwthrd_a_CPPFLAGS=$(CPPFLAGS64) $(sysincludes) processed_defs += lib64/msvcrt.def lib64/msvcr80.def lib64/msvcr90.def lib64/msvcr90d.def \ lib64/msvcr100.def lib64/msvcr110.def lib64/msvcr120.def lib64/msvcr120d.def \ - lib64/msvcr120_app.def lib64/msvcp120_app.def \ + lib64/msvcr120_app.def lib64/msvcp120_app.def lib64/ucrtbase.def \ lib64/advapi32.def lib64/clbcatq.def lib64/kernel32.def lib64/ole32.def \ lib64/oleaut32.def lib64/user32.def lib64/ws2_32.def @@ -922,7 +922,7 @@ include lib64/Makefile.am if !W32API lib64_DATA += lib64/libmsvcp60.a lib64/libmsvcr80.a lib64/libmsvcr90.a lib64/libmsvcr100.a lib64/libmsvcr90d.a \ lib64/libmsvcr110.a lib64/libmsvcr120.a lib64/libmsvcr120d.a lib64/libcrtdll.a \ - lib64/libmsvcr120_app.a lib64/libmsvcp120_app.a + lib64/libmsvcr120_app.a lib64/libmsvcp120_app.a lib64/libucrtbase.a endif lib64/libcrtdll.a lib64/libmsvcr80.a: lib64/lib%.a: lib64/%.def @@ -1208,7 +1208,7 @@ libarm32_LIBRARIES += libarm32/libmingwthrd.a libarm32_libmingwthrd_a_SOURCES = $(src_libmingwthrd) libarm32_libmingwthrd_a_CPPFLAGS=$(CPPFLAGSARM32) $(sysincludes) -processed_defs += libarm32/msvcrt.def libarm32/msvcr80.def libarm32/msvcr90.def libarm32/msvcr90d.def libarm32/msvcr100.def libarm32/msvcr110.def \ +processed_defs += libarm32/msvcrt.def libarm32/msvcr80.def libarm32/msvcr90.def libarm32/msvcr90d.def libarm32/msvcr100.def libarm32/msvcr110.def libarm32/ucrtbase.def \ libarm32/advapi32.def libarm32/clbcatq.def libarm32/kernel32.def libarm32/ole32.def libarm32/oleaut32.def \ libarm32/user32.def libarm32/ws2_32.def @@ -1217,7 +1217,7 @@ endif include libarm32/Makefile.am if !W32API -libarm32_DATA += libarm32/libmsvcp60.a libarm32/libmsvcr110.a +libarm32_DATA += libarm32/libmsvcp60.a libarm32/libmsvcr110.a libarm32/libucrtbase.a endif # combine these two rules with the ones for lib64 @@ -1459,7 +1459,7 @@ libarm64_LIBRARIES += libarm64/libmingwthrd.a libarm64_libmingwthrd_a_SOURCES = $(src_libmingwthrd) libarm64_libmingwthrd_a_CPPFLAGS=$(CPPFLAGSARM64) $(sysincludes) -processed_defs += libarm64/msvcrt.def \ +processed_defs += libarm64/msvcrt.def libarm64/ucrtbase.def \ libarm64/advapi32.def libarm64/clbcatq.def libarm64/kernel32.def libarm64/ole32.def libarm64/oleaut32.def \ libarm64/user32.def libarm64/ws2_32.def @@ -1468,7 +1468,7 @@ endif include libarm64/Makefile.am if !W32API -#libarm64_DATA += libarm64/libmsvcp60.a libarm64/libmsvcr110.a +libarm64_DATA += libarm64/libucrtbase.a endif libarm64/libcrtdll.a libarm64/libmsvcr80.a: libarm64/lib%.a: libarm64/%.def diff --git a/mingw-w64-crt/lib-common/ucrtbase.def.in b/mingw-w64-crt/lib-common/ucrtbase.def.in new file mode 100644 index 000..dfcb6cd --- /dev/null +++ b/mingw-w64-crt/lib-common/ucrtbase.def.in @@ -0,0 +1,2622 @@ +LIBRARY "ucrtbase.dll" +EXPORTS + +#include "func.def.in" +#include "msvcrt-common.def.in" + +#ifdef DEF_I386 +_CIacos +_CIasin +_CIatan +_CIatan2 +_CIcos +_CIcosh +_CIexp +_CIfmod