glfs/general/prog/tk.xml
Manuel Canales Esparcia 516af1140b Tagged tk.xml
git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@3992 af4574ff-66df-0310-9fd7-8a98e5e911e0
2005-05-05 20:46:59 +00:00

193 lines
6.3 KiB
XML

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../../general.ent">
%general-entities;
<!ENTITY tk-download-http "http://prdownloads.sourceforge.net/tcl/tk&tk-version;-src.tar.gz">
<!ENTITY tk-download-ftp "ftp://ftp.us.xemacs.org/pub/tcl/tcl8_4/tk&tk-version;-src.tar.gz">
<!ENTITY tk-md5sum "1b64258abaf258e9a86f331d8de17a71">
<!ENTITY tk-size "3.2 MB">
<!ENTITY tk-buildsize "23.3 MB">
<!ENTITY tk-time "0.35 SBU">
]>
<sect1 id="tk" xreflabel="Tk-&tk-version;">
<?dbhtml filename="tk.html"?>
<sect1info>
<othername>$LastChangedBy$</othername>
<date>$Date$</date>
</sect1info>
<title>Tk-&tk-version;</title>
<indexterm zone="tk">
<primary sortas="a-Tk">Tk</primary>
</indexterm>
<sect2 role="package">
<title>Introduction to Tk</title>
<para>The <application>Tk</application> package contains a
TCL GUI Toolkit.</para>
<bridgehead renderas="sect3">Package Information</bridgehead>
<itemizedlist spacing="compact">
<listitem>
<para>Download (HTTP): <ulink url="&tk-download-http;"/></para>
</listitem>
<listitem>
<para>Download (FTP): <ulink url="&tk-download-ftp;"/></para>
</listitem>
<listitem>
<para>Download MD5 sum: &tk-md5sum;</para>
</listitem>
<listitem>
<para>Download size: &tk-size;</para>
</listitem>
<listitem>
<para>Estimated disk space required: &tk-buildsize;</para>
</listitem>
<listitem>
<para>Estimated build time: &tk-time;</para>
</listitem>
</itemizedlist>
<bridgehead renderas="sect3">Tk Dependencies</bridgehead>
<bridgehead renderas="sect4">Required</bridgehead>
<para>X (<xref linkend="xfree86"/> or <xref linkend="xorg"/>) and
<xref linkend="tcl"/></para>
</sect2>
<sect2 role="installation">
<title>Installation of Tk</title>
<para>Install <application>Tk</application> by running the following
commands:</para>
<screen><userinput>export VERSION=&tk-version; &amp;&amp;
export V=`echo $VERSION | cut -d "." -f 1,2` &amp;&amp;
export DIR=$PWD &amp;&amp;
cd unix &amp;&amp;
./configure --prefix=/usr --enable-threads &amp;&amp;
make &amp;&amp;
sed -i "s:${DIR}/unix:/usr/lib:" tkConfig.sh &amp;&amp;
sed -i "s:${DIR}:/usr/include/tk${V}:" tkConfig.sh</userinput></screen>
<para>To test the results, issue: <command>make test</command>.
Ensure you do it from an X Window display device with the
GLX extensions loaded, else the tests will hang.</para>
<para>Now, as the <systemitem class="username">root</systemitem> user:</para>
<screen role="root"><userinput>make install &amp;&amp;
install -v -d /usr/include/tk${V}/unix &amp;&amp;
install -v -m644 *.h /usr/include/tk${V}/unix/ &amp;&amp;
install -v -d /usr/include/tk${V}/generic &amp;&amp;
install -v -m644 ../generic/*.h /usr/include/tk${V}/generic/ &amp;&amp;
rm -v -f /usr/include/tk${V}/generic/{tk,tkDecls,tkPlatDecls}.h &amp;&amp;
ln -v -nsf ../../include/tk${V} /usr/lib/tk${V}/include &amp;&amp;
ln -v -sf libtk${V}.so /usr/lib/libtk.so &amp;&amp;
ln -v -sf wish${V} /usr/bin/wish</userinput></screen>
<para>Clean up the unprivileged user's environment using the following
commands:</para>
<screen><userinput>unset VERSION &amp;&amp;
unset V &amp;&amp;
unset DIR</userinput></screen>
<!--
<caution>
<para>If you build the package as an ordinary user and then switch to
root to install the package, ensure you set the environment variables
<envar>V</envar> and <envar>VERSION</envar> before running the installation
commands.</para>
</caution>
-->
</sect2>
<sect2 role="commands">
<title>Command Explanations</title>
<para><parameter>--enable-threads</parameter>: This switch forces the package
to build with thread support.</para>
<para><command>sed -i ...</command>: The <application>Tk</application> package
assumes that the source that is used to build <application>Tk</application> is
always kept around for compiling packages that depend on
<application>Tk</application>. These <command>sed</command>'s remove the
reference to the build directory and replace them by saner system wide
locations.</para>
<para><command>install ...</command>: These commands install the internal
headers into a system-wide location.</para>
<para><command>ln -v -sf ...</command>: These commands create compatibility
symbolic links.</para>
</sect2>
<sect2 role="content">
<title>Contents</title>
<segmentedlist>
<segtitle>Installed Programs</segtitle>
<segtitle>Installed Libraries</segtitle>
<segtitle>Installed Directories</segtitle>
<seglistitem>
<seg>wish and wish8.4</seg>
<seg>libtk.so and libtkstub8.4.a</seg>
<seg>/usr/include/tk8.4 and /usr/lib/tk8.4</seg>
</seglistitem>
</segmentedlist>
<variablelist>
<bridgehead renderas="sect3">Short Descriptions</bridgehead>
<?dbfo list-presentation="list"?>
<?dbhtml list-presentation="table"?>
<varlistentry id="wish">
<term><command>wish</command></term>
<listitem>
<para> is a symlink to the <command>wish8.4</command> program.</para>
<indexterm zone="tk wish">
<primary sortas="b-wish">wish</primary>
</indexterm>
</listitem>
</varlistentry>
<varlistentry id="wish8.4">
<term><command>wish8.4</command></term>
<listitem>
<para> is a simple shell containing the
<application>Tk</application> toolkit that creates a main window and
then processes <application>Tcl</application> commands.</para>
<indexterm zone="tk wish8.4">
<primary sortas="b-wish8.4">wish8.4</primary>
</indexterm>
</listitem>
</varlistentry>
<varlistentry id="libtk">
<term><filename role="library">libtk.so</filename></term>
<listitem>
<para>contains the API functions required
by <application>Tk</application>.</para>
<indexterm zone="tk libtk">
<primary sortas="c-libtk">libtk.so</primary>
</indexterm>
</listitem>
</varlistentry>
</variablelist>
</sect2>
</sect1>