source: BOOK/temp-system/common/vim.xml@ c5c09e6

sysvinit
Last change on this file since c5c09e6 was 80c037c, checked in by Chris Staub <chris@…>, 9 years ago

Removed extra spaces

  • Property mode set to 100644
File size: 4.8 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-temp-system-vim" role="wrap">
9 <?dbhtml filename="vim.html"?>
10
11 <title>Vim-&vim-version;</title>
12
13 <indexterm zone="ch-temp-system-vim">
14 <primary sortas="a-Vim">Vim</primary>
15 <secondary>temporary system</secondary>
16 </indexterm>
17
18 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
19 href="../../final-system/common/vim.xml"
20 xpointer="xpointer(//*[@role='package'])"/>
21
22 <sect2 role="installation">
23 <title>Installation of VIM</title>
24
25 <para os="a">We will cross-compile Vim so that we can have a text editor in
26 <filename class="directory">/tools</filename>. Vim is not technically
27 necessary in the temporary system, in that it is not there to satisfy any
28 package dependencies in the final system, but we believe that a text editor
29 is an extremely useful tool to have there.<!-- If you prefer a different
30 editor, you may check the hints project at <ulink url="&hints-root;" />
31 for information on cross-compiling other text editors. (placeholder -
32 uncomment this sentence if/when such information actually exists)--></para>
33
34 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
35 href="../../final-system/common/vim.xml"
36 xpointer="xpointer(//*[@os='p1'])"/>
37
38 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
39 href="../../final-system/common/vim.xml"
40 xpointer="xpointer(//*[@os='p2'])"/>
41
42 <para os="c1">The <command>configure</command> script is full of logic
43 that aborts at the first sign of cross compiling. Work around this by
44 setting the cached values of several tests with the following
45 command:</para>
46
47<screen os="c2"><userinput>cat &gt; src/auto/config.cache &lt;&lt; "EOF"
48vim_cv_getcwd_broken=no
49vim_cv_memmove_handles_overlap=yes
50vim_cv_stat_ignores_slash=no
51vim_cv_terminfo=yes
52vim_cv_toupper_broken=no
53vim_cv_tty_group=world
54EOF</userinput></screen>
55
56 <para os="b">Change the default location of
57 the <filename>vimrc</filename> configuration file to <filename
58 class="directory">/tools/etc</filename>:</para>
59
60<screen os="c"><userinput>echo '#define SYS_VIMRC_FILE "/tools/etc/vimrc"' &gt;&gt; src/feature.h</userinput></screen>
61
62 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
63 href="../../final-system/common/vim.xml"
64 xpointer="xpointer(//*[@os='d'])"/>
65
66<screen os="e"><userinput>./configure \
67 --build=${CLFS_HOST} \
68 --host=${CLFS_TARGET} \
69 --prefix=/tools \
70 --enable-gui=no \
71 --disable-gtktest \
72 --disable-xim \
73 --disable-gpm \
74 --without-x \
75 --disable-netbeans \
76 --with-tlib=ncurses</userinput></screen>
77
78 <variablelist os="f">
79 <title>The meaning of the new configure options:</title>
80
81 <varlistentry>
82 <term><parameter>--enable-gui=no --disable-gtktest --disable-xim --disable-gpm --without-x --disable-netbeans</parameter></term>
83 <listitem>
84 <para>These options prevent Vim from trying to link to libraries
85 that might be on the host but won't exist inside the temporary
86 build environment.</para>
87 </listitem>
88 </varlistentry>
89
90 <varlistentry>
91 <term><parameter>--with-tlib=ncurses</parameter></term>
92 <listitem>
93 <para>Tells Vim to use Ncurses as its terminal library.</para>
94 </listitem>
95 </varlistentry>
96
97 </variablelist>
98
99 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
100 href="../../final-system/common/vim.xml"
101 xpointer="xpointer(//*[@os='g'])"/>
102
103 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
104 href="../../final-system/common/vim.xml"
105 xpointer="xpointer(//*[@os='h'])"/>
106
107 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
108 href="../../final-system/common/vim.xml"
109 xpointer="xpointer(//*[@os='j'])"/>
110
111 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
112 href="../../final-system/common/vim.xml"
113 xpointer="xpointer(//*[@os='k'])"/>
114
115 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
116 href="../../final-system/common/vim.xml"
117 xpointer="xpointer(//*[@os='l'])"/>
118
119<screen os="m"><userinput>ln -sv vim /tools/bin/vi</userinput></screen>
120
121 <para os="tv1">Create a temporary vimrc to make it function more the way you may
122 expect it to. This is explained more in the final system:</para>
123
124<screen os="tv2"><userinput>cat &gt; /tools/etc/vimrc &lt;&lt; "EOF"
125<literal>" Begin /tools/etc/vimrc
126
127set nocompatible
128set backspace=2
129set ruler
130syntax on
131
132" End /tools/etc/vimrc</literal>
133EOF</userinput></screen>
134
135 </sect2>
136
137 <sect2 role="content">
138 <title/>
139
140 <para>Details on this package are located in <xref
141 linkend="contents-vim" role="."/></para>
142
143 </sect2>
144
145</sect1>
Note: See TracBrowser for help on using the repository browser.