Skip to content

docs: update njs build instructions #154

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jun 17, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 10 additions & 15 deletions source/howto/source.rst
Original file line number Diff line number Diff line change
Expand Up @@ -115,29 +115,24 @@ revision numbers, respectively); omit the packages you won't use.
:hash: source-njs

To build Unit with `njs <https://nginx.org/en/docs/njs/>`__ support,
download the :program:`njs` code
to the same parent directory
download the :program:`njs` code to the same parent directory
as the Unit code.

If you'd like to use `Mercurial <https://www.mercurial-scm.org/downloads>`_:
**0.8.2** is the latest version of :program:`njs` that Unit supports.
Make sure you are in the correct branch before configuring the binaries.

.. code-block:: console
$ cd ..
$ hg clone https://hg.nginx.org/njs
If you prefer `Git <https://git-scm.com/downloads>`_:

.. code-block:: console
$ cd ..
$ git clone https://github.com/nginx/njs
$ git clone https://github.com/nginx/njs.git
$ cd njs
$ git checkout -b 0.8.2 0.8.2
Next, configure and build the :program:`njs` binaries:
Next, configure and build the :program:`njs` binaries. Make sure to use the
`--no-zlib` and `--no-libxml2` options to avoid
conflicts with Unit's dependencies:

.. code-block:: console
$ cd njs
$ ./configure :nxt_hint:`--no-zlib --no-libxml2 <Ensures Unit can link against the resulting library>` && make
Point to the resulting source and build directories when :ref:`configuring
Expand Down Expand Up @@ -166,7 +161,7 @@ revision numbers, respectively); omit the packages you won't use.
.. warning::
The **unit-wasm** module is deprecated.
We recommend using **wasm-wasi-component** instead,
available in Unit 1.32.0 and later, which supports
available in Unit 1.32.0 and later, which supports
WebAssembly Components using standard WASI 0.2 interfaces.

To build Unit with the `WebAssembly <https://webassembly.org>`__
Expand Down