Re: vim7 compiling - install.exe howto

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Re: vim7 compiling - install.exe howto

Gergely Kontra wrote:

> Hi all!
> I've successfully compiled vim7 for windows (mingw).
> I've problems running install.exe.
> I've unpacked the sources to a dir called vim70aa, but install.exe is in
> the src directory.
> However, if I run it from the src directory I get:
> kgergely@PIHENTAGY /d/tmp/vim70aa/src
> $ install.exe
> This program sets up the installation of Vim 7.0aa ALPHA
> ERROR: Install program not in directory "vim70aa"
> This program can only work when it is located in its original directory
> On the other hand, if I cheat and copy the install.exe one level upper:
> kgergely@PIHENTAGY /d/tmp/vim70aa
> $ ./install.exe
> This program sets up the installation of Vim 7.0aa ALPHA
> ERROR: Cannot find filetype.vim in "d:\tmp\vim70aa"
> It looks like you did not unpack the runtime archive.
> You must unpack the runtime archive "" before installing
> So how can I simply install it? (I need the context popup)
> thx
> Gergo

I am redirecting this thread (or trying to) to the vim-dev list, since
it is about compiling and about Vim 7.

You must keep the "development" directory tree and the "production"
directory tree apart from each other.

For the sake of argument, let's say that we have a "development"
directory tree with its root (for vim) at %HOME%\devel\vim and a
"production" directory with %VIM% (in Dos parlance) or $VIM (in Vim
parlance) set to C:\Program Files\Vim (or C:\PROGRA~1\vim). The
following procedure should allow you to generate a working Vim 7
distribution for Win32.

1. Unpack the latest snapshot archive to %HOME%\devel\vim\vim70aa and
its subdirectories. The C sources go in the src/ subdirectory, the
runtime files go to the runtime/ subdirectory, etc. (The archive
includes a directory structure: use it. Extract the snapshot to
...vim70aa, it will create the rest of the directory structure.)

2. cd to %HOME%\devel\vim\vim70aa\src and build the executables there
using the appropriate Makefile for your compiler (Make_ming.mak in your
case) and the target "all" (after setting the appropriate options,
either in the environment or in the Make command-line). The editor
executable ends up in src, the ancillary programs end up in src and its

2 bis. Optionally, build additional editor executables with different
options and the appropriate target (for instance, a Console vim if you
built a GUI at step 2). You may want to use the -B switch in that case
(if your version of make has it), to compile "from scratch" without
clobbering the ancillary programs.

3. Make a few tests to see if your newly built editor(s) work(s) OK.

4. You may want (or not) to generate messages translations, as follows:
        a) cd to %HOME%\devel\vim\vim70aa\src\po
        b) Inspect the Make_ming.mak in the current directory
        c) Invoke it with the proper options:
                c1) Set environment variables as you want them
                c2) make -f Make_ming.mak clean
                c3) make -f Make_ming.mak all
                c4) make -f Make_ming.mak install

5. Copy to %VIM%\vim70aa the following files:
        a) the whole contents (recursively and preserving the subdirectory
structure) of %HOME%\devel\vim\vim70aa\runtime
        b) %HOME%\devel\vim\vim70aa\src\*.exe
        c) %HOME%\devel\vim\vim70aa\src\xxd\*.exe
        d) %HOME%\devel\vim\vim70aa\src\GvimExt\*.dll
        e) %HOME%\devel\vim\vim70aa\src\VisVim\*.dll
        f) %HOME%\devel\vim\vim70aa\src\VisVim\README
        g) %HOME%\devel\vim\vim70aa\vimtutor.bat

6. If you already have a %HOME%\_vimrc from Release 6.3, and possibly
other "user" vim scripts in or under %HOME%\vimfiles and/or
%VIM%\vimfiles, they should work under Vim7 with no change. If you never
had an earlier version of Vim, you may want to create a _vimrc. In that
case you can use the following as a start; you will customize it to your
tastes later.

----- %HOME%\_vimrc starts below this line -----
set nocompatible
" if you want a language setting other than your locale's,
" modify and uncomment the following 'if' block
" if has("unix")
"     language messages C
" else
"     language messages en
" endif

" let's use the 'example' vimrc
source $VIMRUNTIME/vimrc_example.vim

" most user 'enhancements' and 'customizations' will come hereafter
----- %HOME%\_vimrc ends above this line -----

6. If your gvim has OLE support, then the first time you run it, you may
want to run it from an administrator account and with the -register
command-line argument.

This completes most of the "hard work". If you want to run install.exe,
IIUC you should run it from the "production" directory %VIM%\vim70aa.
But you may want instead to just create (or modify, if you already had
Vim 6.3) your own desktop shortcut by hand, and possibly alter your PATH
to include %VIM%\vim70aa -- most of the rest is already done.

Best regards,