about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
authorGerben Oolbekkink <g.j.w.oolbekkink@gmail.com>2019-04-05 10:03:32 +0200
committerMartin Nowack <m.nowack@imperial.ac.uk>2019-04-08 12:02:51 +0200
commit2a5944f8dcaab5df4528c3f01dc74a8f5f7f5bba (patch)
tree4a9f00304b2e6a7ac53fe355ab1d38064cf9557e
parent8fe6c47b1755f463594f7bc0b4e35e1145fa6e52 (diff)
downloadklee-2.0.x.tar.gz
Add LD_LIBRARY_PATH to docker image 2.0.x
Fixes #1080. The proper LD_LIBRARY_PATH is required when binaries linked
with kleeRuntest are run.

The STP line is changed to extend the library path instead of replace
it, I am not sure if it can be removed at this moment.
-rw-r--r--Dockerfile3
-rw-r--r--scripts/build/d-klee-linux-ubuntu.inc3
2 files changed, 4 insertions, 2 deletions
diff --git a/Dockerfile b/Dockerfile
index 16b25b52..97708b53 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -51,9 +51,10 @@ ADD --chown=klee:klee / ${BASE}/klee_src
 
 USER klee
 WORKDIR /home/klee
+ENV LD_LIBRARY_PATH /home/klee/klee_build/lib/
 
 # Add KLEE binary directory to PATH
 RUN /bin/bash -c 'ln -s ${BASE}/klee_src /home/klee/ && ln -s ${BASE}/klee_build* /home/klee/klee_build && echo "export PATH=\"$PATH:$(cd /tmp/llvm-*install*/bin && pwd):/home/klee/klee_build/bin\"" >> /home/klee/.bashrc'
 
 # TODO Remove when STP is fixed
-RUN /bin/bash -c 'echo "export LD_LIBRARY_PATH=$(cd ${BASE}/metaSMT-*-deps/stp-git-basic/lib/ && pwd)" >> /home/klee/.bashrc'
+RUN /bin/bash -c 'echo "export LD_LIBRARY_PATH=$(cd ${BASE}/metaSMT-*-deps/stp-git-basic/lib/ && pwd):$LD_LIBRARY_PATH" >> /home/klee/.bashrc'
diff --git a/scripts/build/d-klee-linux-ubuntu.inc b/scripts/build/d-klee-linux-ubuntu.inc
index 38b8dce5..ca925a34 100644
--- a/scripts/build/d-klee-linux-ubuntu.inc
+++ b/scripts/build/d-klee-linux-ubuntu.inc
@@ -15,9 +15,10 @@ ADD --chown=klee:klee / ${BASE}/klee_src
 
 USER klee
 WORKDIR /home/klee
+ENV LD_LIBRARY_PATH /home/klee/klee_build/lib/
 
 # Add KLEE binary directory to PATH
 RUN /bin/bash -c 'ln -s ${BASE}/klee_src /home/klee/ && ln -s ${BASE}/klee_build* /home/klee/klee_build && echo "export PATH=\"$PATH:$(cd /tmp/llvm-*install*/bin && pwd):/home/klee/klee_build/bin\"" >> /home/klee/.bashrc'
 
 # TODO Remove when STP is fixed
-RUN /bin/bash -c 'echo "export LD_LIBRARY_PATH=$(cd ${BASE}/metaSMT-*-deps/stp-git-basic/lib/ && pwd)" >> /home/klee/.bashrc'
+RUN /bin/bash -c 'echo "export LD_LIBRARY_PATH=$(cd ${BASE}/metaSMT-*-deps/stp-git-basic/lib/ && pwd):$LD_LIBRARY_PATH" >> /home/klee/.bashrc'