Last active
November 6, 2025 19:11
-
-
Save timsneath/2b21878016f03e57d0099653feadec7a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # 1) Prereqs | |
| sudo apt update | |
| sudo apt install -y cmake pkg-config build-essential zlib1g-dev liblzma-dev git | |
| # 2) Fetch the last series that still provides SONAME .2 | |
| mkdir -p ~/opt/src && cd ~/opt/src | |
| git clone https://gitlab.gnome.org/GNOME/libxml2.git | |
| cd libxml2 | |
| git checkout v2.12.7 | |
| # 3) Build and install a private, shared libxml2 | |
| cmake -S . -B build -DCMAKE_BUILD_TYPE=Release \ | |
| -DCMAKE_INSTALL_PREFIX=$HOME/opt/libxml2-legacy \ | |
| -DBUILD_SHARED_LIBS=ON \ | |
| -DLIBXML2_WITH_PYTHON=OFF \ | |
| -DLIBXML2_WITH_LZMA=OFF | |
| cmake --build build -j | |
| cmake --install build | |
| export LD_LIBRARY_PATH=$HOME/opt/libxml2-legacy/lib:$LD_LIBRARY_PATH |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment