Facepunch / garrysmod-issues

Garry's Mod issue tracker
143 stars 56 forks source link

Problem with Linux legacy addons when their folder isn't lower-case #4527

Open thegrb93 opened 4 years ago

thegrb93 commented 4 years ago

People using Linux report Starfall not loading because the folder isn't lower-cased. When they change StarfallEx to starfallex, it works. I don't use Linux so can't test for myself, but seems like a gmod bug. https://github.com/thegrb93/StarfallEx/issues/911

Kefta commented 4 years ago

This has been a "bug" since GMod's inception on Linux/OSX, I assume it was intended by this point.

thegrb93 commented 4 years ago

It's also annoying we can't do upper case in file names with file lib anymore. People report that as bug to various addons too.

robotboy655 commented 4 years ago

This is the only solution for addons developed on Windows, which has case-insensitive file system to also work under Linux/OSX, both of which have case-sensitive file systems. This is very important for Steam Workshop, where all files in the .gma are forced lowercase.

There are no plans in changing this behavior.

thegrb93 commented 4 years ago

You could force the legacy addon's folder name lower-case. I don't think the user should have to do it manually. If there are two that conflict, then take the first one and ignore the others.

Kefta commented 4 years ago

"The first one" is not defined, and will just lead to more conflicts. I think GMod should instead spit out a console error when it ignores a file with uppercase, maybe in developer.

robotboy655 commented 4 years ago

Yeah I agree, it should tell the user that an added was refused to be mounted.

thegrb93 commented 4 years ago

It would be most convenient if it worked in the absence of a conflict though, and emitted an error otherwise.

DBotThePony commented 4 years ago

Gmod actually follow source engine's behavior on filenames case-sensivity (source engine lowercase all paths on both platforms when it tries to access assets). For dirty workaround you might want to create a JFS disk partition with -O flag.

This behavior was there for ages and i don't think it is something need to be changed (although it is indeed a major design flaw, but man, Valve were Windows-ifying Id Engine ever since Source Engine release)