For the base content generation, we zurrently use pkzip on windows, and zip on the other platforms, which is usually installed by default on linux.
The base files are not compatible, as in, you do not sync if some players use the windows genreated ones, and others those made on linux. This can be cause of platform dependent thing, like line endings or case diferences in file names, or possibly the different file archiving tools (less likely).
I had a look at this list:
http://en.wikipedia.org/wiki/Comparison ... _archivers
And the only two free tools, which run on all out platforms and feature command line interfaces, are DAR and Info-Zip:
http://en.wikipedia.org/wiki/DAR_(Disk_Archiver)
http://en.wikipedia.org/wiki/Info-ZIP
maybe using other tools does not help at all, but i though i'd list them here for reference anyway.
i can't think of this as beeing an unsolvable problem, and it coudl save us from some ever returning problems, so it seems worth trying to fix this.
As i have no idea how these files are used, two questions:
wold it be an option to convert all files (and dirs) in these 4 archives to lowercase only? Would it break anything/would a lot have to be adjusted?
If it really is the case sensitivity, could the checksum algorithm maybe force file names that are all on one case to lowercase on windows?
Replacing pkzip
Moderator: Moderators
- thesleepless
- Posts: 417
- Joined: 24 Oct 2007, 04:49
Re: Replacing pkzip
7zip/p7zip is available on all platforms for cli
-
- Spring Developer
- Posts: 1254
- Joined: 24 Jun 2007, 08:34
Re: Replacing pkzip
Remove pkzip and include wget for autodownload?
Re: Replacing pkzip
Filenames are already checksummed in lowercase, see ArchiveScanner.cpp:529-545.hoijui wrote:case diferences in file names
[...]
wold it be an option to convert all files (and dirs) in these 4 archives to lowercase only? Would it break anything/would a lot have to be adjusted?
If it really is the case sensitivity, could the checksum algorithm maybe force file names that are all on one case to lowercase on windows?
EDIT: Also have you already checked the archives have the same contents? It wouldn't suprise me if the .bat is just outdated a bit and forgets to include a directory or two.
Re: Replacing pkzip
better use 7z both on windows and other platforms. also, figure out if/how ctime/mtime/atime affect crc (if it is used at all) and molest with touch if needed.
Re: Replacing pkzip
Times do not affect CRC.
Only lowercased filename and file's CRC (of the files inside the archive) affect CRC.
So the only thing that can be an issue is: the set of files that is put in the archives isn't same on windows and linux, or the contents of the files isn't the same on windows and linux (may be line endings.)
Again, see ArchiveScanner.cpp:529-545.
Only lowercased filename and file's CRC (of the files inside the archive) affect CRC.
So the only thing that can be an issue is: the set of files that is put in the archives isn't same on windows and linux, or the contents of the files isn't the same on windows and linux (may be line endings.)
Again, see ArchiveScanner.cpp:529-545.
Re: Replacing pkzip
I used to play fine, without desync, against people using Linux. What changed? Does the problem exist in the first place?hoijui wrote:The base files are not compatible, as in, you do not sync if some players use the windows genreated ones, and others those made on linux.
Re: Replacing pkzip
Only for people building their own Spring on Windows, which they want to use in multi player, it may be a problem.
(And even then it is a minor one as they can just get the release base files, or, in case of a development version, the base files from BuildServ.)
(And even then it is a minor one as they can just get the release base files, or, in case of a development version, the base files from BuildServ.)
Re: Replacing pkzip
thanks tobi!
ther is indeed one file that is missing on windows (EngineOptions.lua).
i already fixed that locally, but did nto commit it yet (since 2 weeks or so :/ ). but even with that, it did not sync. though .. i dont trust my ols ego (as of 2 weeks ago.. actually not even the one from an hour ago mostly, but that is not importat here..). so ill commit and test again, and then will try with 7zip instead of zip/pkzip.
ther is indeed one file that is missing on windows (EngineOptions.lua).
i already fixed that locally, but did nto commit it yet (since 2 weeks or so :/ ). but even with that, it did not sync. though .. i dont trust my ols ego (as of 2 weeks ago.. actually not even the one from an hour ago mostly, but that is not importat here..). so ill commit and test again, and then will try with 7zip instead of zip/pkzip.