2008/12/10 John Marriott <[EMAIL PROTECTED]> > I have recently moved to Vista x64 and I'm having troubling compiling a > 64-bit version of gvim. I downloaded the MinGW-x64 packages > (mingw-w64-bin_x86_64-mingw_20081123.zip) along with the MinGW-x86 > version of make (mingw32-make-3.81-20080326-2.tar.gz). >
I ported Vim to Win64, but so far I've only tried it on the Microsoft VC2005 and VC2008 compilers: http://code.google.com/p/vim-win3264/ > Now the make fails when compiling if_ole.cpp with this error in included > header if_ole.h: > <snip> > In file included from if_ole.cpp:43: > if_ole.h:50: error: 'interface' does not name a type > if_ole.cpp: In member function 'virtual HRESULT CVim::GetHwnd(UINT*)': > if_ole.cpp:299: error: cast from 'HWND__*' to 'UINT' loses precision > make: *** [gobj/if_ole.o] Error 1 > make: Target `gvim.exe' not remade because of errors. > make: Leaving directory > `C:/Users/John/Documents/Software/Utility/Vim/72/vim72/src' > > ... > > gvimext.cpp: In member function 'virtual HRESULT > CShellExtClassFactory::CreateInstance(IUnknown*, const IID&, void**)': > gvimext.cpp:432: error: cannot allocate an object of abstract type > 'CShellExt' > gvimext.h:112: note: because the following virtual functions are pure > within 'CShellExt': > c:\program > > files\gcc\bin\../lib/gcc/x86_64-pc-mingw32/4.4.0/../../../../x86_64-pc-mingw32/include/shlobj.h:215: > note: virtual HRESULT IContextMenu::GetCommandString(UINT_PTR, > UINT, UINT*, CHAR*, UINT) > make[1]: *** [gvimext.o] Error 1 > windres --input-format=rc --output-format=coff -DMING gvimext_ming.rc -o > gvimext.res > make[1]: Target `all' not remade because of errors. > make[1]: Leaving directory > `C:/Users/John/Documents/Software/Utility/Vim/72/vim72/src/GvimExt' > make: *** [GvimExt/gvimext.dll] Error 2 > make: Target `all' not remade because of errors. > make: Leaving directory > `C:/Users/John/Documents/Software/Utility/Vim/72/vim72/src' > </snip> > The signature in your shlobj.h differs in the 4th parameter from the one in gvimext.h: CHAR* versus LPSTR. Those two typedefs should resolve to the same thing, but presumably don't in the mingw-x64 environment. I'm writing this on a Mac and I don't have the Microsoft SDK handy right now, but the MSDN documentation for IContextMenu::GetCommandString [1] says LPSTR, not CHAR* [1] http://msdn.microsoft.com/en-us/library/bb776094(VS.85).aspx Note that turning off all optimizations makes no difference. > > If I remove the need for OLE from the build I get a gvim.exe, but it > doesn't run. It starts up and then hangs chewing up 50% CPU on my Intel > Core 2 Duo. Process Explorer says that it's sitting in kernel function: > > expinterlockedflushslist > > Now, the interesting bit. If I use Visual Studio 2008 Express with the > SDK addon to build a 64-bit version of gvim, I don't get any errors on > if_ole.h and I get a working copy of gvim.exe. > > Has anyone else tried this? > Trying the mingw-x64 build has been on my long todo list for a while, but never floated to the top. -- /George V. Reilly [EMAIL PROTECTED] http://www.georgevreilly.com/blog http://blogs.cozi.com/tech --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_dev" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---