Re: [sleuthkit-users] statically compiling sleuthkit
Brought to you by:
carrier
From: Raphaël R. <ml-...@sy...> - 2013-12-23 10:29:01
|
On 20/12/2013 07:56, Kalin KOZHUHAROV wrote: > Hello, > > I remember being able to do this a long time ago, but apparently not any more... > > Any hints on how to compile it statically, so that I can just send fls > or some other binary to a remote machine? > > # git clone https://github.com/sleuthkit/sleuthkit > # ./bootstrap > # ./configure --prefix=/tmp/test --enable-static --disable-shared > --disable-java --without-afflib --without-libewf > # make -j4 > # make install Hello, I managed to do it in an ugly way after trying the "correct" way, but the build system is very rigid and complex. So (works on a 64bit debian Sid, you will need to adjust paths): 1) Compile normally 2) cd tools/fstools/ 3) make clean 4) make 2>&1 > log 5) egrep '^g++' log | sed -r -e 's/-o ([a-z]+).o/-o \1/' -e 's/++ /++ -static /' -e 's/-c //' -e 's;$; ../../tsk/.libs/libtsk.a /usr/lib/x86_64-linux-gnu/libz.a /usr/lib/x86_64-linux-gnu/libpthread.a;' | tee static.sh 6) bash static.sh Yes, this is ugly but it works :) Regards, Raphaël Rigo |