Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédenteProchaine révisionLes deux révisions suivantes |
fr:howtos:software:java [2015/09/11 14:21 (UTC)] – [Oracle Java] traduction [fr] cedric | fr:howtos:software:java [2018/01/13 16:43 (UTC)] – [OpenJDK] traduction cedric |
---|
<note important>N'installez pas les deux et veillez à désinstaller les précédentes versions de Java avant de commencer l’installation d'une nouvelle version.</note> | <note important>N'installez pas les deux et veillez à désinstaller les précédentes versions de Java avant de commencer l’installation d'une nouvelle version.</note> |
| |
==== Java (JDK) Installation on Slackware 14 and newer ==== | ==== Installation de Java (JDK) sur Slackware 14 et supérieure ==== |
| |
Follow the steps below to install Java on your system: | Suivez les étapes ci-dessous pour installer Java sur votre système: |
| |
1. Visit the official [[http://www.oracle.com/technetwork/java/javase/downloads/index.html|download page]]. | 1. Visitez la [http://www.oracle.com/technetwork/java/javase/downloads/index.html|page de téléchargement]] du site officiel. |
| |
2. Right under //Java Platform, Standard Edition// click the //JDK Download// and accept the license agreement. | 2. Sous //Java Platform, Standard Edition// cliquez sur //JDK Download// et accepter la licence. |
| |
3. Download a binary package that is appropriate for your architecture: | 3. Téléchargez le binaire correspondant à votre architecture: |
| |
''Linux x86'' for a 32-bit version of Slackware.\\ | ''Linux x86'' pour une version Slackware 32-bit.\\ |
''Linux x64'' for a 64-bit version of Slackware. | ''Linux x64'' pour une version Slackware 64-bit. |
| |
Make sure you have chosen the **.tar.gz** version. | Veillez à sélectionner la version **.tar.gz**. |
| |
At the time of writing this, the latest version (64-bit) was: | A la rédaction de ceta rticle, la dernière version (64 bits) est: |
| |
<code>jdk-7u7-linux-x64.tar.gz</code> | <code>jdk-7u7-linux-x64.tar.gz</code> |
| |
4. In a terminal log in as root: | 4. Dans une fenêtre de terminal, loggez vous en root: |
| |
<code>su -</code> | <code>su -</code> |
| |
5. Go to the ''/extra/source/java'' directory on a Slackware installation DVD or change to the local directory if you downloaded it from a Slackware mirror (in which case, //don't forget to download **all** the files and subdirectories in that "''java''"directory!//). | 5. Allez dans le répertoire ''/extra/source/java'' du DVD d’installation de la Slackware ou placez-vous dans le répertoire dans lequel vous téléchargé le binaire si vous l'avez téléchargé depuis un site miroir, auquel cas, //N'oubliez pas de télécharger **tous** les fichiers du sous-répertoire "''java''"!//). |
| |
6. Run the java SlackBuild specifying the path to the downloaded Java binary package. | 6. Exécuter le SlackBuild java en indiquant l'emplacement du binaire Java que vous avez téléchargé. |
| |
<code>./java.SlackBuild /path/to/jdk-7u7-linux-x64.tar.gz</code> | <code>./java.SlackBuild /path/to/jdk-7u7-linux-x64.tar.gz</code> |
| |
Once the SlackBuild finishes, you should get a similar message: | Quand le SlackBuild a terminé, vous devriez avoir un message du genre: |
| |
<code>Slackware package /tmp/jdk-7u7-x86_64-1.txz</code> | <code>Slackware package /tmp/jdk-7u7-x86_64-1.txz</code> |
| |
<note>If you get the following message, you can disregard it.\\ //WARNING: zero length file usr/lib64/java/lib/security/trusted.libraries//</note> | <note>Si vous obtenez ce message, vous pouvez l'ignorer.\\ //ATTENTION: le fichier usr/lib64/java/lib/security/trusted.libraries à une taille nulle//</note> |
| |
7. Install the newly created package: | 7. Installez le nouveau paquet nouvellement créé: |
| |
<code>upgradepkg --install-new /tmp/jdk-7u7-x86_64-1.txz</code> | <code>upgradepkg --install-new /tmp/jdk-7u7-x86_64-1.txz</code> |
| |
8. Restart a web browser and try if Java has been detected by visiting the following [[http://www.java.com/en/download/installed.jsp|website]]. | 8. Démarrez un navigateur web et vérifiez que Java est détecté en visitant le lien suivant [[http://www.java.com/en/download/installed.jsp|website]]. |
| |
9. You may need to reboot the computer for the system to recognize Java: | 9. Vous devrez redémarrer votre machine pour que l'instalaltion de Java soit pris en compte: |
| |
<code>$ which java | <code>$ which java |
/usr/lib64/java/bin/java</code> | /usr/lib64/java/bin/java</code> |
| |
10. If you want [[slackware:slackpkg|slackpkg]] to ignore the jre and jdk packages on clean-system, add them to the blacklist in ''/etc/slackpkg/blacklist'' | 10. Si vous voulez que [[slackware:slackpkg|slackpkg]] ignore les paquets jre et jdk lors d'un clean-system, ajoutez les à la liste noire ''/etc/slackpkg/blacklist'' |
| |
| |
===== OpenJDK ===== | ===== OpenJDK ===== |
| |
If you prefer the fully Open Source alternative of OpenJDK instead of Oracle's pre-compiled and partly closed-source binaries, then you can get sources, SlackBuild scripts and/or native Slackware packages here: [[http://slackware.com/~alien/slackbuilds/openjdk/|http://slackware.com/~alien/slackbuilds/openjdk/]]. | Si vous ne souhaitez pas utiliser les binaires précompilés et partiellement propriétaire d'Oracle, vous pouvez utiliser la version Opensource d'OpenJDK. Les sources, scripts SlackBuild et/ou les paquets natifs Slackware sont disponibles ici : [[http://slackware.com/~alien/slackbuilds/openjdk/|http://slackware.com/~alien/slackbuilds/openjdk/]]. |
| |
If you decide you want to use OpenJDK, the same rules apply that were written above for the Oracle Java packages: //only install one of the two, either JRE or JDK!// | Si vous décidez d'utiliser OpenJDK, suivez les mêmes règles qu'au chapitre précédent: //N'installez qu'une seule des deux versions, soit JRE, soit JDK!// |
If you want a web-browser plugin like Oracle's binaries have, then install the additional [[http://slackware.com/~alien/slackbuilds/icedtea-web|icedtea-web]] package. Oracle kept its browser plugin closed-source. The //icedtea-web// package is an open-source alternative.\\ You will also need [[http://slackware.com/~alien/slackbuilds/rhino|rhino]], the JavaScript engine for OpenJDK. | Si vous avez besoin d'un plugin pour votre navigateur comme dans le binaire Oracle, alors installez le paquet additionnel [[http://slackware.com/~alien/slackbuilds/icedtea-web|icedtea-web]]. Oracle ne propose son plugin qu'en version propriétaire. Le paquet //icedtea-web// est une alternative open-source.\\ Vous aurez également besoin de [[http://slackware.com/~alien/slackbuilds/rhino|rhino]], le moteur JavaScript pour OpenJDK. |
| |
If you decide you want to compile OpenJDK from source, then use the [[http://slackware.com/~alien/slackbuilds/openjdk/build/README.txt|README]] for guidance. | Si vous décidez de compiler OpenJDK depuis le code source, lisez le [[http://slackware.com/~alien/slackbuilds/openjdk/build/README.txt|README]] à titre indicatif. |
| |
| |