lfs/chapter06/flex-inst.xml
Gerard Beekmans 7bfad056d6 QA Part #1
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@2403 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
2003-01-27 22:10:07 +00:00

41 lines
1.1 KiB
XML

<sect2><title>&nbsp;</title><para>&nbsp;</para></sect2>
<sect2>
<title>Installation of Flex</title>
<para>Prepare Flex to be compiled:</para>
<para><screen><userinput>./configure --prefix=/usr</userinput></screen></para>
<para>Continue with compiling the package:</para>
<para><screen><userinput>make</userinput></screen></para>
<para>Install the package:</para>
<para><screen><userinput>make install</userinput></screen></para>
<para>There are packages which expect to find the lex library
in the <filename>/usr/lib</filename> directory. Create a symlink
to account for this:</para>
<para><screen><userinput>ln -s libfl.a /usr/lib/libl.a</userinput></screen></para>
<para>Some programs don't know about flex and try to find the lex
program (flex is a (better) alternative for lex). To please those
programs, create a shell script named lex which calls flex in
emulation mode:</para>
<para><screen><userinput>cat &gt; /usr/bin/lex &lt;&lt; "EOF"</userinput>
#!/bin/sh
# Begin /usr/bin/lex
exec /usr/bin/flex -l "$@"
# End /usr/bin/lex
<userinput>EOF
chmod 755 /usr/bin/lex</userinput></screen></para>
</sect2>