source: general/genlib/js78.xml@ ca73053a

11.0 11.1 11.2 11.3 12.0 12.1 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since ca73053a was ca73053a, checked in by Ken Moffat <ken@…>, 3 years ago

Firefox-78.10.1 and JS-78.10.1.

  • Property mode set to 100644
File size: 10.5 KB
RevLine 
[fcce89bc]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
[433336d]7<!-- for when firefox and js78 use same version
[fcce89bc]8 <!ENTITY ff78-version "&firefox-version;">
[2c5bbb8]9 and when they are on different versions - keep this for when
[2694f38]10 we have moved to next firefox-esr (ff-91) and JS has not moved
11 <!ENTITY ff78-version "&JS78-version;"> -->
12
[72d8eb3]13 <!ENTITY ff78-version "&firefox-version;">
[fcce89bc]14 <!ENTITY js78-download-http "&mozilla-http;/firefox/releases/&ff78-version;esr/source/firefox-&ff78-version;esr.source.tar.xz">
15 <!ENTITY js78-download-ftp " ">
[ca73053a]16 <!ENTITY js78-md5sum "0aa9c735305304373f9fddc35c56e81b">
17 <!ENTITY js78-size "319 MB">
[4e2a48d]18 <!ENTITY js78-buildsize "3.0 GB (36 MB installed after removing 34MB static lib)">
[ca73053a]19 <!ENTITY js78-time "2.4 SBU (on a 4-core machine with parallelism=4)">
[fcce89bc]20]>
21
22<sect1 id="js78" xreflabel="js78-&ff78-version;">
23 <?dbhtml filename="js78.html"?>
24
25 <sect1info>
26 <date>$Date$</date>
27 </sect1info>
28
29 <title>JS-&ff78-version;</title>
30
31 <indexterm zone="js78">
32 <primary sortas="a-js78">js78</primary>
33 </indexterm>
34
35 <sect2 role="package">
36 <title>Introduction to JS</title>
37
38 <para>
39 <application>JS</application> is Mozilla's JavaScript engine
40 written in C. JS78 is taken from Firefox.
41 </para>
42
[6b063cc3]43 &lfs101_checked;
44
[fcce89bc]45 <bridgehead renderas="sect3">Package Information</bridgehead>
46 <itemizedlist spacing="compact">
47 <listitem>
48 <para>
49 Download (HTTP): <ulink url="&js78-download-http;"/>
50 </para>
51 </listitem>
52 <listitem>
53 <para>
54 Download (FTP): <ulink url="&js78-download-ftp;"/>
55 </para>
56 </listitem>
57 <listitem>
58 <para>
59 Download MD5 sum: &js78-md5sum;
60 </para>
61 </listitem>
62 <listitem>
63 <para>
64 Download size: &js78-size;
65 </para>
66 </listitem>
67 <listitem>
68 <para>
69 Estimated disk space required: &js78-buildsize;
70 </para>
71 </listitem>
72 <listitem>
73 <para>
74 Estimated build time: &js78-time;
75 </para>
76 </listitem>
77 </itemizedlist>
[5d0f53c0]78<!--
[fcce89bc]79 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
80 <itemizedlist spacing="compact">
81 <listitem>
82 <para>
83 Required patch:
84 <ulink url="&patch-root;/js78-code_coverage-1.patch"/>
85 </para>
86 </listitem>
87 </itemizedlist>
[5d0f53c0]88-->
[fcce89bc]89 <bridgehead renderas="sect3">JS78 Dependencies</bridgehead>
90
91 <bridgehead renderas="sect4">Required</bridgehead>
92 <para role="required">
93 <xref linkend="autoconf213"/>,
94 <xref linkend="icu"/>,
95 <xref linkend="rust"/>, and
96 <xref linkend="which"/>
[5d0f53c0]97 <!-- Should we list llvm here? -->
[fcce89bc]98 </para>
99
100 <!-- It seems nasm is only used for aarch64-win64. -->
101 <!--bridgehead renderas="sect4">Optional</bridgehead>
102 <para role="optional">
103 <xref linkend="nasm"/>
104 </para-->
105
106 <para condition="html" role="usernotes">
107 User Notes: <ulink url="&blfs-wiki;/js78"/>
108 </para>
109 </sect2>
110
111 <sect2 role="installation">
112 <title>Installation of JS</title>
113
114 <note>
115 <para>
116 Unlike most other packages in BLFS, the instructions below require you
117 to untar <filename>firefox-&ff78-version;esr.tar.xz</filename> and
118 change into the <filename>firefox-&ff78-version;</filename> folder.
119 </para>
120
121 <para>
122 Extracting the tarball
123 will reset the permissions of the current directory to 0755 if you
124 have permission to do that. If you do this in a directory where
125 the sticky bit is set, such
126 as <filename class="directory">/tmp</filename> it will end with error
127 messages:
128 </para>
129
130<literallayout>tar: .: Cannot utime: Operation not permitted
131tar: .: Cannot change mode to rwxr-xr-t: Operation not permitted
132tar: Exiting with failure status due to previous errors
133</literallayout>
134
135 <para>
136 This does finish with non-zero status, but it does
137 <emphasis>NOT</emphasis> mean there is a real problem.
138 Do not untar as the <systemitem class="username">root</systemitem> user
139 in a directory where the sticky bit is set - that will unset it.
140 </para>
141
142 </note>
143
[5d0f53c0]144<!-- It's merged in 78.2.0.
[fcce89bc]145 <para>
146 Apply a patch required by <xref linkend="gjs"/>:
147 </para>
148
149<screen><userinput>patch -Np1 -i ../js78-code_coverage-1.patch</userinput></screen>
[5d0f53c0]150-->
[fcce89bc]151 <para>
152 Install <application>JS</application> by running the following
153 commands:
154 </para>
155
156 <note>
157 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
158 href="../../xincludes/mozshm.xml"/>
159
160 <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
161 href="../../xincludes/mozconfigure.xml"/>
[ca73053a]162
163 <para>
164 Compiling the C++ code respects $MAKEFLAGS and defaults to 'j1',
165 the rust code will use all processors.
166 </para>
[fcce89bc]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>
[6a5717b]184 To run JS test suite, issue:
185 <command>make -C js/src check-jstests
186 JSTESTS_EXTRA_ARGS="--timeout 300 --wpt=disabled"</command>.
187 It's recommended to redirect the output into a log.
188 <!-- recheck when ICU gets upgraded -->
[393517d3]189 <!-- ken: removed "are known to fail' becasue there are
190 4096 known failures, these icu items are unexpected failures
191 and I found the wording confusing -->
[27a7cc5]192 <!-- ken : For 78.4 this was 14 failures, I changed it to 10 for 78.5.
193 On that machine with 78.6 still 10, but on another 14, both with similar
194 setup and locale. -->
195 Depending on the machine, either
196 ten or fourteen JS tests related to locale and timezone fail,
[ca73053a]197 because of an issue with recent versions of <xref linkend="icu"/>.
[393517d3]198 To run the JIT test suite, issue:
[fcce89bc]199 <command>make -C js/src check-jit-test
[ca73053a]200 JITTEST_EXTRA_ARGS="--timeout 300"</command>.
[fcce89bc]201 </para>
202
[55a63862]203 <caution>
204 <para>
205 An issue in the installation process causes any running program which
206 links to JS78 shared library (for example, GNOME Shell) to crash if
207 JS78 is upgraded or reinstalled. To work around this issue, remove
208 the old version of the JS78 shared library before installation:
209 </para>
[4af651f7]210
211<screen role="root"><userinput>rm -fv /usr/lib/libmozjs-78.so</userinput></screen>
[55a63862]212 </caution>
[4af651f7]213
[fcce89bc]214 <para>
215 Now, as the <systemitem class="username">root</systemitem> user:
216 </para>
217
218<screen role="root"><userinput>make install &amp;&amp;
219rm -v /usr/lib/libjs_static.ajs &amp;&amp;
[84283d4]220sed -i '/@NSPR_CFLAGS@/d' /usr/bin/js78-config</userinput></screen>
[fcce89bc]221
222 </sect2>
223
224 <!-- Several gjs-1.65.90 tests fail with js78. Not sure why.
225 OTOH an "otherwise" GNOME-3.36 environment works fine. -->
226
227 <sect2 role="commands">
228 <title>Command Explanations</title>
229
230 <para>
231 <envar>CC=gcc CXX=g++</envar>: Upstream now prefers
232 <application>clang</application>, override it like other Mozilla
233 packages in BLFS book.
234 </para>
235
236 <para>
237 <parameter>--with-*</parameter>: These parameters allow the build system
238 to use system versions of the above libraries. These are required for
239 stability.
240 </para>
241
242 <para>
243 <parameter>--enable-readline</parameter>: This switch enables Readline
244 support in the JS shell.
245 </para>
246
247 <para>
248 <parameter>--disable-jemalloc</parameter>: This switch disables the
[50d9ed6]249 internal memory allocator used in JS78. jemalloc is only intended for
250 the Firefox browser environment. For other applications using JS78,
251 if JS78 uses jemalloc, the application may crash as items allocated
252 in jemalloc allocator are freed on system (glibc) allocator.
[fcce89bc]253 </para>
254
255 <para>
256 <parameter>--disable-debug-symbols</parameter>: Don't generate debug
257 symbols since they are very large and most users won't need it. Remove
258 it if you want to debug JS78.
259 </para>
260
261 <para>
262 <command>rm -v /usr/lib/libjs_static.ajs</command>: Remove a large
263 static library which is not used by any BLFS package.
264 </para>
265
266 <para>
[84283d4]267 <command>sed -i '/@NSPR_CFLAGS@/d' /usr/bin/js78-config</command>:
268 Prevent <command>js78-config</command> from using buggy CFLAGS.
[fcce89bc]269 </para>
270
271 </sect2>
272
273 <sect2 role="content">
274 <title>Contents</title>
275
276 <segmentedlist>
277 <segtitle>Installed Programs</segtitle>
278 <segtitle>Installed Libraries</segtitle>
279 <segtitle>Installed Directories</segtitle>
280
281 <seglistitem>
282 <seg>
283 js78 and js78-config
284 </seg>
285 <seg>
286 libmozjs-78.so
287 </seg>
288 <seg>
289 /usr/include/mozjs-78
290 </seg>
291 </seglistitem>
292 </segmentedlist>
293
294 <variablelist>
295 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
296 <?dbfo list-presentation="list"?>
297 <?dbhtml list-presentation="table"?>
298
299 <varlistentry id="js6-js78">
300 <term><command>js78</command></term>
301 <listitem>
302 <para>
303 provides a command line interface to the
[4c24eb0a]304 <application>JavaScript</application> engine
[fcce89bc]305 </para>
306 <indexterm zone="js78 js78">
307 <primary sortas="b-js78">js78</primary>
308 </indexterm>
309 </listitem>
310 </varlistentry>
311
312 <varlistentry id="js78-config">
313 <term><command>js78-config</command></term>
314 <listitem>
315 <para>
[4c24eb0a]316 is used to find the JS compiler and linker flags
[fcce89bc]317 </para>
318 <indexterm zone="js78 js78-config">
319 <primary sortas="b-js78-config">js78-config</primary>
320 </indexterm>
321 </listitem>
322 </varlistentry>
323
324 <varlistentry id="libmozjs-78">
325 <term><filename class="libraryfile">libmozjs-78.so</filename></term>
326 <listitem>
327 <para>
[4c24eb0a]328 contains the Mozilla JavaScript API functions
[fcce89bc]329 </para>
330 <indexterm zone="js78 libmozjs-78">
331 <primary sortas="c-libmozjs78">libmozjs-78.so</primary>
332 </indexterm>
333 </listitem>
334 </varlistentry>
335 </variablelist>
336 </sect2>
[4c24eb0a]337
[fcce89bc]338</sect1>
Note: See TracBrowser for help on using the repository browser.