#### Beyond Linux® From Scratch (System V Edition) - Version r12.4-737

### Chapter 33. GNOME Libraries and Desktop

- Prev

  geocode-glib-3.26.4

- Next

  gnome-autoar-0.4.5

- Up
- Home

# Gjs-1.84.2

## Introduction to Gjs

Gjs is a set of Javascript bindings for GNOME.

### Note

Development versions of BLFS may not build or run some packages properly if LFS or dependencies have been updated since the most recent stable versions of the books.

### Package Information

- Download (HTTP): https://download.gnome.org/sources/gjs/1.84/gjs-1.84.2.tar.xz

- Download MD5 sum: 5083ed4dc52910eebbbfb17198d8ef8e

- Download size: 772 KB

- Estimated disk space required: 299 MB (with tests)

- Estimated build time: 0.2 SBU (with tests; with parallelism=4)

### Additional Downloads

- Required patch: https://www.linuxfromscratch.org/patches/blfs/svn/gjs-1.84.2-spidermonkey_140-1.patch

### Gjs Dependencies

#### Required

Cairo-1.18.4, dbus-1.16.2, GLib-2.86.2 (with GObject Introspection), and SpiderMonkey from Firefox-140.5.0

#### Optional (for tests)

GTK-3.24.51, GTK-4.20.3, and Valgrind-3.26.0

#### Optional

DTrace, LCOV, sysprof, and Systemtap

## Installation of Gjs

Apply a patch to allow building this package with SpiderMonkey 140:

    patch -Np1 -i ../gjs-1.84.2-spidermonkey_140-1.patch

Install Gjs by running the following commands:

    mkdir gjs-build &&
    cd    gjs-build &&

    meson setup --prefix=/usr          \
                --buildtype=release    \
                --wrap-mode=nofallback \
                ..                     &&
    ninja

To test the results, ensure both GTK-3.24.51 and GTK-4.20.3 are installed and issue: ninja test in a graphical session.

Now, as the `root` user:

    ninja install

## Command Explanations

`--buildtype=release`: Specify a buildtype suitable for stable releases of the package, as the default may produce unoptimized binaries.

`--wrap-mode=nofallback`: This switch prevents meson from using subproject fallbacks for any dependency declarations in the build files, preventing it from downloading any optional dependencies which are not installed on the system.

`-D profiler=disabled`: prevents building the profiler backend even if sysprof is installed.

## Contents

Installed Programs: gjs (symlink) and gjs-console
Installed Library: libgjs.so
Installed Directories: /usr/include/gjs-1.0, /usr/lib/gjs, /usr/libexec/installed-tests/gjs, /usr/share/gjs-1.0, and /usr/share/installed-tests/gjs

### Short Descriptions

gjs-console | contains a console to run JavaScript commands
`libgjs.so` | contains the GNOME JavaScript bindings

- Prev

  geocode-glib-3.26.4

- Next

  gnome-autoar-0.4.5

- Up
- Home