GNU/Linux >> Tutoriels Linux >  >> Linux

Comment installer Erlang sur ArchLinux

Dans ce guide, nous allons installer Erlang/OTP sur ArchLinux.

Contenu associé

  • Comment installer RabbitMQ dans Fedora 35
  • Comment installer Erlang sur Rocky Linux/Alma Linux/CentOS 8
  • Comment installer Rabbitmq dans Rocky Linux/Alma Linux/Centos 8

Prérequis

Vous avez besoin des éléments suivants pour suivre

  • Serveur/poste de travail ArchLinux mis à jour
  • Accès root ou utilisateur avec accès root
  • Accès Internet depuis le serveur

Table des matières

  1. Mise à jour du système
  2. Installer Erlang
  3. Création du programme Hello world

1. Mise à jour du système

Assurons-nous que nos packages de serveur sont à jour en utilisant cette commande :

sudo pacman -Syyu

Installons également quelques packages courants

sudo pacman -S vim

2. Installer Erlang

Installez erlang avec pacman :

sudo pacman -S erlang

3. Création du programme Hello world

Créer hello.erl fichier

vim hello.erl

Ajoutez ceci au fichier

% This is a test Hello World Erlang Code
-module(hello).
-import(io,[fwrite/1]).
-export([helloworld/0]).

helloworld() ->
   fwrite("Hello from Citizix, Erlang World!\n").

Compilez-le à partir du shell Erlang. N'oubliez pas le point ("point") à la fin de chaque commande :

$ erl
/usr/lib/erlang/erts-12.1.5/bin/beam.smp: /usr/lib/libncursesw.so.6: no version information available (required by /usr/lib/erlang/erts-12.1.5/bin/beam.smp)
Erlang/OTP 24 [erts-12.1.5] [source] [64-bit] [smp:2:2] [ds:2:2:10] [async-threads:1] [jit]

Eshell V12.1.5  (abort with ^G)
1> c(hello).
{ok,hello}
2> hello:helloworld().
Hello from Citizix, Erlang World!
ok
3>

Vous avez installé avec succès Erlang sur votre système.

Conclusion

Merci d'avoir utilisé ce tutoriel pour installer le langage de programmation Erlang sur votre système Arch Linux. Pour obtenir de l'aide supplémentaire ou des informations utiles, nous vous recommandons de consulter le site Web officiel d'Erlang.


Linux
  1. Comment installer le langage de programmation Erlang sur Debian 10

  2. Comment installer Erlang sur Debian 10

  3. Comment installer Erlang sur CentOS 8

  4. Comment installer Erlang sur Ubuntu 16.04 LTS

  5. Comment installer RabbitMQ Server et Erlang sous Linux

Comment installer Mono sur Debian 10

Comment installer le serveur RabbitMQ sur CentOS 7

Comment installer OmniOS ce

Comment installer et configurer RabbitMQ dans Archlinux

Comment installer GCC sur Debian 11

Comment installer FreeNAS 11.1