HowTo/Installing Trainz at Linux: Debian based Distributions: Difference between revisions

From TrainzOnline
Jump to navigationJump to search
Ek.skirl (talk | contribs)
No edit summary
Ek.skirl (talk | contribs)
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
==Ubuntu 24.4 LTS noble (Original posted as forum thread)==
See Trainz Forum Discussion Thread   
See Trainz Forum Thread   
"[https://forums.auran.com/threads/installing-and-running-trainz-at-linux-here-ubuntu-24-04-lts-noble.180950/post-2051072 Installing and running Trainz at Linux, here Ubuntu 24.04 LTS noble - post #1 and #3]" too.
"[https://forums.auran.com/threads/installing-and-running-trainz-at-linux-here-ubuntu-24-04-lts-noble.180950/post-2051072 Installing and running Trainz at Linux, here Ubuntu 24.04 LTS noble - post #1 and #3]"


==Ubuntu 24.4 LTS noble (Coy&pasted as source code from forum post as suggested in the forum thread)==
== Ubuntu 24.4 LTS noble ==
[HEADING=3]The idea[/HEADING]
=== The idea ===
This is a very old idea and often discussed. I searched for a systematic instruction, but I didn't find one. So I tried to test it and how it runs. Here's my personal systematic for Debian based Linux systems.
This is a very old idea and often discussed. I searched for a systematic instruction, but I didn't find one. So I tried to test it and how it runs. Here's my personal systematic for Debian based Linux systems.
For my knowledge such systems aren't able to execute windows programs (*.exe) out of the box. We need some helper apps. In my case I will use WineHQ from an external repository.
For my knowledge such systems aren't able to execute windows programs (*.exe) out of the box. We need some helper apps. In my case I will use WineHQ from an external repository.
[HEADING=3]Install WineHQ[/HEADING]
A useful instruction to do so is here (in German):[URL='https://wiki.ubuntuusers.de/Wine/#Fertige-Pakete']ubuntuusers.de Wine Fertige-Pakete[/URL] in sub chapter "Methode 2 - Wine-Fremdquelle". Maybe you want to use this script:
[SPOILER=Installation of WineHQ][CODE]
sudo dpkg --add-architecture i386    # Nur auf 64-Bit-Systemen notwendig.
sudo mkdir -pm755 /etc/apt/keyrings  # Ab 22.04 nicht mehr nötig.
sudo wget -nc -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
sudo wget -NP /etc/apt/sources.list.d/ "https://dl.winehq.org/wine-builds/ubuntu/dists/$(lsb_release -c | grep -o '\w*$')/winehq-$(lsb_release -c | grep -o '\w*$').sources"
sudo apt update
sudo apt install --install-recommends winehq-stable
[/CODE][/SPOILER]
The following chapter handles the installation of Trainz instances. The paths in the later following scripts are based on a collecting folder "Wine" in $USER.
[HEADING=3]Download and unpack the Trainz install files[/HEADING]
After downloading the full installer zip files
[LIST]
[*]TANE-SP4-Offline-Installer-105766.zip
[*]TRS19-SP4-Offline-Installer-114800.zip
[*]TRS22-Offline-Installer-126273.zip
[*]TrainzPlus-Offline-Installer-128486.zip
[/LIST]
and unpacking it into the sub folder looks like this:
[SPOILER=Folder structure][CODE]
$HOME/Wine/TRSDL/
+-- TANESP4_105766
|  +-- ...
|  +-- install.exe
|  +-- ...
+-- TRS19PE_114800
|  +-- ...
|  +-- install.exe
|  +-- ...
+-- TRS22PE_126273
|  +-- ...
|  +-- install.exe
|  +-- ...
+-- TRSPLUS_128486
    +-- ...
    +-- install.exe
    +-- ...
[/CODE][/SPOILER]
[HEADING=3]Install the Trainz instances[/HEADING]
We install every Trainz instance in its own wine prefix. The install statements of the following scripts create the wine prefixes ".TANESP4", ".TRS19PE", ".TRS22PE respective ".TRSPLUS" as hidden same named folders.
Every installation process creates two links at the desktop. I don't currently know the purpose of the link with the purple circle and a white arrow. The launch link for the Trainz instance with a Trainz icon and a small red dot with a white cross is blocked. By right-clicking it and using the "Allow launching" entry, it will be possible to launch Trainz.
Maybe you want to use one of this scripts to install a Trainz instance:
[SPOILER=Installation of TANESP4][CODE]
#!/bin/bash
#===============================================================================
# Installation of TANESP4 in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TANESP4 wine $HOME/Wine/TRSDL/TANESP4_105766/install.exe
#===============================================================================
[/CODE][/SPOILER]
[SPOILER=Installation of TRS19PE][CODE]
#!/bin/bash
#===============================================================================
# Installation TRS19PE in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRS19PE wine $HOME/Wine/TRSDL/TRS19PE_114800/install.exe
#===============================================================================
[/CODE][/SPOILER]
[SPOILER=Installation of TRS22PE][CODE]
#!/bin/bash
#===============================================================================
# Installation TRS22PE in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRS22PE wine $HOME/Wine/TRSDL/TRS22PE_126273/install.exe
#===============================================================================
[/CODE][/SPOILER]
[SPOILER=Installation of TRSPLUS][CODE]
#!/bin/bash
#===============================================================================
# Installation TRSPLUS in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRSPLUS wine $HOME/Wine/TRSDL/TRSPLUS_128486/install.exe
#===============================================================================
[/CODE][/SPOILER]
Good luck and have fun!
==Ubuntu 24.4 LTS noble (Coy&pasted as text from forum post as suggested in the forum thread)==
The idea
This is a very old idea and often discussed. I searched for a systematic instruction, but I didn't find one. So I tried to test it and how it runs. Here's my personal systematic for Debian based Linux systems.
For my knowledge such systems aren't able to execute windows programs (*.exe) out of the box. We need some helper apps. In my case I will use WineHQ from an external repository.
Install WineHQ
A useful instruction to do so is here (in German):ubuntuusers.de Wine Fertige-Pakete in sub chapter "Methode 2 - Wine-Fremdquelle". Maybe you want to use this script:
[SPOILER=Installation of WineHQ][CODE]
sudo dpkg --add-architecture i386    # Nur auf 64-Bit-Systemen notwendig.
sudo mkdir -pm755 /etc/apt/keyrings  # Ab 22.04 nicht mehr nötig.
sudo wget -nc -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
sudo wget -NP /etc/apt/sources.list.d/ "https://dl.winehq.org/wine-builds/ubuntu/dists/$(lsb_release -c | grep -o '\w*$')/winehq-$(lsb_release -c | grep -o '\w*$').sources"
sudo apt update


sudo apt install --install-recommends winehq-stable
=== Install WineHQ ===
A useful instruction to do so is here (in German): [https://wiki.ubuntuusers.de/Wine/#Fertige-Pakete|ubuntuusers.de Wine Fertige-Pakete]
in sub chapter "'''Methode 2 - Wine-Fremdquelle'''". Maybe you want to use this script:


[/CODE][/SPOILER]
<pre>
sudo dpkg --add-architecture i386    # Only necessary for 64bit systems.
sudo mkdir -pm755 /etc/apt/keyrings  # No longer necessary from version 24.04 onwards.
sudo wget -nc -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
sudo wget -NP /etc/apt/sources.list.d/ "https://dl.winehq.org/wine-builds/ubuntu/dists/$(lsb_release -c | grep -o '\w*$')/winehq-$(lsb_release -c | grep -o '\w*$').sources"
sudo apt update
sudo apt install --install-recommends winehq-stable
</pre>


The following chapter handles the installation of Trainz instances. The paths in the later following scripts are based on a collecting folder "Wine" in $USER.
The following chapter handles the installation of Trainz instances. The paths in the later following scripts are based on a collecting folder "Wine" in $USER.
 
=== Download and unpack the Trainz install files ===
Download and unpack the Trainz install files
After downloading the full installer zip files
After downloading the full installer zip files


TANE-SP4-Offline-Installer-105766.zip
* TANE-SP4-Offline-Installer-105766.zip
TRS19-SP4-Offline-Installer-114800.zip
* TRS19-SP4-Offline-Installer-114800.zip
TRS22-Offline-Installer-126273.zip
* TRS22-Offline-Installer-126273.zip
TrainzPlus-Offline-Installer-128486.zip
* TrainzPlus-Offline-Installer-128486.zip
and unpacking it into the sub folder looks like this:
 
[SPOILER=Folder structure][CODE]
 
$HOME/Wine/TRSDL/
 
+-- TANESP4_105766
 
|  +-- ...
 
|  +-- install.exe
 
|  +-- ...
 
+-- TRS19PE_114800
 
|  +-- ...
 
|  +-- install.exe
 
|  +-- ...
 
+-- TRS22PE_126273
 
|  +-- ...
 
|  +-- install.exe
 
|  +-- ...


+-- TRSPLUS_128486
and unpacking it into the sub folder looks like this
<div class="toccolours mw-collapsible mw-collapsed">
hidden collapsed folder file structure (please expand ->):
<div class="mw-collapsible-content">


    +-- ...
$HOME/Wine/TRSDL/
+-- TANESP4_105766
|  +-- ...
|  +-- install.exe
|  +-- ...
+-- TRS19PE_114800
|  +-- ...
|  +-- install.exe
|  +-- ...
+-- TRS22PE_126273
|  +-- ...
|  +-- install.exe
|  +-- ...
+-- TRSPLUS_128486
    +-- ...
    +-- install.exe
    +-- ...


    +-- install.exe
</div></div>


    +-- ...
=== Install the Trainz instances ===
 
[/CODE][/SPOILER]
 
Install the Trainz instances
We install every Trainz instance in its own wine prefix. The install statements of the following scripts create the wine prefixes ".TANESP4", ".TRS19PE", ".TRS22PE respective ".TRSPLUS" as hidden same named folders.
We install every Trainz instance in its own wine prefix. The install statements of the following scripts create the wine prefixes ".TANESP4", ".TRS19PE", ".TRS22PE respective ".TRSPLUS" as hidden same named folders.
Every installation process creates two links at the desktop. I don't currently know the purpose of the link with the purple circle and a white arrow. The launch link for the Trainz instance with a Trainz icon and a small red dot with a white cross is blocked. By right-clicking it and using the "Allow launching" entry, it will be possible to launch Trainz.
Every installation process creates two links at the desktop. I don't currently know the purpose of the link with the purple circle and a white arrow. The launch link for the Trainz instance with a Trainz icon and a small red dot with a white cross is blocked. By right-clicking it and using the "Allow launching" entry, it will be possible to launch Trainz.
Maybe you want to use one of this scripts to install a Trainz instance:
Maybe you want to use one of this scripts to install a Trainz instance:


[SPOILER=Installation of TANESP4][CODE]
#!/bin/bash
 
#===============================================================================
#!/bin/bash
# Installation of TANESP4 in Wine on Ubuntu
 
#-------------------------------------------------------------------------------
#===============================================================================
WINEPREFIX=$HOME/Wine/.TANESP4 wine $HOME/Wine/TRSDL/TANESP4_105766/install.exe
 
#===============================================================================
# Installation of TANESP4 in Wine on Ubuntu
 
#-------------------------------------------------------------------------------
 
WINEPREFIX=$HOME/Wine/.TANESP4 wine $HOME/Wine/TRSDL/TANESP4_105766/install.exe
 
#===============================================================================
 
[/CODE][/SPOILER]
 
[SPOILER=Installation of TRS19PE][CODE]
 
#!/bin/bash
 
#===============================================================================
 
# Installation TRS19PE in Wine on Ubuntu
 
#-------------------------------------------------------------------------------
 
WINEPREFIX=$HOME/Wine/.TRS19PE wine $HOME/Wine/TRSDL/TRS19PE_114800/install.exe
 
#===============================================================================
 
[/CODE][/SPOILER]
 
[SPOILER=Installation of TRS22PE][CODE]
 
#!/bin/bash
 
#===============================================================================
 
# Installation TRS22PE in Wine on Ubuntu
 
#-------------------------------------------------------------------------------
 
WINEPREFIX=$HOME/Wine/.TRS22PE wine $HOME/Wine/TRSDL/TRS22PE_126273/install.exe
 
#===============================================================================
 
[/CODE][/SPOILER]
 
[SPOILER=Installation of TRSPLUS][CODE]
 
#!/bin/bash
 
#===============================================================================
 
# Installation TRSPLUS in Wine on Ubuntu
 
#-------------------------------------------------------------------------------


WINEPREFIX=$HOME/Wine/.TRSPLUS wine $HOME/Wine/TRSDL/TRSPLUS_128486/install.exe
#!/bin/bash
#===============================================================================
# Installation TRS19PE in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRS19PE wine $HOME/Wine/TRSDL/TRS19PE_114800/install.exe
#===============================================================================


#===============================================================================
#!/bin/bash
#===============================================================================
# Installation TRS22PE in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRS22PE wine $HOME/Wine/TRSDL/TRS22PE_126273/install.exe
#===============================================================================


[/CODE][/SPOILER]
#!/bin/bash
#===============================================================================
# Installation TRSPLUS in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRSPLUS wine $HOME/Wine/TRSDL/TRSPLUS_128486/install.exe
#===============================================================================


Good luck and have fun!
Good luck and have fun!

Latest revision as of 10:20, 2 May 2025

See Trainz Forum Discussion Thread "Installing and running Trainz at Linux, here Ubuntu 24.04 LTS noble - post #1 and #3" too.

Ubuntu 24.4 LTS noble

The idea

This is a very old idea and often discussed. I searched for a systematic instruction, but I didn't find one. So I tried to test it and how it runs. Here's my personal systematic for Debian based Linux systems. For my knowledge such systems aren't able to execute windows programs (*.exe) out of the box. We need some helper apps. In my case I will use WineHQ from an external repository.

Install WineHQ

A useful instruction to do so is here (in German): Wine Fertige-Pakete in sub chapter "Methode 2 - Wine-Fremdquelle". Maybe you want to use this script:

 sudo dpkg --add-architecture i386     # Only necessary for 64bit systems.
 sudo mkdir -pm755 /etc/apt/keyrings   # No longer necessary from version 24.04 onwards.
 sudo wget -nc -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
 sudo wget -NP /etc/apt/sources.list.d/ "https://dl.winehq.org/wine-builds/ubuntu/dists/$(lsb_release -c | grep -o '\w*$')/winehq-$(lsb_release -c | grep -o '\w*$').sources"
 sudo apt update
 sudo apt install --install-recommends winehq-stable

The following chapter handles the installation of Trainz instances. The paths in the later following scripts are based on a collecting folder "Wine" in $USER.

Download and unpack the Trainz install files

After downloading the full installer zip files

* TANE-SP4-Offline-Installer-105766.zip
* TRS19-SP4-Offline-Installer-114800.zip
* TRS22-Offline-Installer-126273.zip
* TrainzPlus-Offline-Installer-128486.zip

and unpacking it into the sub folder looks like this

hidden collapsed folder file structure (please expand ->):

$HOME/Wine/TRSDL/
+-- TANESP4_105766
|   +-- ...
|   +-- install.exe
|   +-- ...
+-- TRS19PE_114800
|   +-- ...
|   +-- install.exe
|   +-- ...
+-- TRS22PE_126273
|   +-- ...
|   +-- install.exe
|   +-- ...
+-- TRSPLUS_128486
    +-- ...
    +-- install.exe
    +-- ...

Install the Trainz instances

We install every Trainz instance in its own wine prefix. The install statements of the following scripts create the wine prefixes ".TANESP4", ".TRS19PE", ".TRS22PE respective ".TRSPLUS" as hidden same named folders. Every installation process creates two links at the desktop. I don't currently know the purpose of the link with the purple circle and a white arrow. The launch link for the Trainz instance with a Trainz icon and a small red dot with a white cross is blocked. By right-clicking it and using the "Allow launching" entry, it will be possible to launch Trainz. Maybe you want to use one of this scripts to install a Trainz instance:

#!/bin/bash
#===============================================================================
# Installation of TANESP4 in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TANESP4 wine $HOME/Wine/TRSDL/TANESP4_105766/install.exe
#===============================================================================
#!/bin/bash
#===============================================================================
# Installation TRS19PE in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRS19PE wine $HOME/Wine/TRSDL/TRS19PE_114800/install.exe
#===============================================================================
#!/bin/bash
#===============================================================================
# Installation TRS22PE in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRS22PE wine $HOME/Wine/TRSDL/TRS22PE_126273/install.exe
#===============================================================================
#!/bin/bash
#===============================================================================
# Installation TRSPLUS in Wine on Ubuntu
#-------------------------------------------------------------------------------
WINEPREFIX=$HOME/Wine/.TRSPLUS wine $HOME/Wine/TRSDL/TRSPLUS_128486/install.exe
#=============================================================================== 

Good luck and have fun!