[klee-dev] error : klee + coreutils + experimental [+docker]
Dan Liew
dan at su-root.co.uk
Tue Apr 14 19:22:26 BST 2015
Hi,
> Clearly i have not llvm-ld because it was removed.
> So, what shuold I change in klee-gcc to make it work with the new
> settings/version of things
klee-gcc is only meant to be used with llvm-gcc. I would use
whole-program-llvm [1] to build core utils if you are using clang.
$ export LLVM_COMPILER=clang
$ mkdir obj-llvm
$ CC=/path/to/whole-program-llvm/wllvm ../configure --disable-nls CFLAGS="-g"
$ make
Now extract the bit code for the application you want to run
$ /path/to/whole-program-llvm/extract-bc src/du
# Now you will have a src/du.bc file which is a LLVM module
$ klee --posix-runtime --libc=uclibc src/du.bc --version
> 2) WITH DOCKER klee/klee case:
> It fails in step 1 (2 too)
> I run:
> sudo docker run -ti klee/klee
> klee at 2f1c0eaa949c:~$ wget
> http://ftp.gnu.org/gnu/coreutils/coreutils-6.11.tar.gz
> klee at 2f1c0eaa949c:~$ tar xf coreutils-6.11.tar.gz
> klee at 2f1c0eaa949c:~$ cd coreutils-6.11
> klee at 2f1c0eaa949c:~/coreutils-6.11$ mkdir obj-gcov && cd obj-gcov
> klee at 2f1c0eaa949c:~/coreutils-6.11/obj-gcov$ ../configure --disable-nls
> CFLAGS="-g -fprofile-arcs -ftest-coverage"
>
> config.status: executing po-directories commands
> config.status: creating po/POTFILES
> config.status: creating po/Makefile
> rm: cannot remove 'confdir3/confdir3/confdir3/..
> .(many many repetitions ).../confdir3/confdir3': File name too long
Perhaps you're running an old buggy version of docker? I'm using Docker 1.5.0
Or perhaps there's something wrong with the underlying storage driver
being used by your version of Docker.
You could try doing the build of coretuils in a Docker volume to
bypass the storage driver to see if that fixes your issue:
$ docker run -ti -v /path/on/host/system:/mnt klee/klee
the above will make the /path/on/host/system available in the /mnt
inside the container.
Then you could try extracting the coreutils files into /mnt and trying
the build there.
Thanks,
Dan.
More information about the klee-dev
mailing list