source: general/genlib/js68.xml@ b0eb7c40

10.0 10.1 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 b0eb7c40 was b0eb7c40, checked in by Xi Ruoyao <xry111@…>, 4 years ago

js68: reword the alert about GNOME crash

Now it seems unneeded to reinstall gjs. And, polkit is still using js60.

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

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