HowToBuildStendhal: Difference between revisions

Content deleted Content added
imported>AntumDeluge
→Gradle: optional install instructions
imported>AntumDeluge
→Node.js: install instructions
Line 110:
<pre>
$ brew install ant
</pre>
 
 
== Node ==
 
[https://nodejs.org/en Node.js] is the system used for building the Stendhal web client. Like other tools, Node.js build commands can be executed directly. But it is recommended to use the appropriate Ant wrapper command.
 
When Node is installed, the commands <span style="color:darkred;">''node''</span>, <span style="color:darkred;">''npm''</span> (Node Package Manager), and <span style="color:darkred;">''npx''</span> (Node Package Executor) will be available. Optionally, from the Stendhal source code root directory, you can execute <span style="color:darkred;">''npm install --no-package-lock''</span> to install the required Node modules. If you do not, they will automatically be installed when you execute any build instructions for a component that uses the Node build system (such as the web client).
 
In addition to the instructions below, the [https://nodejs.org/en/download download page] includes instructions on how to install/manage Node using the Node Version Manager (NVM) for common desktop systems.
 
=== Node on Unix ===
 
Most Unix/Linux/BSD distributions have a version of Node available from the default package manager.
 
Example of installing on Ubuntu:
<pre>
$ sudo apt install nodejs ant
</pre>
 
Example of installing on Arch:
<pre>
$ sudo pacman -S nodejs npm
</pre>
 
Example of installing on FreeBSD:
<pre>
# install pre-built version 24 package
$ sudo pkg install node24
 
# compile version 24 from Ports source
$ cd /usr/ports/www/node24
$ sudo make install clean
</pre>
 
=== Node on Windows ===
 
Node for Windows can be downloaded as an installer or portable .zip package from the [https://nodejs.org/en/download download page] (.zip requires manual configuration of environment variables). It is also available from the Windows Package Manager.
 
Example of installing on Windows using WinGet:
<pre>
> winget install OpenJS.NodeJS.LTS
</pre>
 
=== Node on macOS ===
 
Node for macOS can be downloaded as an installer or portable .zip package from the [https://nodejs.org/en/download download page] (.zip requires manual configuration of environment variables). It is also available from Homebrew.
 
Example of installing on macOS using Homebrew:
<pre>
$ brew install node
</pre>