Skip to content

Commit

Permalink
Build updates - fix releases (#419)
Browse files Browse the repository at this point in the history
* README: updated dependencies for llvm backend

* Makefile: proper target dependency for install

* Makefile: add uninstall target

* README: openjdk-{8 => 11}-jdk

* Makefile: only run erc20 test on test-interactive-firefly

* Dockerfile: update openjdk-{8 => 11}-jdk

* README: adoptopenjdk{8 => 12}

* Dockerfile: use rv bionic image
  • Loading branch information
ehildenb authored Jul 31, 2019
1 parent f17933e commit 9996303
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 29 deletions.
35 changes: 12 additions & 23 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,14 @@
FROM ubuntu:bionic

ENV TZ=America/Chicago
RUN ln --symbolic --no-dereference --force /usr/share/zoneinfo/$TZ /etc/localtime \
&& echo $TZ > /etc/timezone

RUN apt-get update \
&& apt-get upgrade --yes \
&& apt-get install --yes \
autoconf bison clang-8 cmake curl flex gcc libboost-test-dev \
libcrypto++-dev libffi-dev libjemalloc-dev libmpfr-dev libprocps-dev \
libsecp256k1-dev libssl-dev libtool libyaml-dev lld-8 llvm-8-tools \
make maven opam openjdk-8-jdk pandoc pkg-config python3 python-pygments \
python-recommonmark python-sphinx time zlib1g-dev protobuf-compiler \
libprotobuf-dev

RUN update-alternatives --set java /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java
FROM runtimeverificationinc/ubuntu:bionic

RUN apt-get update \
&& apt-get upgrade --yes \
&& apt-get install --yes \
autoconf bison clang-8 cmake curl flex gcc libboost-test-dev \
libcrypto++-dev libffi-dev libjemalloc-dev libmpfr-dev libprocps-dev \
libprotobuf-dev libsecp256k1-dev libssl-dev libtool libyaml-dev lld-8 \
llvm-8-tools make maven opam openjdk-11-jdk pandoc pkg-config \
protobuf-compiler python3 python-pygments python-recommonmark \
python-sphinx time zlib1g-dev

ADD deps/k/haskell-backend/src/main/native/haskell-backend/scripts/install-stack.sh /.install-stack/
RUN /.install-stack/install-stack.sh
Expand All @@ -28,12 +22,7 @@ RUN git clone 'https://github.com/z3prover/z3' --branch=z3-4.6.0 \
&& cd ../.. \
&& rm -rf z3

ARG USER_ID=1000
ARG GROUP_ID=1000
RUN groupadd --gid $GROUP_ID user \
&& useradd --create-home --uid $USER_ID --shell /bin/sh --gid user user

USER $USER_ID:$GROUP_ID
USER user:user

ADD --chown=user:user deps/k/llvm-backend/src/main/native/llvm-backend/install-rust deps/k/llvm-backend/src/main/native/llvm-backend/rust-checksum /home/user/.install-rust/
RUN cd /home/user/.install-rust \
Expand Down
10 changes: 7 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ LUA_PATH:=$(PANDOC_TANGLE_SUBMODULE)/?.lua;;
export TANGLER
export LUA_PATH

.PHONY: all clean clean-submodules distclean install \
.PHONY: all clean clean-submodules distclean install uninstall \
deps all-deps llvm-deps haskell-deps repo-deps system-deps k-deps ocaml-deps plugin-deps libsecp256k1 libff \
build build-ocaml build-java build-node build-kore split-tests \
defn java-defn ocaml-defn node-defn haskell-defn llvm-defn \
Expand Down Expand Up @@ -331,10 +331,14 @@ $(llvm_kompiled): $(llvm_files) $(libff_out)

KEVM_RELEASE_TAG?=

install: $(node_kompiled)
install: $(INSTALL_DIR)/$(notdir $(node_kompiled))
$(INSTALL_DIR)/$(notdir $(node_kompiled)): $(node_kompiled)
mkdir -p $(INSTALL_DIR)
cp $(node_kompiled) $(INSTALL_DIR)/

uninstall:
rm $(INSTALL_DIR)/$(notdir $(node_kompiled))

release.md: INSTALL.md
echo "KEVM Release $(KEVM_RELEASE_TAG)" > $@
echo >> $@
Expand Down Expand Up @@ -484,7 +488,7 @@ test-interactive-firefly:
&& git checkout b8c8308 \
&& { npx kevm-ganache-cli --gasLimit 0xfffffffffff --port 8545 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501200,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501201,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501202,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501203,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501204,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501205,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501206,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501207,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501208,1000000000000000000000000 --account=0x2bdd21761a483f71054e14f5b827213567971c676928d9a1808cbfa4b7501209,1000000000000000000000000 & } \
&& npm install \
&& npx truffle test
&& npx truffle test test/token/ERC20/ERC20.test.js

# Media
# -----
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ On Ubuntu >= 18.04 (for example):
```sh
sudo apt install \
autoconf bison flex gcc git libmpfr-dev libsecp256k1-dev \
libtool libz3-dev make maven opam openjdk-8-jdk pandoc \
libtool libz3-dev make maven opam openjdk-11-jdk pandoc \
pkg-config z3 zlib1g-dev
```

Expand All @@ -79,7 +79,7 @@ On OSX, using [Homebrew](https://brew.sh/), after installing the command line to

```sh
brew tap caskroom/cask
brew cask install adoptopenjdk8
brew cask install adoptopenjdk12
brew install automake libtool gmp mpfr pkg-config pandoc maven opam z3 libffi
make libsecp256k1
```
Expand Down Expand Up @@ -138,7 +138,7 @@ export PATH=$HOME/.local/bin:$PATH
The LLVM backend has additional dependencies:

```k
sudo apt install cmake clang-8 clang++-8 llvm-8 lld-8 libboost-test-dev libgmp-dev libyaml-cpp-dev libjemalloc-dev curl protobuf-compiler libprotobuf-dev
sudo apt install cmake clang-8 clang++-8 llvm-8 llvm-8-tools lld-8 libboost-test-dev libgmp-dev libprocps-dev libyaml-dev libjemalloc-dev curl protobuf-compiler libprotobuf-dev
```

On Arch, you'll also need `crypto++` package.
Expand Down

0 comments on commit 9996303

Please sign in to comment.