-
Notifications
You must be signed in to change notification settings - Fork 368
Filesystem case sensitivity and Linux
Note: this document applies only to versions up to 3.1. Newer versions can work on case-sensitive filesystems.
The game is tested on Ubuntu 16.04 and 18.04.
As on any other platform, the Windows version of GTA is used. This creates some problems, because filesystems on Windows are case-insensitive, and GTA data files reference each other with incorrect names (case does not match). To overcome this, you can place GTA installation in FAT filesystem, which is also case-insensitive.
The easiest thing to do would be to copy GTA to FAT partition, if you have any. In case you don't have, or you want to use ramdisk, then you can create FAT filesystem in an image file, as described below.
Copy GTA installation to FAT partition.
Decide how much space you need for image. If you are not using audio, then the game size will be around 1.6 GB. But, make sure that you have a little more than that, so that filesystem can be placed inside. If you are using audio, then size will be around 5 GB.
I won't use audio, so the image size will be 1.7 GB.
- Create image file:
fallocate -l 1.7G gtasafat.img
- Format image file as FAT:
mkfs.vfat -F 32 gtasafat.img
- Create mount point:
mkdir gtasafat
- Mount image file (root privileges required):
sudo mount -o loop,gid=$(id -g),uid=$(id -u) gtasafat.img gtasafat/
- Copy GTA installation to mount point.
Image file is now ready.
You would probably want to add new entry to /etc/fstab
so that image is mounted on system boot.
If you skipped copying audio in order to reduce image size, now you can bind original audio folder to audio folder in mounted image. This is possible because audio files are not referenced from other GTA files, and therefore, there is no mismatched case.
mkdir gtasafat/audio
sudo mount -o bind "/path_to_original_gta/audio" gtasafat/audio
If you have enough RAM, you can copy image file to /dev/shm
folder, which functions as a ramdisk. This way the game will load assets faster.