tce-load -wi compiletc cmake git ninja pkg-config boost-1.78-dev openssl-1.1.1-dev zlib_base-dev libGL-dev qt-5.x-dev git clone --recurse-submodules https://github.com/arvidn/libtorrent.git cd libtorrent git checkout v2.0.8 cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_C_FLAGS='-flto -mtune=generic -Os' -DCMAKE_CXX_FLAGS='-flto -mtune=generic -Os' -DCMAKE_INSTALL_PREFIX=/usr/local cmake --build build mkdir /tmp/dest touch /tmp/mark find . | xargs touch [we are still in the libtorrent directory containing files that are about to be installed] sudo cmake --install build for file in $(find /usr/local -newer /tmp/mark -not -type d); do mkdir -p /tmp/dest/$(dirname $file); done for file in $(find /usr/local -newer /tmp/mark -not -type d); do cp -P $file /tmp/dest/$file; done