Re: [Mingw-w64-public] Runtime for Cygwin
2013/6/5 dw > > > When using latest mingw-w64 runtime from trunk for Cygwin I have > > error: http://pastebin.com/9WVgE1Gu > > I would like to experiment with some alternate solutions to what ktietz > proposed, but I need to be sure I understand what is going wrong. > > My attempts to reproduce the problem have not been successful. Can you > produce a small sample? > > Try to get latest trunk version of mingw-w64 and build runtime for Cygwin. Then Install new builded runtime into Cygwin and try to build Cygwin.dll. This error is only on my 64-bit build (gcc-4.8.0 or gcc-4.8.1) Regards, Alexey. -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] Runtime for Cygwin
> When using latest mingw-w64 runtime from trunk for Cygwin I have > error: http://pastebin.com/9WVgE1Gu I would like to experiment with some alternate solutions to what ktietz proposed, but I need to be sure I understand what is going wrong. My attempts to reproduce the problem have not been successful. Can you produce a small sample? dw -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] Runtime for Cygwin
You missed the hunk for winnt.h header. Kai -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] __faststorefence and mingw-w64 philosophy
2013/6/4 dw : > >>> I think option #3 is that one I prefer too. Just one thing about >>> SSE-instruction. For 64-bit we can assume that SSE has to be present >>> in any case. Just for 32-bit we should check in headers for the >>> __SSE__ macro, and in the intrinsic-function (none-inline) we should >>> default to none-SSE version. >> __SSE__ should always be defined with x86_64 so just checking for >> __SSE__ might be simpler and will give the fastest version. >> >> Thus the same definition could be used for both inline and intrinsic. > > Per MS docs, __faststorefence is only defined for x64. While I assume > it would work, the current winnt.h doesn't define it for x86 and I > wasn't planning to add it. That's a fair point. > Being able to just assume that __SSE__ is defined certainly makes the > code cleaner. The reason I didn't was that it is possible that someone > could be compiling with -mno-sse for some reason. Ignore this? I think we should ignore that somebody uses -mno-sse for x64. First this would be clearly an ABI-breakage, due SSE is mandatory in calling-convention. And secondly, on x64 CPUs base SSE feature-sets we can assume always. > There is a similar question for MemoryBarrier(). The mfence instruction > is SSE2. Check for __SSE2__ or not? Well, not sure here. AFAIR is SSE2 present for all more modern x64 CPUs, but well, here this check might make sense. > dw Kai -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] Runtime for Cygwin
Oh, I am sorry! I change winnt.h bat forgot to click save button) It works now Kai! 2013/6/4 Kai Tietz > You missed the hunk for winnt.h header. > > Kai > > > -- > How ServiceNow helps IT people transform IT departments: > 1. A cloud service to automate IT design, transition and operations > 2. Dashboards that offer high-level views of enterprise services > 3. A single system of record for all IT processes > http://p.sf.net/sfu/servicenow-d2d-j > ___ > Mingw-w64-public mailing list > Mingw-w64-public@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/mingw-w64-public > -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] Runtime for Cygwin
2013/6/4 Kai Tietz > Hmm, could you try if the following patch solves your problem? > > Kai > > Index: winnt.h > === > --- winnt.h(Revision 5878) > +++ winnt.h(Arbeitskopie) > @@ -1542,10 +1542,10 @@ extern "C" { > VOID __stosq(PDWORD64 Destination,DWORD64 Value,SIZE_T Count); > > #ifndef __CRT__NO_INLINE > -__CRT_INLINE __buildstos(__stosb, BYTE) > -__CRT_INLINE __buildstos(__stosw, WORD) > -__CRT_INLINE __buildstos(__stosd, DWORD) > -__CRT_INLINE __buildstos(__stosq, DWORD64) > +__CRT_INLINE __buildstos(__stosb, VOID, PBYTE, BYTE, SIZE_T) > +__CRT_INLINE __buildstos(__stosw, VOID, PWORD, WORD, SIZE_T) > +__CRT_INLINE __buildstos(__stosd, VOID, PDWORD, DWORD, SIZE_T) > +__CRT_INLINE __buildstos(__stosq, VOID, PDWORD64, DWORD64, SIZE_T) > #endif /* __CRT__NO_INLINE */ > > #define MultiplyHigh __mulh > Index: psdk_inc/intrin-mac.h > === > --- psdk_inc/intrin-mac.h(Revision 5878) > +++ psdk_inc/intrin-mac.h(Arbeitskopie) > @@ -15,7 +15,8 @@ > FunctionName: Any valid function name > DataType: BYTE, WORD, DWORD or DWORD64 */ > > -#define __buildstos(x, y) void x(y *Dest, y Data, size_t Count) \ > +#define __buildstos(x, r0, t0, t1, t2) \ > +r0 x(t0 Dest, t1 Data, t2 Count) \ > { \ > __asm__ __volatile__ ("rep stos%z[Data]" \ >: /* no outputs */ \ > > Hi, Kai! I test your patch but without success. I have error: make[3]: Entering directory '/work/build/runtime/x86_64-pc-cygwin/winsup/cygwin' ../../../../../Cygwin32/winsup/cygwin/gendef --cpu=x86_64 --output-def=cygwin.def --tlsoffsets=../../../../../Cygwin32/winsup/cygwin/tlsoffsets64.h ../../../../../Cygwin32/winsup/cygwin/x86_64.din ../../../../../Cygwin32/winsup/cygwin/common.din ../../../../../Cygwin32/winsup/cygwin/mkglobals_h ../../../../../Cygwin32/winsup/cygwin/globals.cc > globals.h c++wrap -O2 -g -fno-rtti -fno-exceptions -Wall -Wstrict-aliasing -Wwrite-strings -fno-common -pipe -fbuiltin -fmessage-length=0 -MMD -Werror -fmerge-constants -ftracer -mcmodel=small -c -o _cygwin_crt0_common.o ../../../../../Cygwin32/winsup/cygwin/lib/_cygwin_crt0_common.cc In file included from /usr/include/w32api/windef.h:139:0, from /usr/include/w32api/windows.h:69, from ../../../../../Cygwin32/winsup/cygwin/winlean.h:52, from ../../../../../Cygwin32/winsup/cygwin/winsup.h:76, from ../../../../../Cygwin32/winsup/cygwin/lib/_cygwin_crt0_common.cc:12: /usr/include/w32api/winnt.h:1545:39: error: macro "__buildstos" requires 5 arguments, but only 2 given __CRT_INLINE __buildstos(__stosb, BYTE) ^ /usr/include/w32api/winnt.h:1546:39: error: macro "__buildstos" requires 5 arguments, but only 2 given __CRT_INLINE __buildstos(__stosw, WORD) ^ /usr/include/w32api/winnt.h:1547:40: error: macro "__buildstos" requires 5 arguments, but only 2 given __CRT_INLINE __buildstos(__stosd, DWORD) ^ /usr/include/w32api/winnt.h:1548:42: error: macro "__buildstos" requires 5 arguments, but only 2 given __CRT_INLINE __buildstos(__stosq, DWORD64) ^ In file included from /usr/include/w32api/windef.h:139:0, from /usr/include/w32api/windows.h:69, from ../../../../../Cygwin32/winsup/cygwin/winlean.h:52, from ../../../../../Cygwin32/winsup/cygwin/winsup.h:76, from ../../../../../Cygwin32/winsup/cygwin/lib/_cygwin_crt0_common.cc:12: /usr/include/w32api/winnt.h:1545:14: error: ‘__buildstos’ does not name a type __CRT_INLINE __buildstos(__stosb, BYTE) ^ ../../../../../Cygwin32/winsup/cygwin/../Makefile.common:43: recipe for target '_cygwin_crt0_common.o' failed make[3]: *** [_cygwin_crt0_common.o] Error 1 make[3]: Leaving directory '/work/build/runtime/x86_64-pc-cygwin/winsup/cygwin' Makefile:82: recipe for target 'cygwin' failed make[2]: *** [cygwin] Error 1 Regards, Alexey. -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
Re: [Mingw-w64-public] Runtime for Cygwin
Hmm, could you try if the following patch solves your problem? Kai Index: winnt.h === --- winnt.h(Revision 5878) +++ winnt.h(Arbeitskopie) @@ -1542,10 +1542,10 @@ extern "C" { VOID __stosq(PDWORD64 Destination,DWORD64 Value,SIZE_T Count); #ifndef __CRT__NO_INLINE -__CRT_INLINE __buildstos(__stosb, BYTE) -__CRT_INLINE __buildstos(__stosw, WORD) -__CRT_INLINE __buildstos(__stosd, DWORD) -__CRT_INLINE __buildstos(__stosq, DWORD64) +__CRT_INLINE __buildstos(__stosb, VOID, PBYTE, BYTE, SIZE_T) +__CRT_INLINE __buildstos(__stosw, VOID, PWORD, WORD, SIZE_T) +__CRT_INLINE __buildstos(__stosd, VOID, PDWORD, DWORD, SIZE_T) +__CRT_INLINE __buildstos(__stosq, VOID, PDWORD64, DWORD64, SIZE_T) #endif /* __CRT__NO_INLINE */ #define MultiplyHigh __mulh Index: psdk_inc/intrin-mac.h === --- psdk_inc/intrin-mac.h(Revision 5878) +++ psdk_inc/intrin-mac.h(Arbeitskopie) @@ -15,7 +15,8 @@ FunctionName: Any valid function name DataType: BYTE, WORD, DWORD or DWORD64 */ -#define __buildstos(x, y) void x(y *Dest, y Data, size_t Count) \ +#define __buildstos(x, r0, t0, t1, t2) \ +r0 x(t0 Dest, t1 Data, t2 Count) \ { \ __asm__ __volatile__ ("rep stos%z[Data]" \ : /* no outputs */ \ -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j ___ 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] Add winstring.h, hstring.idl and corresponding runtimeobject imports
Le 04/06/2013 13:34, Rafaël Carré a écrit : > --- > mingw-w64-crt/Makefile.am | 6 ++- > mingw-w64-crt/lib32/runtimeobject.def | 25 > mingw-w64-crt/lib64/runtimeobject.def | 29 + > mingw-w64-headers/include/hstring.h | 61 +++ > mingw-w64-headers/include/hstring.idl | 27 > mingw-w64-headers/include/winstring.h | 77 > +++ > 6 files changed, 223 insertions(+), 2 deletions(-) > create mode 100644 mingw-w64-crt/lib32/runtimeobject.def > create mode 100644 mingw-w64-crt/lib64/runtimeobject.def > create mode 100644 mingw-w64-headers/include/hstring.h > create mode 100644 mingw-w64-headers/include/hstring.idl > create mode 100644 mingw-w64-headers/include/winstring.h Committed with hstring.idl tweak and adding it to Makefile.am/in as r5879. Thank you for your reviews -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
[Mingw-w64-public] [PATCH] Add winstring.h, hstring.idl and corresponding runtimeobject imports
--- mingw-w64-crt/Makefile.am | 6 ++- mingw-w64-crt/lib32/runtimeobject.def | 25 mingw-w64-crt/lib64/runtimeobject.def | 29 + mingw-w64-headers/include/hstring.h | 61 +++ mingw-w64-headers/include/hstring.idl | 27 mingw-w64-headers/include/winstring.h | 77 +++ 6 files changed, 223 insertions(+), 2 deletions(-) create mode 100644 mingw-w64-crt/lib32/runtimeobject.def create mode 100644 mingw-w64-crt/lib64/runtimeobject.def create mode 100644 mingw-w64-headers/include/hstring.h create mode 100644 mingw-w64-headers/include/hstring.idl create mode 100644 mingw-w64-headers/include/winstring.h diff --git a/mingw-w64-crt/Makefile.am b/mingw-w64-crt/Makefile.am index 4ce1258..71c9f15 100644 --- a/mingw-w64-crt/Makefile.am +++ b/mingw-w64-crt/Makefile.am @@ -542,7 +542,8 @@ lib32_DATA = \ lib32/libxapofx.a lib32/libx3daudio.a lib32/libd3dx9.a \ lib32/libd3dx10.a lib32/libd3dx11.a lib32/libd3dcsxd.a \ lib32/libd3dcompiler.alib32/libwinhttp.alib32/libmsvcr110.a \ - lib32/libdevmgr.a lib32/libdevobj.a lib32/libdevrtl.a + lib32/libdevmgr.a lib32/libdevobj.a lib32/libdevrtl.a\ + lib32/libruntimeobject.a if ! W32API lib32_DATA += lib32/libglut.a @@ -1043,7 +1044,8 @@ lib64_DATA = \ lib64/libxinput.a lib64/libxaudio.a lib64/libxaudiod.a \ lib64/libxapofx.a lib64/libx3daudio.a lib64/libd3dx9.a \ lib64/libd3dx10.a lib64/libd3dx11.a lib64/libd3dcsxd.a \ - lib64/libd3dcompiler.alib64/libwinhttp.alib64/libmsvcr110.a + lib64/libd3dcompiler.alib64/libwinhttp.alib64/libmsvcr110.a \ + lib64/libruntimeobject.a lib64/libcrtdll.a lib64/libmsvcrt.a lib64/libmsvcr80.a: lib64/lib%.a: lib64/%.def $(DTDEF64) $< --dllname $*.dll diff --git a/mingw-w64-crt/lib32/runtimeobject.def b/mingw-w64-crt/lib32/runtimeobject.def new file mode 100644 index 000..c49fc51 --- /dev/null +++ b/mingw-w64-crt/lib32/runtimeobject.def @@ -0,0 +1,25 @@ +LIBRARY "api-ms-win-core-winrt-string-l1-1-0.dll" +EXPORTS +HSTRING_UserFree@8 +HSTRING_UserMarshal@12 +HSTRING_UserSize@12 +HSTRING_UserUnmarshal@12 +WindowsCompareStringOrdinal@12 +WindowsConcatString@12 +WindowsCreateString@12 +WindowsCreateStringReference@16 +WindowsDeleteString@4 +WindowsDeleteStringBuffer@4 +WindowsDuplicateString@8 +WindowsGetStringLen@4 +WindowsGetStringRawBuffer@8 +WindowsInspectString@24 +WindowsIsStringEmpty@4 +WindowsPreallocateStringBuffer@12 +WindowsPromoteStringBuffer@8 +WindowsReplaceString@16 +WindowsStringHasEmbeddedNull@8 +WindowsSubstring@12 +WindowsSubstringWithSpecifiedLength@16 +WindowsTrimStringEnd@12 +WindowsTrimStringStart@12 diff --git a/mingw-w64-crt/lib64/runtimeobject.def b/mingw-w64-crt/lib64/runtimeobject.def new file mode 100644 index 000..c211978 --- /dev/null +++ b/mingw-w64-crt/lib64/runtimeobject.def @@ -0,0 +1,29 @@ +LIBRARY "api-ms-win-core-winrt-string-l1-1-0.dll" +EXPORTS +HSTRING_UserFree +HSTRING_UserFree64 +HSTRING_UserMarshal +HSTRING_UserMarshal64 +HSTRING_UserSize +HSTRING_UserSize64 +HSTRING_UserUnmarshal +HSTRING_UserUnmarshal64 +WindowsCompareStringOrdinal +WindowsConcatString +WindowsCreateString +WindowsCreateStringReference +WindowsDeleteString +WindowsDeleteStringBuffer +WindowsDuplicateString +WindowsGetStringLen +WindowsGetStringRawBuffer +WindowsInspectString +WindowsIsStringEmpty +WindowsPreallocateStringBuffer +WindowsPromoteStringBuffer +WindowsReplaceString +WindowsStringHasEmbeddedNull +WindowsSubstring +WindowsSubstringWithSpecifiedLength +WindowsTrimStringEnd +WindowsTrimStringStart diff --git a/mingw-w64-headers/include/hstring.h b/mingw-w64-headers/include/hstring.h new file mode 100644 index 000..587dfcd --- /dev/null +++ b/mingw-w64-headers/include/hstring.h @@ -0,0 +1,61 @@ +/*** Autogenerated by WIDL 1.5.19 from include/hstring.idl - Do not edit ***/ + +#ifndef __REQUIRED_RPCNDR_H_VERSION__ +#define __REQUIRED_RPCNDR_H_VERSION__ 475 +#endif + +#include +#include + +#ifndef COM_NO_WINDOWS_H +#include +#include +#endif + +#ifndef __hstring_h__ +#define __hstring_h__ + +/* Forward declarations */ + +/* Headers for imported files */ + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +#if 0 +typedef struct HSTRING__ { +int unused; +} HSTRING__; +typedef HSTRING__ *HSTRING; +#endif + + typedef struct HSTRING__{ +int unused; + } HSTRING__; + typedef __RPC_unique_pointer HSTRING__* HSTRING; + + typedef struct HSTRING_HEADER { +__C89_NAMELESS union { + PVOID Reserved1; +#ifdef _WIN64 + char Reserved2[24]; +#else + char Reserved2[20]; +#endif +} Reserved; + } HSTRING_HEADER; + +DECLARE_HANDLE(HSTRING_BUFFER); +/* Begin additional prototypes for all interfaces */ + + +/* End additional prototypes */ + +#ifdef __cplusplus +} +#endif + +#endif /* __hstring_h
Re: [Mingw-w64-public] Is there a way to control the output file format of windres directly during building wx?
You can setup wrapper scripts to do this sort of thing. Many projects take this approach. Personally I prefer doing this and being able to use multilib toolchains, but each to their own! Sample contents would be something like: #!/bin/bash exec /mingw/bin/windres -F pe-i386 "${@}" On Tue, Jun 4, 2013 at 9:08 AM, Ruben Van Boxem wrote: > 2013/6/4 zhangxinghai > >> hello >> I find there is no way to control the output file format of windres >> directly when I build wx. >> If I use mingw32-make under cmd,I must manually modify makefile.gcc,add >> rcflags to >> every windres command. >> If I use msys,I also have no way to directly do that using configure, >> ../../configure --host=i686-w64-mingw32 --enable-shared --disable-debug >> --disable-monolithic >> --enable-unicode CXXFLAGS="-pipe -m32 fno-keep-inline-dllexport -Os" >> LDFLAGS=-m32 CFLAGS=-m32 >> RCFLAGS="-F pe-i386" >> the basedll_version_rc.o's format is pe-x86-64,I can not find any windres >> flag in that make file controlling >> file format.So I think I must manually modify makefile . >> It is strange that RCFLAGS is not the standard flag in gcc like >> CXXFLAGS,LDFLAGS,CFLAGS etc,why Wx omit this flag? >> Or may be another method to reach the same result >> Thanks >> > > This is one of the reasons I am against multilib GCC: build systems don't > know how to handle every tiny detail. > > I would strongly suggest using two seperate toolchains for 32 and 64-bit, > which removes the problem, as everything will do the correct thing. No need > for -m32 added everywhere, or anything else like RCFLAGS. > > Ruben > > >> >> >> >> >> >> -- >> How ServiceNow helps IT people transform IT departments: >> 1. A cloud service to automate IT design, transition and operations >> 2. Dashboards that offer high-level views of enterprise services >> 3. A single system of record for all IT processes >> http://p.sf.net/sfu/servicenow-d2d-j >> ___ >> Mingw-w64-public mailing list >> Mingw-w64-public@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/mingw-w64-public >> >> > > > -- > How ServiceNow helps IT people transform IT departments: > 1. A cloud service to automate IT design, transition and operations > 2. Dashboards that offer high-level views of enterprise services > 3. A single system of record for all IT processes > http://p.sf.net/sfu/servicenow-d2d-j > ___ > Mingw-w64-public mailing list > Mingw-w64-public@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/mingw-w64-public > > -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j___ 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] Add winstring.h and corresponding runtimeobject imports
Thanks for adding the hstring.h header. Nevertheless there is still one nit. In winstring.h you need of course to include now hstring.h header. Cheers, Kai -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j ___ 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] Add winstring.h and corresponding runtimeobject imports
Hello, Le 03/06/2013 16:51, JonY a écrit :> On 6/3/2013 22:18, Rafaël Carré wrote: > >> new file mode 100644 >> index 000..c49fc51 >> --- /dev/null >> +++ b/mingw-w64-crt/lib32/runtimeobject.def >> @@ -0,0 +1,25 @@ >> +LIBRARY "api-ms-win-core-winrt-string-l1-1-0.dll" > > >> new file mode 100644 >> index 000..c211978 >> --- /dev/null >> +++ b/mingw-w64-crt/lib64/runtimeobject.def >> @@ -0,0 +1,29 @@ >> +LIBRARY "api-ms-win-core-winrt-string-l1-1-0.dll" >> > > Are you sure about these? The library names do not match the DLL, these > DLLs are internal versioned copies. MSDN fails to mention runtimeobject.lib for Windows*String functions, like it does for Ro* functions : http://msdn.microsoft.com/en-us/library/br229855(v=vs.85).aspx , but it's the right import lib. See for example last comment on http://blogs.interknowlogy.com/2012/04/11/how-to-create-a-winrt-wrl-c-component-from-scratch-that-can-be-consumed-by-net-components/ However there is no runtimeobject.dll, the functions defined in this import lib actually come from several DLLs, I confirmed this by building a test exe with Visual Studio that uses Windows*String functions, and my binary explicitely mentions this DLL. i686-w64-mingw32-objdump -x extract: There is an import table in .rdata at 0x438840 The Import Tables (interpreted .rdata section contents) vma:HintTime Forward DLL First Table Stamp ChainName Thunk 00038840 000388e0 00038b0e 0002f000 00038890 000389f0 00039a74 0002f110 DLL Name: api-ms-win-core-winrt-string-l1-1-0.dll vma: Hint/Ord Member-Name Bound-To 399b8 7 WindowsCreateStringReference 3999c 12 WindowsGetStringRawBuffer 39a56 4 WindowsCompareStringOrdinal 39986 8 WindowsDeleteString 39a24 10 WindowsDuplicateString 39a0e 6 WindowsCreateString 39a3e 14 WindowsIsStringEmpty 000388a4 000389e4 00039a9c 0002f104 DLL Name: api-ms-win-core-winrt-l1-1-0.dll vma: Hint/Ord Member-Name Bound-To 399d8 2 RoGetApartmentIdentifier 399f4 1 RoGetActivationFactory Note, I'll add Ro* functions to this import lib in a forthcoming patch (these functions are imported from a different DLL as seen above). Le 03/06/2013 16:43, Kai Tietz a écrit : > 2013/6/3 Rafaël Carré : >> diff --git a/mingw-w64-headers/include/winstring.h >> b/mingw-w64-headers/include/winstring.h >> new file mode 100644 >> index 000..b395cef >> --- /dev/null >> +++ b/mingw-w64-headers/include/winstring.h >> @@ -0,0 +1,202 @@ >> +/** >> + * This file has no copyright assigned and is placed in the Public Domain. >> + * This file is part of the mingw-w64 runtime package. >> + * No warranty is given; refer to the file DISCLAIMER.PD within this >> package. >> + */ >> +#ifndef __WINSTRING_H__ >> +#define __WINSTRING_H__ >> + >> +#include >> +#include > > Here we need to include additionally rpc.h header. Also we need here > to include winapifamily.h. I added rpc.h to winstring.h but I am not sure about winapifamily.h, as these functions are available on both desktop and store apps. > Also so some parts from this header should be put into hstring.h > header AFAIC read, it seems to be an idl-based generated file, so > this can come later ... Oops I missed that header. HSTRING functions are all in winstring.h though. >> +#if _WIN32_WINNT >= _WIN32_WINNT_WIN8 > Hmm, true that API is Windows8 based, but do we really need to add > here this guard ... anyway it won't hurt AFAICS. If someone targets Windows 7 using this code it would build and link properly but fail at runtime due to missing libs, so with this guard he will get at least a compilation warning about missing prototypes. >> + >> +void __stdcall HSTRING_UserFree( >> + unsigned long *pFlags, >> + HSTRING *ppidl >> +); > Please write prototypes within one line. Also don't use __stdcall > here. Better use __RPC_USER instead. All these HSTRING_... functions > are RPC-stuff, so it should fit AFAICS. Write it like eg "void > __RPC_USER HSTRING_UserFree(ULONG *pFlags, HSTRING *ppidl);' Done. New patch attached which leaves these questions: - is winapifamily.h really needed? - is rpc.h needed for hstring.h too? Thanks, >From 8a7237c5ba1dd4941e4671fd0ea7db3112ece451 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafa=C3=ABl=20Carr=C3=A9?= Date: Mon, 3 Jun 2013 16:12:35 +0200 Subject: [PATCH] Add winstring.h and corresponding runtimeobject imports --- mingw-w64-crt/Makefile.am | 6 ++- mingw-w64-crt/lib32/runtimeobject.def | 25 mingw-w64-crt/lib64/runtimeobject.def | 29 + mingw-w64-headers/include/hstring.h | 37 + mingw-w64-headers/include/winstring.h | 76 +++ 5 files changed, 171 insertions(+), 2 deletions(-) creat
Re: [Mingw-w64-public] Is there a way to control the output file format of windres directly during building wx?
2013/6/4 zhangxinghai > hello > I find there is no way to control the output file format of windres > directly when I build wx. > If I use mingw32-make under cmd,I must manually modify makefile.gcc,add > rcflags to > every windres command. > If I use msys,I also have no way to directly do that using configure, > ../../configure --host=i686-w64-mingw32 --enable-shared --disable-debug > --disable-monolithic > --enable-unicode CXXFLAGS="-pipe -m32 fno-keep-inline-dllexport -Os" > LDFLAGS=-m32 CFLAGS=-m32 > RCFLAGS="-F pe-i386" > the basedll_version_rc.o's format is pe-x86-64,I can not find any windres > flag in that make file controlling > file format.So I think I must manually modify makefile . > It is strange that RCFLAGS is not the standard flag in gcc like > CXXFLAGS,LDFLAGS,CFLAGS etc,why Wx omit this flag? > Or may be another method to reach the same result > Thanks > This is one of the reasons I am against multilib GCC: build systems don't know how to handle every tiny detail. I would strongly suggest using two seperate toolchains for 32 and 64-bit, which removes the problem, as everything will do the correct thing. No need for -m32 added everywhere, or anything else like RCFLAGS. Ruben > > > > > > -- > How ServiceNow helps IT people transform IT departments: > 1. A cloud service to automate IT design, transition and operations > 2. Dashboards that offer high-level views of enterprise services > 3. A single system of record for all IT processes > http://p.sf.net/sfu/servicenow-d2d-j > ___ > Mingw-w64-public mailing list > Mingw-w64-public@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/mingw-w64-public > > -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public
[Mingw-w64-public] Is there a way to control the output file format of windres directly during building wx?
hello I find there is no way to control the output file format of windres directly when I build wx. If I use mingw32-make under cmd,I must manually modify makefile.gcc,add rcflags to every windres command. If I use msys,I also have no way to directly do that using configure, ../../configure --host=i686-w64-mingw32 --enable-shared --disable-debug --disable-monolithic --enable-unicode CXXFLAGS="-pipe -m32 fno-keep-inline-dllexport -Os" LDFLAGS=-m32 CFLAGS=-m32 RCFLAGS="-F pe-i386" the basedll_version_rc.o's format is pe-x86-64,I can not find any windres flag in that make file controlling file format.So I think I must manually modify makefile . It is strange that RCFLAGS is not the standard flag in gcc like CXXFLAGS,LDFLAGS,CFLAGS etc,why Wx omit this flag? Or may be another method to reach the same result Thanks -- How ServiceNow helps IT people transform IT departments: 1. A cloud service to automate IT design, transition and operations 2. Dashboards that offer high-level views of enterprise services 3. A single system of record for all IT processes http://p.sf.net/sfu/servicenow-d2d-j___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public