mirror of
https://git.linuxfromscratch.org/lfs.git
synced 2025-01-20 14:07:39 +00:00
8f98b45c4b
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@1337 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
30 lines
782 B
XML
30 lines
782 B
XML
<sect2>
|
|
<title>Installation of Flex</title>
|
|
|
|
<para>Install Flex by running the following commands:</para>
|
|
|
|
<para><screen><userinput>./configure --prefix=/usr &&
|
|
make &&
|
|
make install</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). So to please those few
|
|
programs out there we'll create a lex script that calls flex and have
|
|
it emulate lex.</para>
|
|
|
|
<para>Create a new file <filename>/usr/bin/lex</filename> by running the
|
|
following:</para>
|
|
|
|
<para><screen><userinput>cat > /usr/bin/lex << "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>
|
|
|