vim-inst.xml 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <sect2><title>&nbsp;</title><para>&nbsp;</para></sect2>
  2. <sect2>
  3. <title>Installation of Vim</title>
  4. <para>This package requires its patch to be applied before you can
  5. install it. This patch fixes a compile problem with GCC-3.2:</para>
  6. <para><screen><userinput>patch -Np1 -i ../vim-&vim-patch-version;.patch</userinput></screen></para>
  7. <para>Prepare Vim to be compiled:</para>
  8. <para><screen><userinput>./configure --prefix=/usr</userinput></screen></para>
  9. <para>Continue with compiling the package:</para>
  10. <para><screen><userinput>make CPPFLAGS=-DSYS_VIMRC_FILE=\\\"/etc/vimrc\\\"</userinput></screen></para>
  11. <para>The meaning of the make option is:</para>
  12. <itemizedlist>
  13. <listitem><para><userinput>CPPFLAGS=-DSYS_VIMRC_FILE=\\\"/etc/vimrc\\\":</userinput>
  14. This option above causes vim to look for the
  15. <filename>/etc/vimrc</filename> file which contains vim's global settings.
  16. Normally, this file is assumed to be located in <filename
  17. class="directory">/usr/share/vim</filename>, but we feel that
  18. <filename class="directory">/etc</filename> is a more logical place for this
  19. kind of file.</para></listitem>
  20. </itemizedlist>
  21. <para>The <emphasis>CPPFLAGS</emphasis> option above causes vim to look
  22. for the /etc/vimrc file which contains vim's global settings. Normally,
  23. this file is assumed to be located in <filename>/usr/share/vim</filename>,
  24. but we feel that <filename>/etc</filename> is a more logical place for
  25. this kind of file.</para>
  26. <para>Finish installing the package:</para>
  27. <para><screen><userinput>make install</userinput></screen></para>
  28. <para>Vim can run in old-fashioned <emphasis>vi</emphasis> mode by
  29. creating a symlink, which may be created with the following command:</para>
  30. <para><screen><userinput>ln -s vim /usr/bin/vi</userinput></screen></para>
  31. <para>If you plan to install the X Window system on your LFS
  32. system, you might want to re-compile Vim after you have installed X. Vim
  33. comes with a nice GUI version of the editor which requires X and a few
  34. other libraries to be installed. For more information read the Vim
  35. documentation.</para>
  36. </sect2>