A Linux wrapper for the Oodle Data Compression library.
It essentially works like this:
- Parse the Windows Oodle DLL in the current directory (
oo2core_8_win64.dll
) using thepe-parse
library - Map the PE into memory
- Perform relocations
- Resolve imports to point to our own implementation of the minimum set of required Windows API functions
- Setup the
gs
register to point to a fakeTIB
structure - Execute the DLL's entry point
- Execute whatever Oodle exports you want (currently only
OodleLZ_Decompress
)
When you clone this repository, make sure you use --recurse-submodules
to get the pe-parse
submodule.
Otherwise you can run git submodule update --init
after you've cloned it.
After that, just use cmake to build the project and you'll get a liblinoodle.so
file created in the build
directory. You can link to this or use dlopen
, then call the OodleLZ_Decompress
export.
mkdir build
cd build
cmake ..
cd ..
cmake --build build/
This will also build an executable which tests that the library works. Run it with ./build/testlinoodle
.