How To Install jruby on Debian 9
Introduction
In this tutorial we learn how to install jruby
on Debian 9.
What is jruby
jruby is:
JRuby is a high performance, stable, fully threaded Java implementation of the Ruby programming language.
JRuby is tightly integrated with Java to allow the embedding of the interpreter into any Java application with full two-way access between the Java and the Ruby code (similar to Jython for the Python language).
JRuby provides a complete set of core “builtin” classes and syntax for the Ruby language, as well as most of the Ruby Standard Libraries. The standard libraries are mostly Ruby’s own complement of “.rb” files, but a few that depend on C language-based extensions have been reimplemented. Some are still missing, but JRuby hopes to implement as many as is feasible.
There are three methods to install jruby
on Debian 9. We can use apt-get
, apt
and aptitude
. In the following sections we will describe each method. You can choose one of them.
Install jruby Using apt-get
Update apt database with apt-get
using the following command.
sudo apt-get update
After updating apt database, We can install jruby
using apt-get
by running the following command:
sudo apt-get -y install jruby
Install jruby Using apt
Update apt database with apt
using the following command.
sudo apt update
After updating apt database, We can install jruby
using apt
by running the following command:
sudo apt -y install jruby
Install jruby Using aptitude
If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Debian. Update apt database with aptitude
using the following command.
sudo aptitude update
After updating apt database, We can install jruby
using aptitude
by running the following command:
sudo aptitude -y install jruby
How To Uninstall jruby on Debian 9
To uninstall only the jruby
package we can use the following command:
sudo apt-get remove jruby
Uninstall jruby And Its Dependencies
To uninstall jruby
and its dependencies that are no longer needed by Debian 9, we can use the command below:
sudo apt-get -y autoremove jruby
Remove jruby Configurations and Data
To remove jruby
configuration and data from Debian 9 we can use the following command:
sudo apt-get -y purge jruby
Remove jruby configuration, data, and all of its dependencies
We can use the following command to remove jruby
configurations, data and all of its dependencies, we can use the following command:
sudo apt-get -y autoremove --purge jruby
Dependencies
jruby have the following dependencies:
- default-jre
- ant
- junit4
- libasm-java
- libbsf-java
- libbytelist-java
- libheadius-options-java
- libinvokebinder-java
- libjansi-java
- libjcodings-java
- libjffi-jni
- libjoda-time-java
- libjnr-constants-java
- libjnr-enxio-java
- libjnr-ffi-java
- libjnr-netdb-java
- libjnr-posix-java
- libjnr-unixsocket-java
- libjnr-x86asm-java
- libjruby-joni-java
- libjzlib-java
- libosgi-core-java
- libunsafe-mock-java
- libyaml-snake-java
- nailgun
- libyecht-java
References
Summary
In this tutorial we learn how to install jruby
package on Debian 9 using different package management tools: apt
, apt-get
and aptitude
.