- Clone the following projects to the same directory.
git clone https://github.com/caoccao/BetterMediaInfo.git
git clone https://github.com/MediaArea/MediaInfoLib.git
git clone https://github.com/MediaArea/ZenLib.git- Upgrade Ubuntu 24.04.
sudo apt-get update
sudo apt-get install -y libsoup-3.0-dev libjavascriptcoregtk-4.1-dev libwebkit2gtk-4.1-dev- Download zlib.
curl -o zlib.tar.gz https://www.zlib.net/zlib-1.3.2.tar.gz
tar -xzvf zlib.tar.gz
mv zlib-1.3.2 zlib
rm zlib.tar.gz- Build zlib.
cd zlib
./configure --static
make -j `nproc`- Build ZenLib.
cd ZenLib/Project/GNU/Library
./autogen.sh
./configure --enable-static
make -j `nproc`- Build MediaInfoLib.
cd MediaInfoLib/Project/GNU/Library
./autogen.sh
./configure --enable-static
make -j `nproc`- Install XCode.
- Install autoconf automake libtool pkg-config zlib wxwidgets.
brew install autoconf automake libtool pkg-config zlib wxwidgets- Download zlib.
curl -o zlib.tar.gz https://www.zlib.net/zlib-1.3.2.tar.gz
tar -xzvf zlib.tar.gz
mv zlib-1.3.2 zlib
rm zlib.tar.gz- Build zlib.
cd zlib
./configure --static
make -j `nproc`- Build ZenLib.
cd ZenLib/Project/GNU/Library
./autogen.sh
./configure --enable-static
make -j `nproc`- Build MediaInfoLib.
cd MediaInfoLib/Project/GNU/Library
./autogen.sh
./configure --enable-static
make -j `nproc`- Download zlib.
curl -o zlib.zip https://zlib.net/zlib132.zip
7z x zlib.zip
move zlib-1.3.2 zlib
del zlib.zip- Build zlib.
cd zlib
cmake -G "Visual Studio 18 2026" -A x64 -S . -B contrib/vstudio/vc18
cmake --build contrib/vstudio/vc18 --config Release- Patch MediaInfoLib to work with cmake-built zlib.
cd scripts/ts
deno task patch- Build MediaInfoLib in Visual Studio 2026.
cd MediaInfoLib\Project\MSVC2026
msbuild MediaInfoLib.slnx -t:rebuild -verbosity:diag -property:Configuration=Release -property:Platform=x64This step is optional because the generated bindings.rs is broken. bindings.rs is for reference only.
- Install
bindgen-cli.
cargo install bindgen-cli- Generate
bindings.rs.
cd BetterMediaInfo
set LIBCLANG_PATH=C:\Program Files\Microsoft Visual Studio\18\Enterprise\VC\Tools\Llvm\x64\bin\libclang.dll
bindgen ^
--allowlist-item "MediaInfo\w+" ^
-o src-tauri\src\bindings.rs ^
..\MediaInfoLib\Source\MediaInfoDLL\MediaInfoDLL.h- Add the following code to the top of
bindings.rsto mute the warnings.
#![allow(non_camel_case_types, non_upper_case_globals, nonstandard_style, dead_code, unused_imports)]set RUST_LOG=debugpnpm install
pnpm tauri dev
pnpm tauri build- Run the commands as follows.
node BetterMediaInfo\src-tauri\scripts\copy_dlls.cjs
node BetterMediaInfo\src-tauri\scripts\patch_tauri_conf.cjsThe config file BetterMediaInfo.json is resolved at runtime based on the platform and how the app is launched:
- Linux:
$XDG_CONFIG_HOME/BetterMediaInfo/BetterMediaInfo.jsonifXDG_CONFIG_HOMEis set; otherwise$HOME/.config/BetterMediaInfo/BetterMediaInfo.json. - macOS:
$HOME/Library/Application Support/BetterMediaInfo/BetterMediaInfo.json. - Windows:
- If the executable lives under
%LOCALAPPDATA%,%ProgramFiles%, or%ProgramFiles(x86)%(i.e. the app is installed), the config is stored in%APPDATA%\BetterMediaInfo\BetterMediaInfo.json. - Otherwise (development mode), the config is stored next to the executable (current behavior).
- If the executable lives under
The config directory is created automatically on first launch if it doesn't exist.