source: postlfs/shells/tcsh.xml@ a72cdddf

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since a72cdddf was a72cdddf, checked in by Bruce Dubbs <bdubbs@…>, 8 years ago

Update to emacs-25.1-rc2 for compatibility with latest glibc.
Archive two unused files
Tags

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@17708 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 9.2 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 <!-- Following URL does not have previous versions
8 <!ENTITY tcsh-download-http "http://www.sfr-fresh.com/unix/misc/tcsh-&tcsh-version;.tar.gz">-->
9 <!-- Following URL does have previous versions -->
10 <!ENTITY tcsh-download-http "http://fossies.org/linux/misc/tcsh-&tcsh-version;.tar.gz">
11 <!ENTITY tcsh-download-ftp "ftp://ftp.astron.com/pub/tcsh/tcsh-&tcsh-version;.tar.gz">
12 <!ENTITY tcsh-md5sum "f5f854833578647795bc906dd4bcb5d5">
13 <!ENTITY tcsh-size "928 KB">
14 <!ENTITY tcsh-buildsize "15 MB (with tests)">
15 <!ENTITY tcsh-time "0.2 SBU (with tests)">
16]>
17
18<sect1 id="tcsh" xreflabel="Tcsh-&tcsh-version;">
19 <?dbhtml filename="tcsh.html"?>
20
21 <sect1info>
22 <othername>$LastChangedBy$</othername>
23 <date>$Date$</date>
24 </sect1info>
25
26 <title>Tcsh-&tcsh-version;</title>
27
28 <indexterm zone="tcsh">
29 <primary sortas="a-Tcsh">Tcsh</primary>
30 </indexterm>
31
32 <sect2 role="package">
33 <title>Introduction to Tcsh</title>
34
35 <para>The <application>Tcsh</application> package contains <quote>an
36 enhanced but completely compatible version of the Berkeley Unix C shell
37 (<command>csh</command>)</quote>. This is useful as an alternative shell
38 for those who prefer C syntax to that of the <command>bash</command> shell,
39 and also because some programs require the C shell in order to perform
40 installation tasks.</para>
41
42 &lfs7a_checked;
43
44 <bridgehead renderas="sect3">Package Information</bridgehead>
45 <itemizedlist spacing="compact">
46 <listitem>
47 <para>Download (HTTP): <ulink url="&tcsh-download-http;"/></para>
48 </listitem>
49 <listitem>
50 <para>Download (FTP): <ulink url="&tcsh-download-ftp;"/></para>
51 </listitem>
52 <listitem>
53 <para>Download MD5 sum: &tcsh-md5sum;</para>
54 </listitem>
55 <listitem>
56 <para>Download size: &tcsh-size;</para>
57 </listitem>
58 <listitem>
59 <para>Estimated disk space required: &tcsh-buildsize;</para>
60 </listitem>
61 <listitem>
62 <para>Estimated build time: &tcsh-time;</para>
63 </listitem>
64 </itemizedlist>
65
66 <para condition="html" role="usernotes">User Notes:
67 <ulink url="&blfs-wiki;/tcsh"/></para>
68
69 </sect2>
70
71 <sect2 role="installation">
72 <title>Installation of Tcsh</title>
73
74 <para>
75 First, fix the package for tool chain changes:
76 </para>
77
78<screen><userinput>sed -e 's/ i)/ k)/' \
79 -e '/ k)/ i \ k = i;' \
80 -e '/\*cp/ a \ volatile size_t k;' \
81 -i tc.alloc.c &amp;&amp;
82
83 sed -i 's|SVID_SOURCE|DEFAULT_SOURCE|g' config/linux &amp;&amp;
84 sed -i 's|BSD_SOURCE|DEFAULT_SOURCE|g' config/linux &amp;&amp;
85 sed -i 's|^ union wait|int|' sh.proc.c</userinput></screen>
86
87 <para>Install <application>Tcsh</application> by running the following
88 commands:</para>
89
90<screen><userinput>sed -i 's|fR/g|&amp;m|' tcsh.man2html &amp;&amp;
91./configure --prefix=/usr --bindir=/bin &amp;&amp;
92
93make &amp;&amp;
94sh ./tcsh.man2html</userinput></screen>
95
96 <para>To test the results, issue: <command>make check</command>.</para>
97
98 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
99
100<screen role="root"><userinput>make install install.man &amp;&amp;
101
102ln -v -sf tcsh /bin/csh &amp;&amp;
103ln -v -sf tcsh.1 /usr/share/man/man1/csh.1 &amp;&amp;
104
105install -v -m755 -d /usr/share/doc/tcsh-&tcsh-version;/html &amp;&amp;
106install -v -m644 tcsh.html/* /usr/share/doc/tcsh-&tcsh-version;/html &amp;&amp;
107install -v -m644 FAQ /usr/share/doc/tcsh-&tcsh-version;</userinput></screen>
108
109 </sect2>
110
111 <sect2 role="commands">
112 <title>Command Explanations</title>
113
114 <para><command>sed -i 's|fR/g|&amp;m|' tcsh.man2html</command>:
115 This updates some deprecated Perl code.</para>
116
117 <para><parameter>--bindir=/bin</parameter>: This installs the
118 <command>tcsh</command> program in <filename
119 class='directory'>/bin</filename> instead of <filename
120 class='directory'>/usr/bin</filename>.</para>
121
122 <para><command>sh ./tcsh.man2html</command>: This creates HTML documentation
123 from the formatted man page.</para>
124
125 <para><command>ln -v -sf tcsh /bin/csh</command>: The FHS states that if
126 there is a <application>C</application> shell installed, there should be a
127 symlink from <filename>/bin/csh</filename> to it. This creates that
128 symlink.</para>
129
130 </sect2>
131
132 <sect2 role="configuration">
133 <title>Configuring Tcsh</title>
134
135 <sect3 id="tcsh-config">
136 <title>Config Files</title>
137
138 <para>There are numerous configuration files for the C shell. Examples
139 of these are <filename>/etc/csh.cshrc</filename>,
140 <filename>/etc/csh.login</filename>, <filename>/etc/csh.logout</filename>,
141 <filename>~/.tcshrc</filename>, <filename>~/.cshrc</filename>,
142 <filename>~/.history</filename>, <filename>~/.cshdirs</filename>,
143 <filename>~/.login</filename>, and <filename>~/.logout</filename>. More
144 information on these files can be found in the
145 <filename>tcsh(1)</filename> man page.</para>
146
147 <indexterm zone="tcsh tcsh-config">
148 <primary sortas="e-etc-csh.cshrc">/etc/csh.cshrc</primary>
149 </indexterm>
150
151 <indexterm zone="tcsh tcsh-config">
152 <primary sortas="e-etc-csh.login">/etc/csh.login</primary>
153 </indexterm>
154
155 <indexterm zone="tcsh tcsh-config">
156 <primary sortas="e-etc-csh.logout">/etc/csh.logout</primary>
157 </indexterm>
158
159 <indexterm zone="tcsh tcsh-config">
160 <primary sortas="e-AA.tcshrc">~/.tcshrc</primary>
161 </indexterm>
162
163 <indexterm zone="tcsh tcsh-config">
164 <primary sortas="e-AA.cshrc">~/.cshrc</primary>
165 </indexterm>
166
167 <indexterm zone="tcsh tcsh-config">
168 <primary sortas="e-AA.history">~/.history</primary>
169 </indexterm>
170
171 <indexterm zone="tcsh tcsh-config">
172 <primary sortas="e-AA.cshdirs">~/.cshdirs</primary>
173 </indexterm>
174
175 <indexterm zone="tcsh tcsh-config">
176 <primary sortas="e-AA.login">~/.login</primary>
177 </indexterm>
178
179 <indexterm zone="tcsh tcsh-config">
180 <primary sortas="e-AA.logout">~/.logout</primary>
181 </indexterm>
182
183 </sect3>
184
185 <sect3>
186 <title>Configuration Information</title>
187
188 <para>Update <filename>/etc/shells</filename> to include the C shell
189 program names (as the <systemitem class="username">root</systemitem>
190 user):</para>
191
192<screen role="root"><userinput>cat &gt;&gt; /etc/shells &lt;&lt; "EOF"
193<literal>/bin/tcsh
194/bin/csh</literal>
195EOF</userinput></screen>
196
197 <para>
198 The following <filename>~/.cshrc</filename> provides two alternative
199 colour prompts and coloured <command>ls</command> output. If you prefer
200 a global modification, issue the command as the <systemitem
201 class="username">root</systemitem> user, replacing
202 <filename>~/.cshrc</filename> by <filename>/etc/csh.cshrc</filename>.
203 </para>
204
205<screen><userinput>cat &gt; ~/.cshrc &lt;&lt; "EOF"
206<literal># Original at:
207# https://www.cs.umd.edu/~srhuang/teaching/code_snippets/prompt_color.tcsh.html
208
209# Modified by the BLFS Development Team.
210
211# Add these lines to your ~/.cshrc (or to /etc/csh.cshrc).
212
213# Colors!
214set red="%{\033[1;31m%}"
215set green="%{\033[0;32m%}"
216set yellow="%{\033[1;33m%}"
217set blue="%{\033[1;34m%}"
218set magenta="%{\033[1;35m%}"
219set cyan="%{\033[1;36m%}"
220set white="%{\033[0;37m%}"
221set end="%{\033[0m%}" # This is needed at the end...
222
223# Setting the actual prompt. Two separate versions for you to try, pick
224# whichever one you like better, and change the colors as you want.
225# Just don't mess with the ${end} guy in either line... Comment out or
226# delete the prompt you don't use.
227
228set prompt="${green}%n${blue}@%m ${white}%~ ${green}%%${end} "
229set prompt="[${green}%n${blue}@%m ${white}%~ ]${end} "
230
231# This was not in the original URL above
232# Provides coloured ls
233alias ls ls --color=always
234
235# Clean up after ourselves...
236unset red green yellow blue magenta cyan yellow white end</literal>
237EOF</userinput></screen>
238
239 </sect3>
240
241 </sect2>
242
243 <sect2 role="content">
244 <title>Contents</title>
245
246 <segmentedlist>
247 <segtitle>Installed Program</segtitle>
248 <segtitle>Installed Libraries</segtitle>
249 <segtitle>Installed Directory</segtitle>
250
251 <seglistitem>
252 <seg>tcsh</seg>
253 <seg>None</seg>
254 <seg>/usr/share/doc/tcsh-&tcsh-version;</seg>
255 </seglistitem>
256 </segmentedlist>
257
258 <variablelist>
259 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
260 <?dbfo list-presentation="list"?>
261 <?dbhtml list-presentation="table"?>
262
263 <varlistentry id="tcsh-prog">
264 <term><command>tcsh</command></term>
265 <listitem>
266 <para>is an enhanced but completely compatible version of the
267 Berkeley Unix C shell, <command>csh</command>. It is usable as both an
268 interactive shell and a script processor.</para>
269 <indexterm zone="tcsh tcsh-prog">
270 <primary sortas="b-tcsh">tcsh</primary>
271 </indexterm>
272 </listitem>
273 </varlistentry>
274 </variablelist>
275
276 </sect2>
277
278</sect1>
Note: See TracBrowser for help on using the repository browser.