| Version 11 (modified by , 3 years ago) ( diff ) |
|---|
Altre lingue:
Tavola dei contenuti
Questa pagina è una bozza, la traduzione è in corso
Scaricare
Questa pagina fornisce i passaggi di base per l'installazione di JOSM e le informazioni per la risoluzione dei problemi. Per iniziare a lavorare con JOSM, consulta le pagine Introduction e Help. E per questioni molto complesse vedi le Note d'Installazione (en).
Opzioni raccommandate
Avvia josm.jnlp (versione testata più recente)
Versione raccomandata, per tutte le piattaforme, aggiornata automaticamente, con cadenza mensile, alla più recente versione testata (how to start).
Scarica josm-tested.jar (versione testata 19439)
Tutte le piattaforme (how to run).
Tutte le opzioni di download
Ogni mese il team di JOSM rilascia (en) una versione testata per il download. Le varianti per MS Windows ed Apple macOS sono compilate su questa versione testata. Quando si clicca su josm.jnlp per lanciare JOSM, si otterrà sempre la versione testata più recente. Web Start (en) di Java è il meccanismo che lo rende possibile.
Ogni notte il sistema di compilazione genera un'ultima versione. Queste versioni possono contenere eroori anche gravi ma, di solito, funzionano bene. Per l'ultima versione è disponibile anche una variante Web Start.
| Per tutti i sistemi operativi | In sviluppo | ||||||
|---|---|---|---|---|---|---|---|
| Versione | Web Start | Download | Windows | Apple macOS | Ubuntu, Debian… | openSUSE | Jar / Javadoc / Source |
| testata 19439 | josm.jnlp | josm-tested.jar | josm-setup.exe josm-setup.msi Microsoft Store (vedi sotto) | JOSM macOS .zip package o (homebrew) | vedi sotto | vedi sotto | josm:19439 |
| latest 19473 | latest.jnlp | josm-latest.jar | vedi sotto | Usa gli snapshots | |||
| older | download/ | compilazioni automatiche della JOSM.app | pool/ | versioni testate | |||
Quando si avviano gli script si prega di controllare prima su ultima, testata o tutte per ridurre il consumo di banda in download.
Eliminare le traduzioni
Se la dimensione del download è un problema, sono disponibili file più piccoli della versione testata. Per i download contenenti solo inglese, aggiungi ?lang=en all'URL. Per includere una traduzione, sostituisci en con il codice della lingua (en) che desideri (primo carattere minuscolo, solo per le lingue supportate). È possibile ridurre ulteriormente le dimensioni del file eliminando le informazioni di firma aggiungendo ?unsigned=1.
Repository Linux
JOSM basato su Debian, principalmente per Ubuntu
Questo è il nostro repository di pacchetti principalmente per Ubuntu. Dovrebbe funzionare anche con altre distribuzioni basate su Debian (soprattutto basate su Ubuntu), ma non testiamo e manteniamo attivamente alcuna distribuzione diversa da Ubuntu.
Il repository contiene due pacchetti:
- josm – Fornisce la versione testata (stabile). Sostituisce il pacchetto fornito dal repository ufficiale della tua distribuzione. Il nome predefinito delle cartelle JOSM è impostato su
JOSM. - josm-latest – L'ultima versione (nightly). Può essere installata parallelamente al pacchetto josm, perchè il nome predefinito delle cartelle di questa versione JOSM è impostato su
JOSM-latest.
Entrambi i pacchetti forniscono rispettivamente /etc/default/josm e /etc/default/josm-latest come file di configurazione per le opzioni java (en).
Oltre alla normale procedura descritta di seguito, i DEB precedenti possono essere scaricati manualmente dagli archivi dei file.
Installazione
Modifica la lista delle risorse dei pacchetti /etc/apt/sources.list.d/josm.list:
sudo editor /etc/apt/sources.list.d/josm.list
ed aggiungi una delle linee seguenti in base alla tua versione di Ubuntu:
deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt lunar universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt kinetic universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt jammy universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt impish universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt hirsute universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt groovy universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt focal universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt eoan universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt disco universe deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt bionic universe # Per le altre distribuzioni basate su Debian aggiungi: deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt alldist universe
In alternativa, tutto ciò può essere fatto in Ubuntu con la seguente linea di comando unica (non per le distribuzioni basate su Ubuntu tipo Linux Mint):
echo "deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt $(lsb_release -sc) universe" | sudo tee /etc/apt/sources.list.d/josm.list > /dev/null
o per Linux Mint:
echo "deb [signed-by=/usr/local/share/keyrings/josm-apt.gpg] https://josm.openstreetmap.de/apt $(grep ^DISTRIB_CODENAME= /etc/upstream-release/lsb-release| awk -F = '{print $(2)}') universe" | sudo tee /etc/apt/sources.list.d/josm.list > /dev/null
Scarica la chiave pubblica:
# Creare la cartella per le chiavi scaricate manualmente se non è già stata creata sudo mkdir -p /usr/local/share/keyrings # Scarica la chiave wget -q https://josm.openstreetmap.de/josm-apt.key -O- | sudo gpg --dearmor -o /usr/local/share/keyrings/josm-apt.gpg
In passato, era usata l'istruzione apt-key. Se la chiave è stata aggiunta al portachiavi di sistema, la linea di comando seguente la rimuoverà:
sudo apt-key del $(apt-key list | grep -B1 "<josm-dev@openstreetmap.org>" | sed '$d' | cut -b 48-51,53-57)
Ora aggiorna i sorgenti dei pacchetti:
# Prima potresti aver bisogno di installare il supporto ssl per apt: sudo apt-get install apt-transport-https # Aggiorna i sorgenti sudo apt-get update
ed installa:
# Puoi saltare questa prima linea se questi pacchetti non sono mai stati installati. sudo apt-get remove josm josm-plugins # Per la versione testata sudo apt-get install josm # Per la versione in sviluppo sudo apt-get install josm-latest
GNU Debian
I nostri pacchetti Ubuntu, vedi su, funzionano su Debian e noi ne consigliamo l'uso. In base al setup di sudo, alcune istruzioni non funzioneranno come utente "normale" ma solo root.
A partire da Debian 11 (bullseye) il josm-installer è disponibile sotto main nella sezione utils. Esso scaricail file .jar attuale da questo sito e lo aggiorna se necessario.
La versione testata di JOSM è disponibile sotto main nella sezione utils, ma la versione di solito è piuttosto vecchia.
Usare il backports repository per ottenere una versione più aggiornata, vedere le Istruzioni. Anche questa versione potrebbe essere piuttosto vecchia.
openSUSE
La versione testata di JOSM è disponibile nel repository the Application:Geo.
Per prima cosa aggiungere come utente root in yast o con zypper il repository (per Tumbleweed sostituire $releasever con openSUSE_Tumbleweed):
zypper ar -f 'https://download.opensuse.org/repositories/Application:/Geo/$releasever' Application:Geo
Quindi installare semplicemente i pacchetti josm e josm-fonts.
Risoluzione dei problemi
Java
When you double-click on a jar file and nothing happens in most cases this means Java isn't installed.
JOSM was tested with Oracles variant, so we used to recommend getting Java from their pages for manual downloads or intermediate versions.
JOSM now recommends Azul or Bellsoft Liberica JDK's. Generally speaking, the current Java LTS should be preferred (at time of writing, that would be Java 17), but Java 8 will work. See the README for current recommendations. But first give the Java already distributed with the operating system a try, for example.
When choosing a download keep in mind:
- A Java Plug-in for web browsers is not needed to run JOSM. Therefore results from pages like www.java.com/en/download/installed8.jsp are not relevant.
- A Java variant with 64 bit is recommended for JOSM. The operating systems architecture is important for deciding between 32 bit Java or 64 bit Java. Because JOSM is not affected by the web browsers architecture most recommendations on this page www.java.com/en/download/faq/java_win64bit.xml are not relevant.
- Avoid pages like www.java.com/en/download which intent to place Java Plug-ins in web browsers. And this is not important for JOSM.
For further information visit the Installation Notes and troubleshooting pages. Java in this section means a JRE (Java Runtime Engine) which provides a JVM (Java Virtual Machine) to run JOSM, a Java program that is developed using JDK (Java Development Kit) and sometimes launched with the JNLP (Java Network Launch Protocol aka Web Start and successor of Java Plug-ins).
Testare Java
Checks if Java is installed and why JOSM does not start (example mainly for MS Windows).
- Download josm-tested.jar to your desktop.
- Open a Command Prompt aka Terminal
- Type
cd %homepath%⏎ and typecd Desktop⏎ - Type
java -version⏎ Three lines with the version data should appear. If you see something else then Java is not properly installed. - Type
java -jar josm-tested.jar⏎. Now JOSM should run, started from the Command Line (en). - Quit JOSM.
- Type
josm-tested.jar⏎. If JOSM starts again, the Windows Explorer is ready for double clicks on jar files.
Web Start
You need to install OpenWebStart first. It will download and run Java by itself. The transition from Oracle WebStart to OpenWebStart is still in progress, so in case of issue please create a new ticket or post a comment to #17858.
You may need to update the default application for opening JNLP files if you previously used Oracle WebStart. See jnlp file association for instructions on setting OpenWebStart as the default program for jnlp files.
Testare Web Start
- Download josm.jnlp to your desktop.
- Open a Terminal and move to the Desktop as above
- Type
javaws josm.jnlp⏎. This should initially download JOSM, show a security dialog and then launch JOSM. - If that fails, then type
javaws -verbose josm.jnlp⏎. This should first show a dialog with information about the JVM and then launch JOSM.
Macchina Virtuale
Out of memory
Nowadays manually controlling Javas memory is seldom needed because available RAM on computers has grown. Wrongly chosen values can decrease JOSM performance.
For some tasks, JOSM has a large appetite for memory. On the one hand, it may be necessary to configure a memory size that supports more plugins and features. On the other hand can slow machines be stabilized by restricting Javas memory use.
If needed, use the command line (en) to set the Java Option -Xmx…m, for example -Xmx512m or -Xmx1536m. In Debian/Ubuntu you can edit the file /etc/default/josm respectively /etc/default/josm-latest.
Formerly older java programs accepted -Xmx=512m or even -Xmx 512m. Now those malformed arguments throw error messages.
VM selection
On current versions of MS Windows by default Java is installed mainly in the C:\Program Files\Java\ directory. Additional parts are placed in C:\Program Files\Oracle\Java\. There is a .\javapath\ directory as target for the PATH environment variable. It is the home for the three virtual files java.exe, javaw.exe and javaws.exe. This files are symbolic links form the current Java installations.
On older versions of 64 bit Windows sometimes the 32 bit mode JRE was additionally installed. Also some browsers brought their own JVM with limited capabilities. In those cases a Web Start from the browser would not use your Java installation but that from the browser.
Check that there's no other javawebstart in \Windows\SysWow64. The Java control panel will not detect it and you can safely delete it. Perform cleanup and only keep the latest versions of each JRE (One or the 32-bit mode, another one for the 64-bit mode).
For shortcuts created on the desktop for JNLP and running the Javawebstart launcher , make sure to pass VM parameters prefixed with -J and no intermediate space before the VM option. If you have installed both the 32-bit and 64-bit version, you should pass the option "-d64" if you want to select the preferred 64-bit VM. Note that some Oracle documentation pages indicate the option "-D64" with the incorrect capitalization!)
Example of an edited command line for a shortcut on the windows desktop:
javaws.exe -J-d64 -J-Xmx2048m josm.jnlp
Windows josm.exe
Usando josm-setup.exe per l'installazione su Microsoft Windows si verificano le seguenti azioni:
- I due file eseguibili
JOSM.exeeHWConsole.exesono installati nella cartella%LOCALAPPDATA%\JOSM - JOSM.exe è registrato come programma predefinito per le estensioni di file
*.osm,*.geojson,*.gpx,*.josand*.joz. - Le icone di collegamento a JOSM sono inserite sul Desktop e nel Menu Start.
- I dati di disinstallazione sono inseriti nei punti appropriati.
Quando si lancia JOSM.exe viene avviato JOSM con una versione incorporata di Java mantenuta dagli sviluppatori di JOSM, basata su Azul Zulu. JOSM.exe agisce come un contenitore ed è portatile (en).
HWConsole.exe è simile a JOSM.exe ma avvia JOSM aprendo una console Windows che mostra i messaggi standard di JOSM (logs).
JOSM.exe accetta tutti i consueti argomenti di programma JOSM (en). Vedere ad esempio:
# Caricare i dati OSM josm.exe https://www.osm.org/way/476702262
Per passare le opzioni Java (en) alla VM Java, JOSM.exe usa il file di configurazione JOSM.cfg nella sotto-cartella della sua app. In questo file ogni opzione richiede una linea separata.
macOS
Usindo il gestore brew
Gli utenti macOS possono usare il gestore di pacchetti homebrew per installare ed aggiornare la loro versione JOSM.
Nel Terminale, esegui brew install --cask josm per installare o brew upgrade --cask josm per aggiornare l'attuale versione testata di JOSM.
Problemi noti
Problemi non risolti riguardanti …:


