Attention: Here be dragons

This is the latest (unstable) version of this documentation, which may document features not available in or compatible with released stable versions of Godot.

Esportazione per Linux

Vedi anche

Questa pagina descrive come esportare un progetto Godot per Linux. Se si desidera invece compilare i binari dell'editor o dei modelli di esportazione dal codice sorgente, consultare Compilare per Linux, *BSD.

Il modo più semplice per distribuire un gioco per PC è copiare l'eseguibile (godot), comprimere la cartella e inviarla a qualcun altro. Tuttavia, spesso questo non è desiderato.

Godot offre un approccio più elegante per la distribuzione su PC quando si utilizza il sistema di esportazione. Quando si esporta per Linux, l'esportatore prende tutti i file del progetto e crea un file data.pck. Questo file è impacchettato in un binario appositamente ottimizzato, più piccolo, più rapido e non contiene l'editor e il debugger.

Architettura

There are 7 different processor architectures that exported Godot projects can run on in Linux:

  • x86_64

  • x86_32

  • arm64

  • arm32

  • rv64

  • ppc64

  • loongarch64

The default is x86_64, this is the most common architecture of PC processors today. All modern Intel and AMD processors as of writing this are x86_64.

x86_32 will give you a 32bit executable that can run on 32bit only distributions of Linux as well as some modern distributions that are 64bit. It is NOT recommended to use this option unless you are trying to get your project to run on an old 32bit distribution and processor. It should also be noted that several prominent distributions, such as Fedora, have been discussing removing their 32bit libraries which would prevent executables made this way from running on future versions of that distribution.

arm64 executables can run on 64bit ARM processors. If you're familiar with the Raspberry Pi, those have utilized 64bit ARM processors since the Pi 3 (older versions used 32bit ARM processors). If you're uploading to a platform that supports multiple executables, such as itch.io, and you're confident your game could run on a common ARM computer, such as the Pi 5, then we'd recommend exporting this version and providing it as an option.

arm32 executables are for older 32bit arm processors, such as what the Raspberry Pi 1 and 2 used. Given that they're not common at all these days we do not recommend exporting for this unless you have a computer with one of these processors you know you can, and want to have your game running on.

rv64 is for RISC-V processors, ppc64 is for 64bit PowerPC processors, and loongarch64 is for 64bit LoongArch processors. All of these architectures are substantially more niche when it comes to running videogames on them. And we only recommend exporting for them if you have a reason to, such as if you're an enthusiast who owns hardware. Official export templates are not provided by Godot, you will have to create them on your own. Instructions for compiling the engine for RISC-V and creating export templates can be found on the Compilare per Linux, *BSD page.

Variabili d'ambiente

È possibile utilizzare le seguenti variabili d'ambiente per impostare le opzioni di esportazione al di fuori dell'editor. Durante il processo di esportazione, queste variabili sovrascrivono i valori impostati nel menu di esportazione.

Variabili d'ambiente per esportazione su Linux

Opzioni di esportazione

Variabile d'ambiente

Crittografia / Chiave crittografica

GODOT_SCRIPT_ENCRYPTION_KEY

Opzioni di esportazione

È possibile trovare un elenco completo delle opzioni di esportazione disponibili nel riferimento alla classe EditorExportPlatformLinuxBSD.