-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
99 changed files
with
4,440 additions
and
1,795 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
*~ | ||
_obuild | ||
/tezos | ||
/tests/*.cm? | ||
/tests/*/*.cm? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# branches: | ||
# only: | ||
# - master | ||
dist: trusty | ||
language: ocaml | ||
sudo: required | ||
|
||
before_install: | ||
- sh travis-scripts/prepare-trusty.sh | ||
|
||
install: | ||
- sh travis-scripts/prepare-opam.sh | ||
|
||
script: | ||
- export OPAMYES=1 | ||
- opam sw 4.05.0 | ||
- eval `opam config env` | ||
- make clone-tezos | ||
- make | ||
- make tests-mini | ||
- make tests | ||
- make rev-tests | ||
|
||
# TODO > how to compile and test with tezos (I.e. with a fully compiled version of tezos)? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,26 @@ | ||
(* Version of the Liquidity compiler *) | ||
|
||
version = "1.0"; | ||
|
||
(* Disable to compile without the sources of Tezos. | ||
The following features with be disabled: | ||
* Decompilation of Michelson files | ||
* Execution of Michelson contracts | ||
*) | ||
|
||
Sys = module("ocp-build:Sys", "1.0"); | ||
|
||
(* This value is used if with_tezos is not set before *) | ||
default_with_tezos = true; | ||
default_with_tezos = Sys.file_exists("tezos/README.md"); | ||
|
||
try { with_tezos = with_tezos; } | ||
catch("unknown-variable",x){ with_tezos = default_with_tezos; } | ||
|
||
(* By default, liquidity will contain some version information | ||
(Git commit, build date, etc.). However, during development, it | ||
makes recompilation slower, so you can create a file DEVEL here | ||
to tell ocp-build not to include version information. | ||
The flag can also be controled in an inclusing project by using | ||
the 'with_version' option. | ||
*) | ||
|
||
default_with_version = !Sys.file_exists("DEVEL"); | ||
|
||
try { with_version = with_version; } | ||
catch("unknown-variable",x){ with_version = default_with_version; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,27 @@ | ||
#!/bin/sh | ||
|
||
DEFAULT='\033[0m' | ||
RED='\033[0;31m' | ||
|
||
test=$1 | ||
echo $test | ||
echo "\n[check-mini.sh] test = $test" | ||
|
||
LIQUIDITY=liquidity | ||
|
||
./_obuild/${LIQUIDITY}-mini/${LIQUIDITY}-mini.asm tests/$test.liq || exit 2 | ||
|
||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz | ||
|
||
if [ -f ./tezos/_obuild/tezos-client/tezos-client.asm ] ; then | ||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz | ||
else | ||
echo "\n${RED}./tezos/_obuild/tezos-client/tezos-client.asm not present ! typechecking of tests/$test.liq.tz skipped${DEFAULT}\n" | ||
fi | ||
|
||
./_obuild/${LIQUIDITY}/${LIQUIDITY}.asm tests/$test.liq.tz || exit 2 | ||
|
||
./_obuild/${LIQUIDITY}-mini/${LIQUIDITY}-mini.asm tests/$test.liq.tz.liq || exit 2 | ||
|
||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz.liq.tz | ||
if [ -f ./tezos/_obuild/tezos-client/tezos-client.asm ] ; then | ||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz.liq.tz | ||
else | ||
echo "\n${RED}./tezos/_obuild/tezos-client/tezos-client.asm not present ! typechecking of tests/$test.liq.tz.liq.tz skipped${DEFAULT}\n" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,34 @@ | ||
#!/bin/sh | ||
|
||
DEFAULT='\033[0m' | ||
RED='\033[0;31m' | ||
|
||
test=$1 | ||
echo $test | ||
echo "\n[check.sh] test = $test" | ||
|
||
LIQUIDITY=liquidity | ||
|
||
echo ./_obuild/${LIQUIDITY}/${LIQUIDITY}.asm tests/$test.liq | ||
./_obuild/${LIQUIDITY}/${LIQUIDITY}.asm tests/$test.liq || exit 2 | ||
|
||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz | ||
|
||
if [ -f ./tezos/_obuild/tezos-client/tezos-client.asm ] ; then | ||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz || exit 2 | ||
else | ||
echo "\n${RED}./tezos/_obuild/tezos-client/tezos-client.asm not present ! typechecking of tests/$test.liq.tz skipped${DEFAULT}\n" | ||
fi | ||
|
||
echo ./_obuild/${LIQUIDITY}/${LIQUIDITY}.asm tests/$test.liq.tz | ||
./_obuild/${LIQUIDITY}/${LIQUIDITY}.asm tests/$test.liq.tz || exit 2 | ||
|
||
echo ./_obuild/${LIQUIDITY}/${LIQUIDITY}.asm tests/$test.liq.tz.liq | ||
./_obuild/${LIQUIDITY}/${LIQUIDITY}.asm tests/$test.liq.tz.liq || exit 2 | ||
|
||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz.liq.tz | ||
if [ -f ./tezos/_obuild/tezos-client/tezos-client.asm ] ; then | ||
./tezos/_obuild/tezos-client/tezos-client.asm typecheck program tests/$test.liq.tz.liq.tz || exit 2 | ||
else | ||
echo "\n${RED}./tezos/_obuild/tezos-client/tezos-client.asm not present ! typechecking of tests/$test.liq.tz.liq.tz skipped${DEFAULT}\n" | ||
fi | ||
|
||
echo ./_obuild/ocp-liquidity-comp/ocp-liquidity-comp.asm -I +../zarith zarith.cma -I _obuild/liquidity-env ./_obuild/liquidity-env/liquidity-env.cma -impl tests/$test.liq | ||
./_obuild/ocp-liquidity-comp/ocp-liquidity-comp.asm -I +../zarith zarith.cma -I _obuild/liquidity-env ./_obuild/liquidity-env/liquidity-env.cma -dsource -impl tests/$test.liq | ||
rm -f a.out |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
open Utils | ||
|
||
#include "../../tezos/src/utils/cli_entries.ml" | ||
(* | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
|
||
open Tezos_context | ||
|
||
#include "../../tezos/src/client/embedded/alpha/client_proto_args.mli" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.