[master] Route66 addon detection is case-sensitive

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.

Post a reply

Smilies
:D :) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :geek: :ugeek: :!: :?: :idea: :arrow: :| :mrgreen: :3: :wub: >:( :blergh:
View more smilies

BBCode is OFF
Smilies are ON

Topic review
   

Expand view Topic review: [master] Route66 addon detection is case-sensitive

Re: [master] Route66 addon detection is case-sensitive

by Manuel-K » Sun Mar 01, 2020 10:42 am

Rachael wrote:
Manuel-K wrote:That is random and up to the user's choice.
In the case of distributed material, it is *not* random and up to the user's choice. This needs to be clearly addressed in a sane way.
I was talking about the first part of the path, if that wasn't obvious. You can't just arbitrarily switch case on that and expect it to work.

The previous code even broke GOG's installation folder because that is mixed-case.

––

I'll re-check GOG's installers later, but I think it should work with what we have now.

––

Edit: I've looked through the GOG installer's install_script (from innounp) and the current version (for Windows) has everything relevant in upper case. There is no official installer for Linux, but there are unofficial scripts that use the Windows-version with innoextract.

Re: [master] Route66 addon detection is case-sensitive

by Graf Zahl » Sun Mar 01, 2020 7:37 am

You can blame its Unix roots for that. Apparently too much old software would have broken if it had been changed. What gets even more annoying is when certain languages have different casing rules, like the Turkish 'i' - or letters that have no uppercase variant - or worst - Greek's small skgma that exists in two different forms that both map to the same uppercase variant. A case sensitive file system will never run into problems with these but a case insensitive system definitely will if it doesn't define character equalities.

Re: [master] Route66 addon detection is case-sensitive

by Rachael » Sun Mar 01, 2020 7:04 am

Manuel-K wrote:That is random and up to the user's choice.
In the case of distributed material, it is *not* random and up to the user's choice. This needs to be clearly addressed in a sane way.

When dealing with Linux and FreeBSD, you unfortunately just have to get it out of your head that "h" means the same as "H". It simply does not, and you can never assume that it does. There are Linux applications where this does need manual maintenance and fixing, regular applications can only do so much. Even server applications such as Apache expect you to fix this yourself. "bob" and "Bob" are completely different filenames, and even completely different usernames. So - what Graf is asking here is what casing the installer actually uses.

I will say one thing though: I find the whole idea of a case-sensitive file system annoying and stupid. That's one thing Linux could have done without.

Re: [master] Route66 addon detection is case-sensitive

by Graf Zahl » Sun Mar 01, 2020 3:52 am

That wasn't what I was asking. I was asking for the proper cases of the files and internal directories I need to test for.

Re: [master] Route66 addon detection is case-sensitive

by Manuel-K » Sun Mar 01, 2020 3:33 am

Graf Zahl wrote:That's just stupid.
There has to be a misunderstanding somewhere!? How could it be stupid to allow the user to choose his/her name?

Re: [master] Route66 addon detection is case-sensitive

by Graf Zahl » Sun Mar 01, 2020 3:16 am

I fixed the path composition.
Manuel-K wrote:
Graf Zahl wrote:What is the proper case here for Linux? Remember, I cannot test this on a case insensitive file system and if lower/uppercasing the path does not work it needs to be specified in the proper case.
That is random and up to the user's choice.
That's just stupid. If I cannot specify the proper names because they are random, and the last fix still doesn't work, zip all files belonging to the mod and use that. I won't fix "broken by design."

Re: [master] Route66 addon detection is case-sensitive

by Manuel-K » Sun Mar 01, 2020 2:58 am

Graf Zahl wrote:What is the proper case here for Linux? Remember, I cannot test this on a case insensitive file system and if lower/uppercasing the path does not work it needs to be specified in the proper case.
That is random and up to the user's choice.

The only sure way to make it work is to split the string and only manipulate the second part keeping the case of first part that's taken from Path definitions in the ini.

Edit: E.g. check = path + fn.MakeLower()
Edit2: Tested that and it works.

Re: [master] Route66 addon detection is case-sensitive

by Graf Zahl » Sun Mar 01, 2020 2:54 am

What is the proper case here for Linux? Remember, I cannot test this on a case insensitive file system and if lower/uppercasing the path does not work it needs to be specified in the proper case.

Re: [master] Route66 addon detection is case-sensitive

by Manuel-K » Sun Mar 01, 2020 2:51 am

That doesn't work as intended, unless you really wanted to change the case of the full path which includes the path of the containing directory and therefore the home directory.

Re: [master] Route66 addon detection is case-sensitive

by Graf Zahl » Sun Mar 01, 2020 12:42 am

Fixed. It will now look for both lowercase and uppercase names, but if you got mixed case paths you'll be out of luck. If that's how things are distributed I need the proper paths added to the config.

[master] Route66 addon detection is case-sensitive

by Manuel-K » Sat Feb 29, 2020 1:28 pm

When one of the files listed in the mustcontain definition doesn't match the case, it doesn't work.

Commit 64a34f8af78ee5b627e11a39a291ca5fab57472a

Top