1
0
forked from aniani/vim

Fixes and improvements for MS-Windows build.

This commit is contained in:
Bram Moolenaar
2010-07-18 21:42:34 +02:00
parent 607cc1e015
commit 69154f22a6
11 changed files with 107 additions and 73 deletions

View File

@@ -272,11 +272,16 @@ This means that Vim will search for the Perl DLL file only when needed. When
you don't use the Perl interface you don't need it, thus you can use Vim you don't use the Perl interface you don't need it, thus you can use Vim
without this DLL file. without this DLL file.
To use the Perl interface the Perl DLL must be in your search path. In a You can download Perl from http://www.perl.org. The one from ActiveState was
console window type "path" to see what directories are used. used for building Vim.
To use the Perl interface the Perl DLL must be in your search path.
If Vim reports it cannot find the perl512.dll, make sure your $PATH includes
the directory where it is localted. The Perl installer normally does that.
In a console window type "path" to see what directories are used.
The name of the DLL must match the Perl version Vim was compiled with. The name of the DLL must match the Perl version Vim was compiled with.
Currently the name is "perl58.dll". That is for Perl 5.8. To know for Currently the name is "perl512.dll". That is for Perl 5.12. To know for
sure edit "gvim.exe" and search for "perl\d*.dll\c". sure edit "gvim.exe" and search for "perl\d*.dll\c".
============================================================================== ==============================================================================

View File

@@ -194,12 +194,20 @@ This means that Vim will search for the Ruby DLL file only when needed. When
you don't use the Ruby interface you don't need it, thus you can use Vim you don't use the Ruby interface you don't need it, thus you can use Vim
without this DLL file. without this DLL file.
You need to install the right version of Ruby for this to work. You can find
the package to download from:
http://www.garbagecollect.jp/ruby/mswin32/en/download/release.html
Currently that is ruby-1.9.1-p429-i386-mswin32.zip
To use the Ruby interface the Ruby DLL must be in your search path. In a To use the Ruby interface the Ruby DLL must be in your search path. In a
console window type "path" to see what directories are used. console window type "path" to see what directories are used.
The name of the DLL must match the Ruby version Vim was compiled with. The name of the DLL must match the Ruby version Vim was compiled with.
Currently the name is "ruby18.dll". That is for Ruby 1.8. To know for sure Currently the name is "msvcrt-ruby191.dll". That is for Ruby 1.9.1. To know
edit "gvim.exe" and search for "ruby\d*.dll\c". for sure edit "gvim.exe" and search for "ruby\d*.dll\c".
If you want to build Vim with Ruby 1.9.1, you need to edit the config.h file
and comment-out the check for _MSC_VER.
============================================================================== ==============================================================================
vim:tw=78:ts=8:ft=help:norl: vim:tw=78:ts=8:ft=help:norl:

View File

@@ -585,9 +585,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
'norevins' options.txt /*'norevins'* 'norevins' options.txt /*'norevins'*
'nori' options.txt /*'nori'* 'nori' options.txt /*'nori'*
'norightleft' options.txt /*'norightleft'* 'norightleft' options.txt /*'norightleft'*
'norightleftcmd' options.txt /*'norightleftcmd'*
'norl' options.txt /*'norl'* 'norl' options.txt /*'norl'*
'norlc' options.txt /*'norlc'*
'nornu' options.txt /*'nornu'* 'nornu' options.txt /*'nornu'*
'noro' options.txt /*'noro'* 'noro' options.txt /*'noro'*
'nors' options.txt /*'nors'* 'nors' options.txt /*'nors'*

View File

@@ -1088,11 +1088,9 @@ Patch to support horizontal scroll wheel in GTK. Untested. (Bjorn Winckler,
Before (beta) release 7.3: Before (beta) release 7.3:
- Add fixes for 7.2 to version7.txt
- Add hg history to version7.txt
- Remove UF_VERSION_CRYPT_PREV and UF_VERSION_PREV.
- Documentation for Python 3 support. - Documentation for Python 3 support.
- Build the MS-Windows version with Python 2.6.5 and 3.1.2? - Build the MS-Windows version with Ruby 1.91. How?
- Build the MS-Windows version with newer Perl version?
Before release 7.3: Before release 7.3:
- Rename vim73 branch to default (hints: Xavier de Gaye, 2010 May 23) - Rename vim73 branch to default (hints: Xavier de Gaye, 2010 May 23)

View File

@@ -7214,6 +7214,8 @@ the "Edit with Vim" context menu.
The gvim executable is 32 bits, the installed gvimext.dll is either a 32 or 64 The gvim executable is 32 bits, the installed gvimext.dll is either a 32 or 64
bit version. (mostly by George Reilly) bit version. (mostly by George Reilly)
Made the DOS installer work with more compilers. Made the DOS installer work with more compilers.
The MS-Windows big gvim is now built with Python 2.7 and 3.1.2, Perl 5.12 and
Ruby 1.9.1.
The extra and language files are no longer distributed separately. The extra and language files are no longer distributed separately.
The source files for all systems are included in one distribution. The source files for all systems are included in one distribution.
@@ -7309,17 +7311,43 @@ Add patch to improve support of z/OS (OS/390). (Ralf Schandl)
Added the helphelp.txt file. Moved text from various.txt to it. Added the helphelp.txt file. Moved text from various.txt to it.
New syntax files: New syntax files:
TODO Haskell Cabal build file (Vincent Berthoux)
ChaiScript (Jason Turner)
Cucumber (Tim Pope)
Fantom (Kamil Toman)
Liquid (Tim Pope)
Markdown (Tim Pope)
wavefront's obj file (Vincent Berthoux)
Perl 6 (Andy Lester)
SDC - Synopsys Design Constraints (Maurizio Tranchero)
SVG - Scalable Vector Graphics (Vincent Berthoux)
task data (John Florian)
task 42 edit (John Florian)
New filetype plugins: New filetype plugins:
TODO Cucumber (Tim Pope)
Liquid (Tim Pope)
Markdown (Tim Pope)
Tcl (Robert L Hicks)
New spell files: New indent plugins:
TODO ChaiScript (Jason Turner)
Breton. (Dominique Pelle) Cucumber (Tim Pope)
CUDA (Bram Moolenaar)
LifeLines (Patrick Texier)
Liquid (Tim Pope)
Mail (Bram Moolenaar)
Perl 6 (Andy Lester)
Other new runtime files:
Breton spell file (Dominique Pelle)
Tutor Bairish (Sepp Hell)
Tutor in Esperanto. (Dominique Pellé)
Korean translations. (SungHyun Nam)
Dvorak keymap (Ashish Shukla)
Serbian menu translations (Aleksandar Jelenak)
Tetum spell files.
Fixed *fixed-7.3* Fixed *fixed-7.3*

View File

@@ -817,7 +817,11 @@ RUBY_INSTALL_NAME = mswin32-ruby$(RUBY_VER)
!message Ruby requested (version $(RUBY_VER)) - root dir is "$(RUBY)" !message Ruby requested (version $(RUBY_VER)) - root dir is "$(RUBY)"
CFLAGS = $(CFLAGS) -DFEAT_RUBY CFLAGS = $(CFLAGS) -DFEAT_RUBY
RUBY_OBJ = $(OUTDIR)\if_ruby.obj RUBY_OBJ = $(OUTDIR)\if_ruby.obj
!if $(RUBY_VER) >= 190
RUBY_INC = /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" /I "$(RUBY)\include\ruby-$(RUBY_VER_LONG)"
!else
RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)" RUBY_INC = /I "$(RUBY)\lib\ruby\$(RUBY_VER_LONG)\$(RUBY_PLATFORM)"
!endif
RUBY_LIB = $(RUBY)\lib\$(RUBY_INSTALL_NAME).lib RUBY_LIB = $(RUBY)\lib\$(RUBY_INSTALL_NAME).lib
# Do we want to load Ruby dynamically? # Do we want to load Ruby dynamically?
!if "$(DYNAMIC_RUBY)" == "yes" !if "$(DYNAMIC_RUBY)" == "yes"

View File

@@ -404,7 +404,7 @@ CClink = $(CC)
# If both python2.x and python3.x are enabled then the linking will be via # If both python2.x and python3.x are enabled then the linking will be via
# dlopen(), dlsym(), dlclose(), i.e. pythonX.Y.so must be available # dlopen(), dlsym(), dlclose(), i.e. pythonX.Y.so must be available
#CONF_OPT_PYTHON = --enable-pythoninterp #CONF_OPT_PYTHON = --enable-pythoninterp
#CONF_OPT_PYTHON3 = --enable-python3interp CONF_OPT_PYTHON3 = --enable-python3interp
# RUBY # RUBY
# Uncomment this when you want to include the Ruby interface. # Uncomment this when you want to include the Ruby interface.

View File

@@ -1,3 +1,3 @@
:: command to build big Vim with OLE, Perl, Python, Ruby and Tcl :: command to build big Vim with OLE, Perl, Python, Ruby and Tcl
nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl58 DYNAMIC_PERL=yes PERL_VER=58 PYTHON=e:\python24 DYNAMIC_PYTHON=yes PYTHON_VER=24 RUBY=e:\ruby18 DYNAMIC_RUBY=yes RUBY_VER=18 RUBY_VER_LONG=1.8 TCL=e:\tcl DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes XPM=e:\xpm nmake -f Make_mvc.mak GUI=yes OLE=yes PERL=E:\perl512 DYNAMIC_PERL=yes PERL_VER=512 PYTHON=e:\python27 DYNAMIC_PYTHON=yes PYTHON_VER=27 PYTHON3=e:\python31 DYNAMIC_PYTHON3=yes PYTHON3_VER=31 RUBY=e:\ruby191 DYNAMIC_RUBY=yes RUBY_VER=191 RUBY_VER_LONG=1.9.1 TCL=e:\tcl DYNAMIC_TCL=yes %1 IME=yes CSCOPE=yes XPM=e:\xpm

View File

@@ -321,6 +321,7 @@ static void end_dynamic_python3(void)
static int py3_runtime_link_init(char *libname, int verbose) static int py3_runtime_link_init(char *libname, int verbose)
{ {
int i; int i;
void *ucs_from_string, *ucs_from_string_and_size;
if (hinstPy3) if (hinstPy3)
return OK; return OK;
@@ -346,11 +347,8 @@ static int py3_runtime_link_init(char *libname, int verbose)
} }
} }
/* load unicode functions separately as only the ucs2 or the ucs4 functions /* Load unicode functions separately as only the ucs2 or the ucs4 functions
* will be present in the library * will be present in the library. */
*/
void *ucs_from_string, *ucs_from_string_and_size;
ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString"); ucs_from_string = symbol_from_dll(hinstPy3, "PyUnicodeUCS2_FromString");
ucs_from_string_and_size = symbol_from_dll(hinstPy3, ucs_from_string_and_size = symbol_from_dll(hinstPy3,
"PyUnicodeUCS2_FromStringAndSize"); "PyUnicodeUCS2_FromStringAndSize");
@@ -438,7 +436,7 @@ static Py_ssize_t RangeEnd;
static void PythonIO_Flush(void); static void PythonIO_Flush(void);
static int PythonIO_Init(void); static int PythonIO_Init(void);
static void PythonIO_Fini(void); static void PythonIO_Fini(void);
static PyMODINIT_FUNC Py3Init_vim(void); PyMODINIT_FUNC Py3Init_vim(void);
/* Utility functions for the vim/python interface /* Utility functions for the vim/python interface
* ---------------------------------------------- * ----------------------------------------------
@@ -2222,7 +2220,8 @@ PyDoc_STRVAR(vim_module_doc,"vim python interface\n");
static struct PyModuleDef vimmodule; static struct PyModuleDef vimmodule;
static PyMODINIT_FUNC Py3Init_vim(void) #ifndef PROTO
PyMODINIT_FUNC Py3Init_vim(void)
{ {
PyObject *mod; PyObject *mod;
/* The special value is removed from sys.path in Python3_Init(). */ /* The special value is removed from sys.path in Python3_Init(). */
@@ -2255,6 +2254,7 @@ static PyMODINIT_FUNC Py3Init_vim(void)
return mod; return mod;
} }
#endif
/************************************************************************* /*************************************************************************
* 4. Utility functions for handling the interface between Vim and Python. * 4. Utility functions for handling the interface between Vim and Python.

View File

@@ -106,7 +106,7 @@ static size_t fwrite_crypt __ARGS((buf_T *buf UNUSED, char_u *ptr, size_t len, F
static char_u *read_string_decrypt __ARGS((buf_T *buf UNUSED, FILE *fd, int len)); static char_u *read_string_decrypt __ARGS((buf_T *buf UNUSED, FILE *fd, int len));
static int serialize_header __ARGS((FILE *fp, buf_T *buf, char_u *hash)); static int serialize_header __ARGS((FILE *fp, buf_T *buf, char_u *hash));
static int serialize_uhp __ARGS((FILE *fp, buf_T *buf, u_header_T *uhp)); static int serialize_uhp __ARGS((FILE *fp, buf_T *buf, u_header_T *uhp));
static u_header_T *unserialize_uhp __ARGS((FILE *fp, char_u *file_name, int new_version)); static u_header_T *unserialize_uhp __ARGS((FILE *fp, char_u *file_name));
static int serialize_uep __ARGS((FILE *fp, buf_T *buf, u_entry_T *uep)); static int serialize_uep __ARGS((FILE *fp, buf_T *buf, u_entry_T *uep));
static u_entry_T *unserialize_uep __ARGS((FILE *fp, int *error, char_u *file_name)); static u_entry_T *unserialize_uep __ARGS((FILE *fp, int *error, char_u *file_name));
static void serialize_pos __ARGS((pos_T pos, FILE *fp)); static void serialize_pos __ARGS((pos_T pos, FILE *fp));
@@ -694,9 +694,7 @@ nomem:
# define UF_HEADER_END_MAGIC 0xe7aa /* magic after last header */ # define UF_HEADER_END_MAGIC 0xe7aa /* magic after last header */
# define UF_ENTRY_MAGIC 0xf518 /* magic at start of entry */ # define UF_ENTRY_MAGIC 0xf518 /* magic at start of entry */
# define UF_ENTRY_END_MAGIC 0x3581 /* magic after last entry */ # define UF_ENTRY_END_MAGIC 0x3581 /* magic after last entry */
# define UF_VERSION_PREV 1 /* 2-byte undofile version number */
# define UF_VERSION 2 /* 2-byte undofile version number */ # define UF_VERSION 2 /* 2-byte undofile version number */
# define UF_VERSION_CRYPT_PREV 0x8001 /* idem, encrypted */
# define UF_VERSION_CRYPT 0x8002 /* idem, encrypted */ # define UF_VERSION_CRYPT 0x8002 /* idem, encrypted */
/* extra fields for header */ /* extra fields for header */
@@ -1019,10 +1017,9 @@ serialize_uhp(fp, buf, uhp)
} }
static u_header_T * static u_header_T *
unserialize_uhp(fp, file_name, new_version) unserialize_uhp(fp, file_name)
FILE *fp; FILE *fp;
char_u *file_name; char_u *file_name;
int new_version;
{ {
u_header_T *uhp; u_header_T *uhp;
int i; int i;
@@ -1068,7 +1065,6 @@ unserialize_uhp(fp, file_name, new_version)
uhp->uh_time = get8ctime(fp); uhp->uh_time = get8ctime(fp);
/* Optional fields. */ /* Optional fields. */
if (new_version)
for (;;) for (;;)
{ {
int len = getc(fp); int len = getc(fp);
@@ -1564,7 +1560,6 @@ u_read_undo(name, hash, orig_name)
char_u *file_name; char_u *file_name;
FILE *fp; FILE *fp;
long version, str_len; long version, str_len;
int new_version;
char_u *line_ptr = NULL; char_u *line_ptr = NULL;
linenr_T line_lnum; linenr_T line_lnum;
colnr_T line_colnr; colnr_T line_colnr;
@@ -1645,7 +1640,7 @@ u_read_undo(name, hash, orig_name)
goto error; goto error;
} }
version = get2c(fp); version = get2c(fp);
if (version == UF_VERSION_CRYPT || version == UF_VERSION_CRYPT_PREV) if (version == UF_VERSION_CRYPT)
{ {
#ifdef FEAT_CRYPT #ifdef FEAT_CRYPT
if (*curbuf->b_p_key == NUL) if (*curbuf->b_p_key == NUL)
@@ -1665,12 +1660,11 @@ u_read_undo(name, hash, orig_name)
goto error; goto error;
#endif #endif
} }
else if (version != UF_VERSION && version != UF_VERSION_PREV) else if (version != UF_VERSION)
{ {
EMSG2(_("E824: Incompatible undo file: %s"), file_name); EMSG2(_("E824: Incompatible undo file: %s"), file_name);
goto error; goto error;
} }
new_version = (version == UF_VERSION || version == UF_VERSION_CRYPT);
if (fread(read_hash, UNDO_HASH_SIZE, 1, fp) != 1) if (fread(read_hash, UNDO_HASH_SIZE, 1, fp) != 1)
{ {
@@ -1716,8 +1710,7 @@ u_read_undo(name, hash, orig_name)
seq_cur = get4c(fp); seq_cur = get4c(fp);
seq_time = get8ctime(fp); seq_time = get8ctime(fp);
/* Optional header fields, not in previous version. */ /* Optional header fields. */
if (new_version)
for (;;) for (;;)
{ {
int len = getc(fp); int len = getc(fp);
@@ -1758,7 +1751,7 @@ u_read_undo(name, hash, orig_name)
goto error; goto error;
} }
uhp = unserialize_uhp(fp, file_name, new_version); uhp = unserialize_uhp(fp, file_name);
if (uhp == NULL) if (uhp == NULL)
goto error; goto error;
uhp_table[num_read_uhps++] = uhp; uhp_table[num_read_uhps++] = uhp;

View File

@@ -36,5 +36,5 @@
#define VIM_VERSION_NODOT "vim73a" #define VIM_VERSION_NODOT "vim73a"
#define VIM_VERSION_SHORT "7.3a" #define VIM_VERSION_SHORT "7.3a"
#define VIM_VERSION_MEDIUM "7.3a BETA" #define VIM_VERSION_MEDIUM "7.3a BETA"
#define VIM_VERSION_LONG "VIM - Vi IMproved 7.3 BETA (2010 Jul 7)" #define VIM_VERSION_LONG "VIM - Vi IMproved 7.3a BETA (2010 Jul 18)"
#define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.3 BETA (2010 Jul 7, compiled " #define VIM_VERSION_LONG_DATE "VIM - Vi IMproved 7.3a BETA (2010 Jul 18, compiled "