source: general/prog/lua.xml@ 231d5eb

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 231d5eb was 231d5eb, checked in by Fernando de Oliveira <fernando@…>, 10 years ago

Help Lua-5.2.3 to find Ncurses-5.9 for Readline-6.3.

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

  • Property mode set to 100644
File size: 6.6 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 <!ENTITY lua-download-http "http://www.lua.org/ftp/lua-&lua-version;.tar.gz">
8 <!ENTITY lua-download-ftp " ">
9 <!ENTITY lua-md5sum "dc7f94ec6ff15c985d2d6ad0f1b35654">
10 <!ENTITY lua-size "248 KB">
11 <!ENTITY lua-buildsize "3.5 MB">
12 <!ENTITY lua-time "Less than 0.1 SBU">
13]>
14
15<sect1 id="lua" xreflabel="Lua-&lua-version;">
16 <?dbhtml filename="lua.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
23 <title>Lua-&lua-version;</title>
24
25 <indexterm zone="lua">
26 <primary sortas="a-Lua">Lua</primary>
27 </indexterm>
28
29 <sect2 role="package">
30 <title>Introduction to Lua</title>
31
32 <para>
33 <application>Lua</application> is a powerful light-weight programming
34 language designed for extending applications. It is also frequently used
35 as a general-purpose, stand-alone language. <application>Lua</application>
36 is implemented as a small library of C functions, written in ANSI C, and
37 compiles unmodified in all known platforms. The implementation goals are
38 simplicity, efficiency, portability, and low embedding cost. The result is
39 a fast language engine with small footprint, making it ideal in embedded
40 systems too.
41 </para>
42
43 &lfs75_checked;
44
45 <bridgehead renderas="sect3">Package Information</bridgehead>
46 <itemizedlist spacing="compact">
47 <listitem>
48 <para>
49 Download (HTTP): <ulink url="&lua-download-http;"/>
50 </para>
51 </listitem>
52 <listitem>
53 <para>
54 Download (FTP): <ulink url="&lua-download-ftp;"/>
55 </para>
56 </listitem>
57 <listitem>
58 <para>
59 Download MD5 sum: &lua-md5sum;
60 </para>
61 </listitem>
62 <listitem>
63 <para>
64 Download size: &lua-size;
65 </para>
66 </listitem>
67 <listitem>
68 <para>
69 Estimated disk space required: &lua-buildsize;
70 </para>
71 </listitem>
72 <listitem>
73 <para>
74 Estimated build time: &lua-time;
75 </para>
76 </listitem>
77 </itemizedlist>
78
79 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
80 <itemizedlist spacing="compact">
81 <listitem>
82 <para>
83 Required patch:
84 <ulink url="&patch-root;/lua-&lua-version;-shared_library-1.patch"/>
85 </para>
86 </listitem>
87 </itemizedlist>
88
89 <para condition="html" role="usernotes">User Notes:
90 <ulink url="&blfs-wiki;/lua"/>
91 </para>
92 </sect2>
93
94 <sect2 role="installation">
95 <title>Installation of Lua</title>
96
97 <para>
98 Install <application>Lua</application> by running the following
99 commands:
100 </para>
101
102<screen><userinput>patch -Np1 -i ../lua-&lua-version;-shared_library-1.patch &amp;&amp;
103sed -i '/#define LUA_ROOT/s:/usr/local/:/usr/:' src/luaconf.h &amp;&amp;
104sed -i 's/-lreadline/-lreadline -lncurses/' src/Makefile &amp;&amp;
105make linux</userinput></screen>
106
107 <para>
108 To test the results, issue: <command>make test</command>.
109 </para>
110
111 <para>
112 Now, as the <systemitem class="username">root</systemitem> user:
113 </para>
114
115<screen role="root"><userinput>make INSTALL_TOP=/usr TO_LIB="liblua.so liblua.so.5.2 liblua.so.&lua-version;" \
116 INSTALL_DATA="cp -d" INSTALL_MAN=/usr/share/man/man1 install &amp;&amp;
117mkdir -pv /usr/share/doc/lua-&lua-version; &amp;&amp;
118cp -v doc/*.{html,css,gif,png} /usr/share/doc/lua-&lua-version;</userinput></screen>
119
120 <para>Some packages check for the <application>pkg-config</application> file
121 for <application>Lua</application>. As the
122 <systemitem class="username">root</systemitem> user:</para>
123
124<screen role="root"><userinput>cat &gt; /usr/lib/pkgconfig/lua.pc &lt;&lt; "EOF"
125<literal>V=5.2
126R=&lua-version;
127
128prefix=/usr
129INSTALL_BIN=${prefix}/bin
130INSTALL_INC=${prefix}/include
131INSTALL_LIB=${prefix}/lib
132INSTALL_MAN=${prefix}/man/man1
133INSTALL_LMOD=${prefix}/share/lua/${V}
134INSTALL_CMOD=${prefix}/lib/lua/${V}
135exec_prefix=${prefix}
136libdir=${exec_prefix}/lib
137includedir=${prefix}/include
138
139Name: Lua
140Description: An Extensible Extension Language
141Version: ${R}
142Requires:
143Libs: -L${libdir} -llua -lm
144Cflags: -I${includedir}</literal>
145EOF</userinput></screen>
146
147 </sect2>
148
149 <sect2 role="commands">
150 <title>Command Explanations</title>
151
152 <para>
153 <command>sed -i ... src/luaconf.h</command>: This command changes
154 <application>Lua</application> search path to match the install paths.
155 </para>
156
157 <para>
158 <command>sed -i ... src/Makefile</command>: This command helps
159 <application>Lua</application> to find <application>Ncurses</application>
160 libraries at build time.
161 </para>
162
163 </sect2>
164
165 <sect2 role="content">
166 <title>Contents</title>
167
168 <segmentedlist>
169 <segtitle>Installed Programs</segtitle>
170 <segtitle>Installed Library</segtitle>
171 <segtitle>Installed Directories</segtitle>
172
173 <seglistitem>
174 <seg>
175 lua and luac
176 </seg>
177 <seg>
178 liblua.so
179 </seg>
180 <seg>
181 /usr/lib/lua,
182 /usr/share/lua and
183 /usr/share/doc/lua-&lua-version;
184 </seg>
185 </seglistitem>
186 </segmentedlist>
187
188 <variablelist>
189 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
190 <?dbfo list-presentation="list"?>
191 <?dbhtml list-presentation="table"?>
192
193 <varlistentry id="lua-prog">
194 <term><command>lua</command></term>
195 <listitem>
196 <para>
197 is the standalone Lua interpreter.
198 </para>
199 <indexterm zone="lua lua-prog">
200 <primary sortas="b-lua">lua</primary>
201 </indexterm>
202 </listitem>
203 </varlistentry>
204
205 <varlistentry id="luac">
206 <term><command>luac</command></term>
207 <listitem>
208 <para>
209 is the Lua compiler.
210 </para>
211 <indexterm zone="lua luac">
212 <primary sortas="b-luac">luac</primary>
213 </indexterm>
214 </listitem>
215 </varlistentry>
216
217 <varlistentry id="liblua">
218 <term><filename class="libraryfile">liblua.so</filename></term>
219 <listitem>
220 <para>
221 contains the <application>Lua</application> API functions.
222 </para>
223 <indexterm zone="lua liblua">
224 <primary sortas="c-liblua">liblua.so</primary>
225 </indexterm>
226 </listitem>
227 </varlistentry>
228
229 </variablelist>
230
231 </sect2>
232
233</sect1>
Note: See TracBrowser for help on using the repository browser.