Markus Trenkwalder wrote:
Hi list,
checked out vim-7.1a.001 today from svn (#263) and tried to compile it
with mingw-gcc and got the following error:
----8<----
$ make -f Make_ming.mak
gcc -c -Iproto -DWIN32 -DWINVER=0x0400 -D_WIN32_WINNT=0x0400
-DHAVE_PATHDEF -DFEAT_BIG -DHAVE_GETTEXT -DHAVE_LOCALE_H
-DDYNAMIC_GETTEXT -DFEAT_CSCOPE -DFEAT_NETBEANS_INTG -DFEAT_GUI_W32
-DFEAT_CLIPBOARD -DFEAT_MBYTE -DFEAT_MBYTE_IME -DDYNAMIC_IME
-DDYNAMIC_ICONV -pipe -w -march=i386 -Wall -O3 -fomit-frame-pointer
-freg-struct-return -s gui_w32.c -o gobj/gui_w32.o
gui_w32.c:236: error: redefinition of `struct tagNMTTDISPINFOA'
gui_w32.c:246: error: redefinition of `struct tagNMTTDISPINFOW'
make: *** [gobj/gui_w32.o] Error 1
----8<----
My naive solution to this problem is:
----8<----
--- src/gui_w32.c.000 Mon May 7 08:26:54 2007
+++ src/gui_w32.c Mon May 7 07:01:09 2007
@@ -232,7 +232,7 @@
LPARAM lParam;
} NMTTDISPINFO_NEW;
-#ifndef LPNMTTDISPINFO
+#if !defined(LPNMTTDISPINFO) && !defined(TOOLTIPTEXTA)
typedef struct tagNMTTDISPINFOA {
NMHDR hdr;
LPSTR lpszText;
----8<----
Regards
Markus
You're not the first; there seems to have been a f*ckup in the svn commit
lately. I suggest you scrap your existing 7.1a sources and restart from
scratch, by downloading the 7.1a.000 sources then applying the 7.1a.001 patch.
Here are the files whose download I recommend:
1) the unpatched archives
http://ftp.vim.org/pub/vim/unstable/unix/vim-7.1a.tar.bz2
http://ftp.vim.org/pub/vim/unstable/extra/vim-7.1a-extra.tar.gz
http://ftp.vim.org/pub/vim/unstable/extra/vim-7.1a-lang.tar.gz
The first one is not a typo: even for Windows, I recommend the *Unix* + extra
+ lang sources. Together, they have exactly one copy of every source file
needed to compile Vim for *any* platform including Windows.
Unpack them on top of each other at what will become your Vim directory "for
compiling", maybe something like D:\build\vim : they will create a subfolder
"vim71a" and place all the sources in it, creating subfolders as needed.
I don't know if you have a bz2 decompresser program, or if your version of
"patch" will accept the patch format. In both cases, MinGW may or may not
offer the necessary packages (look there first) but I know Cygwin does. (Even
WinZip knows about the .tar and .gz formats.)
2) the patch
http://ftp.vim.org/pub/vim/unstable/patches/7.1a/7.1a.001
Download it (and optionally its sibling files README MD5 and MD5SUMS) into a
newly-created subfolder named (in my example) D:\build\vim\vim71a\patches then
apply it by using (IIUC)
D:
cd \build\vim\vim70
patch -p0 <patches\7.1a.001
See details at http://users.skynet.be/antoine.mechelynck/vim/compile.htm but
replace everywhere the directory name .../vim70/... by .../vim71a/..., even in
the name of what will become your "production" 7.1a $VIMRUNTIME after
compiling and installing.
I used Cygwin gcc and Make_cyg.mak but using MingGW and Make_ming.mak is not
very different. I trust you will know what to change in the procedure to cater
for any differences between them.
Best regards,
Tony.
--
"All snakes who wish to remain in Ireland will please raise their right
hands."
-- Saint Patrick