[klee-dev] Error when compile coreutils

Loi Luu loi.luuthe at gmail.com
Mon Apr 22 12:26:19 BST 2013


Hi Urmas,

It works. Thank you so much :)


On Mon, Apr 22, 2013 at 3:31 PM, Urmas Repinski <urrimus at hotmail.com> wrote:

> Hi Tomasz
>
> Just googled a little and found some solution -
> http://comments.gmane.org/gmane.comp.compilers.llvm.klee/925
>
>
> LLVM-LD can't find the libraries it needs to link with. In the is case
> librt (the realtime library).
>
> Find the location of librt.a on your system and set the
> LLVM_LIB_SEARCH_PATH variable before you run make.
>
> For example on my system librt is in /usr/lib/ so I would run in my shell
>
> $ export LLVM_LIB_SEARCH_PATH=/usr/lib
>
> Read the manpage of llvm-ld for more information.
>
> That should fix your problem.
>
> Regards,
> Dan Liew.
>
>
> So try to set not export LIBRARY_PATH=/usr/lib/x86_64-linux-gnu, but
> export LLVM_LIB_SEARCH_PATH=/usr/lib/x86_64-linux-gnu.
>
> Hope this helps,
> Urmas Repinski
>
> ------------------------------
> From: loi.luuthe at gmail.com
> Date: Mon, 22 Apr 2013 01:18:37 -0700
> To: t.kuchta12 at imperial.ac.uk
> CC: klee-dev at imperial.ac.uk
>
> Subject: Re: [klee-dev] Error when compile coreutils
>
> Hi,
>
> I did try it before but it didnt work.
>
> Thanks,
>
> Sent from my Windows Phone
> ------------------------------
> From: Kuchta, Tomasz
> Sent: 22/04/2013 14:46
> To: Loi Luu
> Cc: klee-dev
> Subject: Re: [klee-dev] Error when compile coreutils
>
> Hello,
>
>  Please also try setting
>
>  export LIBRARY_PATH=/usr/lib/x86_64-linux-gnu
>
>  Best Regards,
>
>  Tomek
>
>  On 22 Apr 2013, at 04:32, Loi Luu <loi.luuthe at gmail.com> wrote:
>
>  Dear all,
>
>  I got the same error in this thread
> http://keeda.stanford.edu/pipermail/klee-dev/2012-September/000925.html,
> and I follow the solution that Dan Liew suggested but it still gave me the
> same error.
>
>  For more specific, firstly I located the librt.a
>  *locate librt.a *
> /home/turtle/klee-uclibc/lib/librt.a
> /usr/lib/x86_64-linux-gnu/librt.a
>
>  So I add the latter address to path:
>
>  *export LLVM_LIB_SEARCH=/usr/lib/x86_64-linux-gnu*
>
>  *After running make, I still got the error*
>  /home/turtle/klee/scripts/klee-gcc  -g  -Wl,--as-needed -o chown chown.o
> chown-core.o ../lib/libcoreutils.a  ../lib/libcoreutils.a
> /home/turtle/klee/scripts/klee-gcc  -I. -I../../src -I../lib  -I../../lib
>   -g -MT chmod.o -MD -MP -MF .deps/chmod.Tpo -c -o chmod.o ../../src/chmod.c
> mv -f .deps/chmod.Tpo .deps/chmod.Po
> /home/turtle/klee/scripts/klee-gcc  -g  -Wl,--as-needed -o chmod chmod.o
> ../lib/libcoreutils.a  ../lib/libcoreutils.a
> /home/turtle/klee/scripts/klee-gcc  -I. -I../../src -I../lib  -I../../lib
>   -g -MT cp.o -MD -MP -MF .deps/cp.Tpo -c -o cp.o ../../src/cp.c
> mv -f .deps/cp.Tpo .deps/cp.Po
> /home/turtle/klee/scripts/klee-gcc  -I. -I../../src -I../lib  -I../../lib
>   -g -MT copy.o -MD -MP -MF .deps/copy.Tpo -c -o copy.o ../../src/copy.c
> mv -f .deps/copy.Tpo .deps/copy.Po
> /home/turtle/klee/scripts/klee-gcc  -I. -I../../src -I../lib  -I../../lib
>   -g -MT cp-hash.o -MD -MP -MF .deps/cp-hash.Tpo -c -o cp-hash.o
> ../../src/cp-hash.c
> mv -f .deps/cp-hash.Tpo .deps/cp-hash.Po
> /home/turtle/klee/scripts/klee-gcc  -g  -Wl,--as-needed -o cp cp.o copy.o
> cp-hash.o ../lib/libcoreutils.a  ../lib/libcoreutils.a
> /home/turtle/klee/scripts/klee-gcc  -I. -I../../src -I../lib  -I../../lib
>   -g -MT dd.o -MD -MP -MF .deps/dd.Tpo -c -o dd.o ../../src/dd.c
> mv -f .deps/dd.Tpo .deps/dd.Po
> /home/turtle/klee/scripts/klee-gcc  -g  -Wl,--as-needed -o dd dd.o
> ../lib/libcoreutils.a  ../lib/libcoreutils.a -lrt
> llvm-ld: error: Cannot find library 'rt'
> make[3]: *** [dd] Error 1
> make[3]: Leaving directory `/home/turtle/coreutils-6.11/obj-llvm/src'
> make[2]: *** [all] Error 2
> make[2]: Leaving directory `/home/turtle/coreutils-6.11/obj-llvm/src'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory `/home/turtle/coreutils-6.11/obj-llvm'
> make: *** [all] Error 2
>
>   Does anyone know what caused this error?
>
>  Thank you,
> --
>  Loi, Luu The (Mr.)
> University of  Engineering and Technology, Vietnam National University,
> Hanoi.
>  _______________________________________________
> klee-dev mailing list
> klee-dev at imperial.ac.uk
> https://mailman.ic.ac.uk/mailman/listinfo/klee-dev
>
>
>
> _______________________________________________ klee-dev mailing list
> klee-dev at imperial.ac.uk https://mailman.ic.ac.uk/mailman/listinfo/klee-dev
>
> _______________________________________________
> klee-dev mailing list
> klee-dev at imperial.ac.uk
> https://mailman.ic.ac.uk/mailman/listinfo/klee-dev
>
>


-- 
Loi, Luu The (Mr.)
University of  Engineering and Technology, Vietnam National University,
Hanoi.
-------------- next part --------------
HTML attachment scrubbed and removed


More information about the klee-dev mailing list