On a Raspberry Pi with Raspbian system, first cleanup apt cache with :
sudo aptitude clean
Then download package without installing them :
sudo aptitude --download-only reinstall \
xorg-dev \
libgtk-3-dev \
libboost-filesystem-dev \
libboost-system-dev \
libudev-dev \
libcairo2-dev \
libusb-1.0-0-dev \
libssl-dev \
libfreetype6-dev \
libfontconfig1-dev \
libglu1-mesa-dev \
libmpg123-dev \
libopenal-dev \
libassimp-dev \
libopencv-dev \
libasound2-dev \
libsndfile1-dev \
gstreamer1.0-x \
gstreamer1.0-alsa \
gstreamer1.0-libav \
gstreamer1.0-pulseaudio \
gstreamer1.0-plugins-base \
gstreamer1.0-plugins-good \
gstreamer1.0-plugins-bad \
gstreamer1.0-plugins-ugly \
libgstreamer1.0-dev \
libgstreamer-plugins-base1.0-dev \
libcurl4-openssl-dev \
liburiparser-dev \
libpugixml-dev \
zlibg1-dev \
libpng16-16
extract all deb into a sysroot folder and compress the folder
mkdir ~/sysroot
cd ~/sysroot
for deb in /var/cache/apt/archives/*.deb; do dpkg-deb -xv $deb .; done
cd ..
tar -cazf sysroot.tar.gz sysroot
then transfert the tar to your dev machine running linux and unpack it :
mkdir ~/ofnode
scp pi@raspberrypi.local:~/sysroot.tar.gz .
tar -xf sysroot.tar.gz