source: general/genlib/js78.xml@ 84283d4

10.1 11.0 ken/refactor-virt lazarus qt5new trunk xry111/git-date xry111/git-date-for-trunk xry111/git-date-test
Last change on this file since 84283d4 was 84283d4, checked in by Bruce Dubbs <bdubbs@…>, 13 months ago

Minor tweaks to js78

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

  • Property mode set to 100644
File size: 9.3 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 ff78-version "&firefox-version;">
8 <!ENTITY js78-download-http "&mozilla-http;/firefox/releases/&ff78-version;esr/source/firefox-&ff78-version;esr.source.tar.xz">
9 <!ENTITY js78-download-ftp " ">
10 <!-- 78.2.0 -->
11 <!ENTITY js78-md5sum "e071f6c9bea8344d4556323f02bf6125">
12 <!ENTITY js78-size "317 MB">
13 <!ENTITY js78-buildsize "2.9 GB (30 MB installed after removing 31MB static lib)">
14 <!ENTITY js78-time "2.2 SBU (with parallelism = 4)">
15]>
16
17<sect1 id="js78" xreflabel="js78-&ff78-version;">
18 <?dbhtml filename="js78.html"?>
19
20 <sect1info>
21 <othername>$LastChangedBy$</othername>
22 <date>$Date$</date>
23 </sect1info>
24
25 <title>JS-&ff78-version;</title>
26
27 <indexterm zone="js78">
28 <primary sortas="a-js78">js78</primary>
29 </indexterm>
30
31 <sect2 role="package">
32 <title>Introduction to JS</title>
33
34 <para>
35 <application>JS</application> is Mozilla's JavaScript engine
36 written in C. JS78 is taken from Firefox.
37 </para>
38
39 <bridgehead renderas="sect3">Package Information</bridgehead>
40 <itemizedlist spacing="compact">
41 <listitem>
42 <para>
43 Download (HTTP): <ulink url="&js78-download-http;"/>
44 </para>
45 </listitem>
46 <listitem>
47 <para>
48 Download (FTP): <ulink url="&js78-download-ftp;"/>
49 </para>
50 </listitem>
51 <listitem>
52 <para>
53 Download MD5 sum: &js78-md5sum;
54 </para>
55 </listitem>
56 <listitem>
57 <para>
58 Download size: &js78-size;
59 </para>
60 </listitem>
61 <listitem>
62 <para>
63 Estimated disk space required: &js78-buildsize;
64 </para>
65 </listitem>
66 <listitem>
67 <para>
68 Estimated build time: &js78-time;
69 </para>
70 </listitem>
71 </itemizedlist>
72<!--
73 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
74 <itemizedlist spacing="compact">
75 <listitem>
76 <para>
77 Required patch:
78 <ulink url="&patch-root;/js78-code_coverage-1.patch"/>
79 </para>
80 </listitem>
81 </itemizedlist>
82-->
83 <bridgehead renderas="sect3">JS78 Dependencies</bridgehead>
84
85 <bridgehead renderas="sect4">Required</bridgehead>
86 <para role="required">
87 <xref linkend="autoconf213"/>,
88 <xref linkend="icu"/>,
89 <xref linkend="rust"/>, and
90 <xref linkend="which"/>
91 <!-- Should we list llvm here? -->
92 </para>
93
94 <!-- It seems nasm is only used for aarch64-win64. -->
95 <!--bridgehead renderas="sect4">Optional</bridgehead>
96 <para role="optional">
97 <xref linkend="nasm"/>
98 </para-->
99
100 <para condition="html" role="usernotes">
101 User Notes: <ulink url="&blfs-wiki;/js78"/>
102 </para>
103 </sect2>
104
105 <sect2 role="installation">
106 <title>Installation of JS</title>
107
108 <caution>
109 <para>
110 If you are upgrading JS78 from a previously installed old version,
111 save all work and exit your GNOME Session if you have one running.
112 Replacing the JS78 binary will cause the GNOME Shell to crash and
113 return you to your display manager or TTY. After installing the new
114 version, if GNOME Shell still doesn't work, reinstall
115 <xref linkend="gjs"/>.
116 </para>
117 </caution>
118
119 <note>
120 <para>
121 Unlike most other packages in BLFS, the instructions below require you
122 to untar <filename>firefox-&ff78-version;esr.tar.xz</filename> and
123 change into the <filename>firefox-&ff78-version;</filename> folder.
124 </para>
125
126 <para>
127 Extracting the tarball
128 will reset the permissions of the current directory to 0755 if you
129 have permission to do that. If you do this in a directory where
130 the sticky bit is set, such
131 as <filename class="directory">/tmp</filename> it will end with error
132 messages:
133 </para>
134
135<literallayout>tar: .: Cannot utime: Operation not permitted
136tar: .: Cannot change mode to rwxr-xr-t: Operation not permitted
137tar: Exiting with failure status due to previous errors
138</literallayout>
139
140 <para>
141 This does finish with non-zero status, but it does
142 <emphasis>NOT</emphasis> mean there is a real problem.
143 Do not untar as the <systemitem class="username">root</systemitem> user
144 in a directory where the sticky bit is set - that will unset it.
145 </para>
146
147 </note>
148
149<!-- It's merged in 78.2.0.
150 <para>
151 Apply a patch required by <xref linkend="gjs"/>:
152 </para>
153
154<screen><userinput>patch -Np1 -i ../js78-code_coverage-1.patch</userinput></screen>
155-->
156 <para>
157 Install <application>JS</application> by running the following
158 commands:
159 </para>
160
161 <note>
162 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
163 href="../../xincludes/mozshm.xml"/>
164
165 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
166 href="../../xincludes/mozconfigure.xml"/>
167 </note>
168
169
170<screen><userinput>mkdir obj &amp;&amp;
171cd obj &amp;&amp;
172
173CC=gcc CXX=g++ \
174../js/src/configure --prefix=/usr \
175 --with-intl-api \
176 --with-system-zlib \
177 --with-system-icu \
178 --disable-jemalloc \
179 --disable-debug-symbols \
180 --enable-readline &amp;&amp;
181make</userinput></screen>
182
183 <para>
184 <!-- All JIT tests pass with 78.2.0. -->
185 To run JIT test suite, issue:
186 <command>make -C js/src check-jit-test
187 JITTEST_EXTRA_ARGS="--timeout 300"</command>.
188 The other parts of test suite are not functional on BLFS.
189 </para>
190
191 <para>
192 Now, as the <systemitem class="username">root</systemitem> user:
193 </para>
194
195<screen role="root"><userinput>make install &amp;&amp;
196rm -v /usr/lib/libjs_static.ajs &amp;&amp;
197sed -i '/@NSPR_CFLAGS@/d' /usr/bin/js78-config</userinput></screen>
198
199 </sect2>
200
201 <!-- Several gjs-1.65.90 tests fail with js78. Not sure why.
202 OTOH an "otherwise" GNOME-3.36 environment works fine. -->
203
204 <sect2 role="commands">
205 <title>Command Explanations</title>
206
207 <para>
208 <envar>CC=gcc CXX=g++</envar>: Upstream now prefers
209 <application>clang</application>, override it like other Mozilla
210 packages in BLFS book.
211 </para>
212
213 <para>
214 <parameter>--with-*</parameter>: These parameters allow the build system
215 to use system versions of the above libraries. These are required for
216 stability.
217 </para>
218
219 <para>
220 <parameter>--enable-readline</parameter>: This switch enables Readline
221 support in the JS shell.
222 </para>
223
224 <para>
225 <parameter>--disable-jemalloc</parameter>: This switch disables the
226 internal memory allocator used in JS78. jemalloc causes a conflict with glibc.
227 </para>
228
229 <para>
230 <parameter>--disable-debug-symbols</parameter>: Don't generate debug
231 symbols since they are very large and most users won't need it. Remove
232 it if you want to debug JS78.
233 </para>
234
235 <para>
236 <command>rm -v /usr/lib/libjs_static.ajs</command>: Remove a large
237 static library which is not used by any BLFS package.
238 </para>
239
240 <para>
241 <command>sed -i '/@NSPR_CFLAGS@/d' /usr/bin/js78-config</command>:
242 Prevent <command>js78-config</command> from using buggy CFLAGS.
243 </para>
244
245 </sect2>
246
247 <sect2 role="content">
248 <title>Contents</title>
249
250 <segmentedlist>
251 <segtitle>Installed Programs</segtitle>
252 <segtitle>Installed Libraries</segtitle>
253 <segtitle>Installed Directories</segtitle>
254
255 <seglistitem>
256 <seg>
257 js78 and js78-config
258 </seg>
259 <seg>
260 libmozjs-78.so
261 </seg>
262 <seg>
263 /usr/include/mozjs-78
264 </seg>
265 </seglistitem>
266 </segmentedlist>
267
268 <variablelist>
269 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
270 <?dbfo list-presentation="list"?>
271 <?dbhtml list-presentation="table"?>
272
273 <varlistentry id="js6-js78">
274 <term><command>js78</command></term>
275 <listitem>
276 <para>
277 provides a command line interface to the
278 <application>JavaScript</application> engine.
279 </para>
280 <indexterm zone="js78 js78">
281 <primary sortas="b-js78">js78</primary>
282 </indexterm>
283 </listitem>
284 </varlistentry>
285
286 <varlistentry id="js78-config">
287 <term><command>js78-config</command></term>
288 <listitem>
289 <para>
290 is used to find the JS compiler and linker flags.
291 </para>
292 <indexterm zone="js78 js78-config">
293 <primary sortas="b-js78-config">js78-config</primary>
294 </indexterm>
295 </listitem>
296 </varlistentry>
297
298 <varlistentry id="libmozjs-78">
299 <term><filename class="libraryfile">libmozjs-78.so</filename></term>
300 <listitem>
301 <para>
302 contains the Mozilla JavaScript API functions.
303 </para>
304 <indexterm zone="js78 libmozjs-78">
305 <primary sortas="c-libmozjs78">libmozjs-78.so</primary>
306 </indexterm>
307 </listitem>
308 </varlistentry>
309 </variablelist>
310 </sect2>
311</sect1>
Note: See TracBrowser for help on using the repository browser.