From 8096841543106bd318072932d671c2c84741f3a3 Mon Sep 17 00:00:00 2001 From: kstreee Date: Wed, 10 Feb 2016 05:09:03 -0800 Subject: [PATCH] Solve failure in 'docker build .'. Summary: An issue facebook/infer#270 suggest two docker build failure error. facebok/infer#270 issues two docker build failure errors. - failure in 'make -C infer clang java' : add './configure' before the command. - failure in building sources : add 'opam switch 4.02.3' to use this syntax in ' https://github.com/kstreee/infer/blob/cc4439938e99a27d301a2d42aa3413849dc55a46/infer/src/clang/cLocation.ml#L76 '. In ubuntu, when 'apt-get install ocaml' ( https://github.com/kstreee/infer/blob/cc4439938e99a27d301a2d42aa3413849dc55a46/docker/Dockerfile#L20 ), for now, it installs ocaml 4.01, but this syntax does not work with ocaml 4.01. Closes https://github.com/facebook/infer/pull/271 Reviewed By: jberdine Differential Revision: D2916909 Pulled By: jvillard fb-gh-sync-id: 3eba991 shipit-source-id: 3eba991 --- docker/Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index f3f03f539..92de01a27 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -34,7 +34,7 @@ RUN curl -sL \ https://github.com/ocaml/opam/releases/download/1.2.2/opam-1.2.2-x86_64-Linux \ -o /usr/local/bin/opam && \ chmod 755 /usr/local/bin/opam -RUN opam init -y --comp=4.01.0 && \ +RUN opam init -y --comp=4.02.3 && \ opam install -y extlib.1.5.4 atdgen.1.6.0 javalib.2.3.1 sawja.1.5.1 # Download the latest Infer release @@ -52,6 +52,7 @@ RUN INFER_VERSION=$(curl -s https://api.github.com/repos/facebook/infer/releases # Compile Infer RUN cd /infer && \ eval $(opam config env) && \ + ./configure && \ make -C infer clang java # Install Infer