source: BOOK/final-system/common/flex.xml@ 91b8781

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since 91b8781 was a0c0bc8, checked in by Chris Staub <chris@…>, 13 years ago

Text fixes

  • Property mode set to 100644
File size: 4.2 KB
RevLine 
[3f8be484]1<?xml version="1.0" encoding="ISO-8859-1"?>
[aa18ac0]2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
[3f8be484]4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-system-flex" role="wrap">
9 <?dbhtml filename="flex.html"?>
10
11 <title>Flex-&flex-version;</title>
12
13 <indexterm zone="ch-system-flex">
14 <primary sortas="a-Flex">Flex</primary>
15 </indexterm>
16
17 <sect2 role="package">
18 <title/>
19
20 <para>The Flex package contains a utility for generating programs that
21 recognize patterns in text.</para>
22
23 </sect2>
24
25 <sect2 role="installation">
26 <title>Installation of Flex</title>
27
[a0c0bc8]28 <para os="p1">The following patch contains fixes to generate proper
[842cd58]29 GCC 4.4.x code:</para>
30
31<screen os="p2"><userinput>patch -Np1 -i ../&flex-gcc44-patch;</userinput></screen>
32
[4bb4b626]33 <para os="a">Prepare Flex for compilation:</para>
[3f8be484]34
[4bb4b626]35<screen os="b"><userinput>./configure --prefix=/usr</userinput></screen>
[3f8be484]36
[4bb4b626]37 <para os="c">Compile the package:</para>
[3f8be484]38
[4bb4b626]39<screen os="d"><userinput>make</userinput></screen>
[3f8be484]40
[4bb4b626]41 <para os="e">To test the results, issue:
[3f8be484]42 <userinput>make check</userinput>.</para>
43
[4bb4b626]44 <para os="f">Install the package:</para>
[3f8be484]45
[4bb4b626]46<screen os="g"><userinput>make install</userinput></screen>
[3f8be484]47
[4bb4b626]48 <para os="h">There are some packages that expect to find the
[3f8be484]49 <filename class="libraryfile">lex</filename> library in <filename
50 class="directory">/usr/lib</filename>. Create a symlink to account for
51 this:</para>
52
[4bb4b626]53<screen os="i"><userinput>ln -sv libfl.a /usr/lib/libl.a</userinput></screen>
[3f8be484]54
[4bb4b626]55 <para os="j">A few programs do not know about <command>flex</command> yet and
[3f8be484]56 try to run its predecessor, <command>lex</command>. To support those
57 programs, create a wrapper script named <filename>lex</filename> that
58 calls <filename>flex</filename> in <command>lex</command> emulation
59 mode:</para>
60
[4bb4b626]61<screen os="k"><userinput>cat &gt; /usr/bin/lex &lt;&lt; "EOF"
[3f8be484]62<literal>#!/bin/sh
63# Begin /usr/bin/lex
64
65exec /usr/bin/flex -l "$@"
66
67# End /usr/bin/lex</literal>
68EOF
[94e6142]69chmod -v 755 /usr/bin/lex</userinput></screen>
[3f8be484]70
71 </sect2>
72
73 <sect2 id="contents-flex" role="content">
74 <title>Contents of Flex</title>
75
76 <segmentedlist>
77 <segtitle>Installed programs</segtitle>
[f5e37b2]78 <segtitle>Installed libraries</segtitle>
[3f8be484]79
80 <seglistitem>
81 <seg>flex and lex</seg>
[f5e37b2]82 <seg>libfl.a and libfl_pic.a</seg>
[3f8be484]83 </seglistitem>
84 </segmentedlist>
85
86 <variablelist>
87 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
88 <?dbfo list-presentation="list"?>
89 <?dbhtml list-presentation="table"?>
90
91 <varlistentry id="flex">
92 <term><command>flex</command></term>
93 <listitem>
94 <para>A tool for generating programs that recognize patterns in text;
95 it allows for the versatility to specify the rules for pattern-finding,
96 eradicating the need to develop a specialized program</para>
97 <indexterm zone="ch-system-flex flex">
98 <primary sortas="b-flex">flex</primary>
99 </indexterm>
100 </listitem>
101 </varlistentry>
102
103 <varlistentry id="lex">
104 <term><command>lex</command></term>
105 <listitem>
106 <para>A script that runs <command>flex</command> in
107 <command>lex</command> emulation mode</para>
108 <indexterm zone="ch-system-flex lex">
109 <primary sortas="b-lex">lex</primary>
110 </indexterm>
111 </listitem>
112 </varlistentry>
113
114 <varlistentry id="libfl.a">
115 <term><filename class="libraryfile">libfl.a</filename></term>
116 <listitem>
117 <para>The <filename class="libraryfile">flex</filename> library</para>
118 <indexterm zone="ch-system-flex libfl.a">
119 <primary sortas="c-libfl.a">libfl.a</primary>
120 </indexterm>
121 </listitem>
122 </varlistentry>
123
[8053eec]124 <varlistentry id="libfl_pic.a">
125 <term><filename class="libraryfile">libfl_pic.a</filename></term>
126 <listitem>
127 <para>The <filename class="libraryfile">flex</filename> library</para>
128 <indexterm zone="ch-system-flex libfl_pic.a">
129 <primary sortas="c-libfl.a">libfl_pic.a</primary>
130 </indexterm>
131 </listitem>
132 </varlistentry>
133
[3f8be484]134 </variablelist>
135
136 </sect2>
137
138</sect1>
Note: See TracBrowser for help on using the repository browser.