A Tutorial for Installing Linux Dosbox on a 32-bit computer
All rights reserved
1. Downloading and preparing media
This tutorial is made with Windows 10, because most of the people uses it. If you use Ubuntu or Debian Linux, it would work best. I do not take responsibility from anything that might happen if you follow this tutorial. I would recommend to use a less important computer with this kind of projects, so that it does not matter if they break or something else happens.
First download a 32-bit Debian i386 netinst CD distro, that has no graphical user interface if not specially installed. Bullseye(11) is the latest distribution, but Buster(10) is the stable version. That is why I use Buster.
2. Installing Debian OS
3. Start using Debian
After installation what you will see is:
Debian GNU/Linux 10 “computername” tty1
Here you must enter your username, that you made at “Set up users and passwords” section.
After that you will be asked your password.
You are at prompt:
Disable “deb cdrom” as a repository:
Enter: sudo nano /etc/apt/sources.list
Put a hashtag(#) in front of line “deb cdrom:”
Ctrl-X to exit. Save modified buffer? Press Y.
If you get a (Y/N) question during the installation, press Y and enter.
Type: sudo apt update. > [sudo] password for “username”:(enter password)
You should get all your packages updated. Might be, that the installation has the latest packages.
Type: sudo apt upgrade. > [sudo] password for “username”:(enter password)
Type: sudo apt install dosbox
This installation asks confirmation to install all the packages. Y and enter.
Enter: sudo dosbox
If you do not enter as sudo, you get following: Exit to error: Can’t init SDL Unable to open mouse.
If Dosbox does not work at all, you should try: sudo apt install dosbox --fix-missing
The problem is, that keyboard inputs does not work. When Dosbox starts first time, it makes a config file "dosbox-0.74-2.conf", which is in "/root/.dosbox/" folder. It used to be, that dosbox started without “sudo”. It meant that folder “.dosbox” was under “user” folder.
Dosbox does not operate, so reboot is needed.
After restart, type “sudo nano /root/.dosbox/dosbox-0.74-2.conf”. If it does not work, view the folder contents with “ls” command: "sudo ls /root/.dosbox". This shows the name of .conf file.
Let’s modify dosbox conf file:
First: In the first group (sdl) make usescancodes=false. This fixes the text input problem.
Next: under (dosbox), memsize=64. I have read that it is maximum the system uses.
Last: under (autoexec) "mount c /home/”username”/dosgames" (and the last row) "c:"
4. Installing games
Now, we need some games!
Remember, Linux understands Windows type hard disk formats, but Windows doesn't understand ext-type of formats.
Let us make now a games directory in your user folder. Go to (/home/”username”/). Then make the folder > sudo mkdir dosgames
Save some games to a USB-stick and enter it to a free usb slot on your project PC.
It says something following: [sdb] Assuming drive cache: write through...
Next phase is to mount the USB-stick to the system.
I made a “dosgames” folder under “media” folder: sudo mkdir “foldername”
If the system does not tell what is the name of the installation media, you should type: sudo lsblk
This should tell all of the medias that are attached to the system. If you are not sure which one is the media you need, detach the it, use again lsblk and that which one is gone is the one.
Sudo mount /dev/sdb/ /media/dosgames/
Go to the /media/dosgames/
Copy games to your folder (/home/”username”/dosgames).
Copy with following command: sudo cp -R (source_folder) (destination_folder): sudo cp -R /media/dosgames/"game"/ /home/"username"/dosgames/
Now you can start a game by starting dosbox first. Type “sudo dosbox”.
4. Setting Audio
Now that we have games, we need to test them. Very soon you notice, that game runs well, but there is no audio. We want to fix that one, because sounds are very important for perfect gaming experience.
What we need, can be found from the following page: https://wiki.debian.org/ALSA
The dependencies that have been mentioned there, should fix the missing sound.
To get these dependencies installed, you need to type: sudo apt install “package name”
To initialize ALSA, you need to type: sudo alsactl init
My computer says in this phase:
Found hardware: “HDA-Intel” “Realtek ALC361” and so on…
Hardware is initialized using a generic method.
Run: pulseaudio --start
5. Random ThingsI leave graphics settings for you to try. Graphics works for me, but games use only a small part of the screen.
Joysticks should work without much problems. I Inserted a USB WingMan Precision gamepad and it worked well without any settings.
I enter a link of this page to my post at Vogons.org. You can enter your responses there.