View Single Post
  #161  
Old 20-04-2026, 15:42
kj911 kj911 is offline
Registered User
 
Join Date: Apr 2010
Location: world
Posts: 231
Thanks: 158
Thanked 88 Times in 62 Posts
kj911 is on a distinguished road
wrathma: Thanks for the detailed description!

Speaking of switches:

wem-packer: Here, using "-s" or "-s -b" does not cause any particular confusion, during compress, unlike the unpacker.

wem-unpacker: Do not use the "-b" switch here, otherwise it may happen that the first time it is run it will fail (referring to "hdiff/xdelta"), while the second time it will run without errors. It is better to use it without switches, except for the "-tN" switch.

This is related to the fact that the "original" *.wem file is also in the folder, which conflicts with one of the members of the hdiffz+oggre chain and should appear at the end of the process, as the new *.wem file. That is, wem-unpacker deletes the original *.wem file and exits here, without continuing to run the hdiffz+oggre chain to then finish the unpacking properly, as it should.

Code:
C:\>wem-packer.exe -s -b music_frontend
Found 4 .wem files to pack (recursive)
Using 2 threads with size check (keeping backups)


268707965.wem: output is bigger than input, skipped

681733649.wem: output is bigger than input, skipped

775589494.wem: output is bigger than input, skipped

All files packed successfully in 7s!
C:\>wem-unpacker.exe music_frontend
Found 1 .ww files to unpack (recursive)
Using 2 threads

[0%] 0/1 Files processed, ETA: 0s
Errors encountered:
  108187332.ww: xdelta failed
Completed with errors in %s
0s
C:\>wem-unpacker.exe music_frontend
Found 1 .ww files to unpack (recursive)
Using 2 threads

[0%] 0/1 Files processed, ETA: 0s
All files unpacked successfully 4s!
wempack-xdelta package: This doesn't run under Win7 x64 either. (Has anyone tested it under Win7, are you using the uploaded files or only Win10/11?)

Running the GO compiler with these switches, I managed to produce somewhat smaller EXEs. It should be 100% compatible with Win7 (also with 32-bit editions, theoretically going back to Vista, up to the early 32-bit version of Win10.) although, all "embedded binaries" are XP-compatible.
Code:
go build -a -gcflags=all="-l -B" -ldflags="-w -s" -o myapp main.go
The uploaded CPP file would require a more experienced programmer than me, this was also transpiled with AI, from GO to C++.

UPD: Embedding binary files via alternative methods: https://github.com/samuelngs/binary-go workable from these "wem-(un)packer's" project?
Attached Files
File Type: 7z wempack_x86_hdiff.7z (1.58 MB, 6 views)
File Type: 7z wempack_x86_xdelta.7z (1.08 MB, 5 views)

Last edited by kj911; 21-04-2026 at 15:23.
Reply With Quote
The Following User Says Thank You to kj911 For This Useful Post:
wrathma (22-04-2026)