Karsten Hopp 18fa48
To: vim-dev@vim.org
Karsten Hopp 18fa48
Subject: patch 7.1.065 (extra)
Karsten Hopp 18fa48
Fcc: outbox
Karsten Hopp 18fa48
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 18fa48
Mime-Version: 1.0
Karsten Hopp 18fa48
Content-Type: text/plain; charset=ISO-8859-1
Karsten Hopp 18fa48
Content-Transfer-Encoding: 8bit
Karsten Hopp 18fa48
------------
Karsten Hopp 18fa48
Karsten Hopp 18fa48
Patch 7.1.065 (extra)
Karsten Hopp 18fa48
Problem:    Win32: Compilation problem for newer version of w32api.
Karsten Hopp 18fa48
Solution:   Only define __IID_DEFINED__ when needed. (Chris Sutcliffe)
Karsten Hopp 18fa48
Files:	    src/Make_ming.mak, src/iid_ole.c
Karsten Hopp 18fa48
Karsten Hopp 18fa48
Karsten Hopp 18fa48
*** ../vim-7.1.064/src/Make_ming.mak	Thu May 10 19:35:54 2007
Karsten Hopp 18fa48
--- src/Make_ming.mak	Sat Aug 11 14:52:11 2007
Karsten Hopp 18fa48
***************
Karsten Hopp 18fa48
*** 572,579 ****
Karsten Hopp 18fa48
  $(OUTDIR)/if_cscope.o:	if_cscope.c $(INCL) if_cscope.h
Karsten Hopp 18fa48
  	$(CC) -c $(CFLAGS) if_cscope.c -o $(OUTDIR)/if_cscope.o
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  $(OUTDIR)/if_ole.o: if_ole.cpp $(INCL)
Karsten Hopp 18fa48
! 	$(CC) $(CFLAGS) -D__IID_DEFINED__ -c -o $(OUTDIR)/if_ole.o if_ole.cpp
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  $(OUTDIR)/if_ruby.o: if_ruby.c $(INCL)
Karsten Hopp 18fa48
  ifeq (16, $(RUBY))
Karsten Hopp 18fa48
--- 572,580 ----
Karsten Hopp 18fa48
  $(OUTDIR)/if_cscope.o:	if_cscope.c $(INCL) if_cscope.h
Karsten Hopp 18fa48
  	$(CC) -c $(CFLAGS) if_cscope.c -o $(OUTDIR)/if_cscope.o
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
+ # Remove -D__IID_DEFINED__ for newer versions of the w32api
Karsten Hopp 18fa48
  $(OUTDIR)/if_ole.o: if_ole.cpp $(INCL)
Karsten Hopp 18fa48
! 	$(CC) $(CFLAGS) -c -o $(OUTDIR)/if_ole.o if_ole.cpp
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  $(OUTDIR)/if_ruby.o: if_ruby.c $(INCL)
Karsten Hopp 18fa48
  ifeq (16, $(RUBY))
Karsten Hopp 18fa48
*** ../vim-7.1.064/src/iid_ole.c	Sun Jun 13 18:45:30 2004
Karsten Hopp 18fa48
--- src/iid_ole.c	Sat Aug 11 14:57:58 2007
Karsten Hopp 18fa48
***************
Karsten Hopp 18fa48
*** 16,24 ****
Karsten Hopp 18fa48
  extern "C"{
Karsten Hopp 18fa48
  #endif
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  #ifndef __IID_DEFINED__
Karsten Hopp 18fa48
! #define __IID_DEFINED__
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  typedef struct _IID
Karsten Hopp 18fa48
  {
Karsten Hopp 18fa48
--- 16,33 ----
Karsten Hopp 18fa48
  extern "C"{
Karsten Hopp 18fa48
  #endif
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
+ #ifdef __MINGW32__
Karsten Hopp 18fa48
+ # include <w32api.h>
Karsten Hopp 18fa48
+ 
Karsten Hopp 18fa48
+ # if __W32API_MAJOR_VERSION == 3 && __W32API_MINOR_VERSION < 10
Karsten Hopp 18fa48
+    /* This define is missing from older MingW versions of w32api, even though
Karsten Hopp 18fa48
+     * IID is defined. */
Karsten Hopp 18fa48
+ #  define __IID_DEFINED__
Karsten Hopp 18fa48
+ # endif
Karsten Hopp 18fa48
+ #endif
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  #ifndef __IID_DEFINED__
Karsten Hopp 18fa48
! # define __IID_DEFINED__
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  typedef struct _IID
Karsten Hopp 18fa48
  {
Karsten Hopp 18fa48
***************
Karsten Hopp 18fa48
*** 28,39 ****
Karsten Hopp 18fa48
      unsigned char  c[8];
Karsten Hopp 18fa48
  } IID;
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
! #endif // __IID_DEFINED__
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  #ifndef CLSID_DEFINED
Karsten Hopp 18fa48
! #define CLSID_DEFINED
Karsten Hopp 18fa48
  typedef IID CLSID;
Karsten Hopp 18fa48
! #endif // CLSID_DEFINED
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  const IID IID_IVim = {0x0F0BFAE2,0x4C90,0x11d1,{0x82,0xD7,0x00,0x04,0xAC,0x36,0x85,0x19}};
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
--- 37,48 ----
Karsten Hopp 18fa48
      unsigned char  c[8];
Karsten Hopp 18fa48
  } IID;
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
! #endif
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  #ifndef CLSID_DEFINED
Karsten Hopp 18fa48
! # define CLSID_DEFINED
Karsten Hopp 18fa48
  typedef IID CLSID;
Karsten Hopp 18fa48
! #endif
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
  const IID IID_IVim = {0x0F0BFAE2,0x4C90,0x11d1,{0x82,0xD7,0x00,0x04,0xAC,0x36,0x85,0x19}};
Karsten Hopp 18fa48
  
Karsten Hopp 18fa48
*** ../vim-7.1.064/src/version.c	Sat Aug 11 22:22:56 2007
Karsten Hopp 18fa48
--- src/version.c	Sun Aug 12 15:21:34 2007
Karsten Hopp 18fa48
***************
Karsten Hopp 18fa48
*** 668,669 ****
Karsten Hopp 18fa48
--- 668,671 ----
Karsten Hopp 18fa48
  {   /* Add new patch number below this line */
Karsten Hopp 18fa48
+ /**/
Karsten Hopp 18fa48
+     65,
Karsten Hopp 18fa48
  /**/
Karsten Hopp 18fa48
Karsten Hopp 18fa48
-- 
Karsten Hopp 18fa48
I'm writing a book.  I've got the page numbers done.
Karsten Hopp 18fa48
Karsten Hopp 18fa48
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 18fa48
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 18fa48
\\\        download, build and distribute -- http://www.A-A-P.org        ///
Karsten Hopp 18fa48
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///