diff --git a/src/Makefile b/src/Makefile index a3f7375e3..c1d667365 100644 --- a/src/Makefile +++ b/src/Makefile @@ -309,14 +309,14 @@ partial-clean:: ## Embedded client protocol modules -client/embedded/client_%.cmx: \ +client/embedded/client_embedded_%.cmx: \ $(patsubst %.ml, %.cmx, $(NODE_LIB_IMPLS) $(CLIENT_LIB_IMPLS)) \ proto/tezos_embedded_protocol_%.cmx \ $$(shell find client/embedded/% \( -name _tzbuild \) -prune -or \( -name \*.ml -print -or -name \*.mli -print \)) - @$(MAKE) -C client/embedded/$* ../client_$*.cmx + @$(MAKE) -C client/embedded/$* ../client_embedded_$*.cmx -client/embedded/client_genesis.cmx: \ - client/embedded/client_alpha.cmx +client/embedded/client_embedded_genesis.cmx: \ + client/embedded/client_embedded_alpha.cmx partial-clean:: -for d in $$(ls -d client/embedded/*/) ; do make clean -C $$d ; done diff --git a/src/Makefile.files b/src/Makefile.files index 763a91b09..6552bfce3 100644 --- a/src/Makefile.files +++ b/src/Makefile.files @@ -359,7 +359,7 @@ CLIENT_VERSIONS := \ $(shell ls -d ${SRCDIR}/client/embedded/*/)) EMBEDDED_CLIENT_VERSIONS := \ - $(patsubst %,${SRCDIR}/client/embedded/client_%.cmx, \ + $(patsubst %,${SRCDIR}/client/embedded/client_embedded_%.cmx, \ ${CLIENT_VERSIONS}) diff --git a/src/client/embedded/Makefile.shared b/src/client/embedded/Makefile.shared index 2af2851c3..3f41adbe3 100644 --- a/src/client/embedded/Makefile.shared +++ b/src/client/embedded/Makefile.shared @@ -1,6 +1,6 @@ all: \ - ../client_$(PROTO_VERSION).cmx + ../client_embedded_$(PROTO_VERSION).cmx -include ../../../Makefile.local include ../../../Makefile.config @@ -31,15 +31,15 @@ OBJS := \ OBJS_DEPS := \ ${CLIENT_IMPLS:.ml=.ml.deps} ${CLIENT_INTFS:.mli=.mli.deps} -${OBJS} ${OBJS_DEPS}: TARGET="(client_$(PROTO_VERSION).cmx)" -${OBJS}: EXTRA_OCAMLFLAGS = -for-pack Client_$(PROTO_VERSION) -../client_$(PROTO_VERSION).cmx: EXTRA_OCAMLFLAGS = -${OBJS} ${OBJS_DEPS} ../client_$(PROTO_VERSION).cmx: \ +${OBJS} ${OBJS_DEPS}: TARGET="(client_embedded_$(PROTO_VERSION).cmx)" +${OBJS}: EXTRA_OCAMLFLAGS = -for-pack Client_embedded_$(PROTO_VERSION) +../client_embedded_$(PROTO_VERSION).cmx: EXTRA_OCAMLFLAGS = +${OBJS} ${OBJS_DEPS} ../client_embedded_$(PROTO_VERSION).cmx: \ PACKAGES=lwt ocplib-json-typed sodium ocplib-ocamlres uutf ocplib-endian zarith -${OBJS} ${OBJS_DEPS} ../client_$(PROTO_VERSION).cmx: \ +${OBJS} ${OBJS_DEPS} ../client_embedded_$(PROTO_VERSION).cmx: \ ../../../proto/tezos_embedded_protocol_${PROTO_VERSION}.cmx -../client_$(PROTO_VERSION).cmx: $(patsubst %.ml, %.cmx, ${CLIENT_IMPLS}) +../client_embedded_$(PROTO_VERSION).cmx: $(patsubst %.ml, %.cmx, ${CLIENT_IMPLS}) @echo LINK $(notdir $@) @$(OCAMLOPT) -linkall ${OCAMLFLAGS} -pack -o $@ \ $(patsubst %.ml, %.cmx, ${CLIENT_IMPLS}) @@ -58,7 +58,7 @@ ${OBJS} ${OBJS_DEPS} ../client_$(PROTO_VERSION).cmx: \ .PHONY: clean clean:: - -rm -f ../client_$(PROTO_VERSION).cm* ../client_$(PROTO_VERSION).o + -rm -f ../client_embedded_$(PROTO_VERSION).cm* ../client_embedded_$(PROTO_VERSION).o -rm -f *.cm* *~ *.o *.a *.deps *.deps.byte -rm -rf _tzbuild -rm -f .depend diff --git a/src/client/embedded/alpha/Makefile b/src/client/embedded/alpha/Makefile index c7c972706..d5e1f651f 100644 --- a/src/client/embedded/alpha/Makefile +++ b/src/client/embedded/alpha/Makefile @@ -41,14 +41,7 @@ CLIENT_IMPLS := \ client_mining_daemon.ml \ client_mining_main.ml --include baker/Makefile - include ../Makefile.shared ${OBJS_DEPS} ${OBJS}: OPENED_MODULES += Client_proto_alpha Tezos_context client_proto_alpha.ml.deps client_proto_alpha.cmx: OPENED_MODULES := - -.PHONY: clean -clean:: - -rm -f baker/*.cm* baker/*~ baker/*.o baker/*.a - -rm -f baker/*.deps baker/*.deps.byte diff --git a/src/client/embedded/genesis/Makefile b/src/client/embedded/genesis/Makefile index 3ece3e8a1..a8ad2d905 100644 --- a/src/client/embedded/genesis/Makefile +++ b/src/client/embedded/genesis/Makefile @@ -12,8 +12,8 @@ include ../Makefile.shared SOURCE_DIRECTORIES += .. -${OBJS_DEPS} ${OBJS}: ../client_alpha.cmx +${OBJS_DEPS} ${OBJS}: ../client_embedded_alpha.cmx ${OBJS_DEPS} ${OBJS}: OPENED_MODULES += Client_proto_genesis client_proto_genesis.ml.deps client_proto_genesis.cmx: OPENED_MODULES := -../client_alpha.cmx: +../client_embedded_alpha.cmx: diff --git a/src/client/embedded/genesis/client_proto_main.ml b/src/client/embedded/genesis/client_proto_main.ml index f059dc2a4..b7ad8a56a 100644 --- a/src/client/embedded/genesis/client_proto_main.ml +++ b/src/client/embedded/genesis/client_proto_main.ml @@ -73,7 +73,7 @@ let commands () = @@ stop) begin fun timestamp hash fitness seckey cctxt -> let fitness = - Client_alpha.Client_proto_alpha.Fitness_repr.from_int64 fitness in + Client_embedded_alpha.Client_proto_alpha.Fitness_repr.from_int64 fitness in mine cctxt.rpc_config ?timestamp cctxt.config.block (Activate hash) fitness seckey >>=? fun hash -> cctxt.answer "Injected %a" Block_hash.pp_short hash >>= fun () -> @@ -96,7 +96,7 @@ let commands () = @@ stop) begin fun timestamp hash fitness seckey cctxt -> let fitness = - Client_alpha.Client_proto_alpha.Fitness_repr.from_int64 fitness in + Client_embedded_alpha.Client_proto_alpha.Fitness_repr.from_int64 fitness in mine cctxt.rpc_config ?timestamp cctxt.config.block (Activate_testnet (hash, Int64.mul 24L 3600L)) fitness seckey >>=? fun hash -> diff --git a/test/Makefile.shared b/test/Makefile.shared index 8c328e521..0bf13f39d 100644 --- a/test/Makefile.shared +++ b/test/Makefile.shared @@ -43,7 +43,7 @@ NODELIB := ${SRCDIR}/node.cmxa CLIENTLIB := ${SRCDIR}/client.cmxa \ $(patsubst ${SRCDIR}/client/embedded/%/, \ - ${SRCDIR}/client/embedded/client_%.cmx, \ + ${SRCDIR}/client/embedded/client_embedded_%.cmx, \ $(shell ls -d ${SRCDIR}/client/embedded/*/)) ${MINUTILSLIB} ${UTILSLIB} ${COMPILERLIB} ${NODELIB} ${CLIENTLIB}: diff --git a/test/proto_alpha/Makefile b/test/proto_alpha/Makefile index 01bfcd6a1..45794a591 100644 --- a/test/proto_alpha/Makefile +++ b/test/proto_alpha/Makefile @@ -26,12 +26,12 @@ PACKAGES := \ OPENED_MODULES := \ ${CLIENT_OPENED_MODULES} \ - Client_alpha Client_proto_alpha Tezos_context + Client_embedded_alpha Client_proto_alpha Tezos_context ${SRCDIR}/client/embedded/alpha/%.cmi: ${SRCDIR}/client/embedded/alpha/%.mli - ${MAKE} -C ${SRCDIR} client/embedded/client_alpha.cmx + ${MAKE} -C ${SRCDIR} client/embedded/client_embedded_alpha.cmx ${SRCDIR}/client/embedded/alpha/%.cmx: ${SRCDIR}/client/embedded/alpha/%.ml - ${MAKE} -C ${SRCDIR} client/embedded/client_alpha.cmx + ${MAKE} -C ${SRCDIR} client/embedded/client_embedded_alpha.cmx ############################################################################ ## Transactions diff --git a/test/proto_alpha/proto_alpha_helpers.ml b/test/proto_alpha/proto_alpha_helpers.ml index fe4001987..ca7a8ed2c 100644 --- a/test/proto_alpha/proto_alpha_helpers.ml +++ b/test/proto_alpha/proto_alpha_helpers.ml @@ -27,7 +27,7 @@ let dictator_sk = let activate_alpha () = let fitness = Fitness_repr.from_int64 0L in - Client_genesis.Client_proto_main.mine + Client_embedded_genesis.Client_proto_main.mine rpc_config (`Head 0) (Activate Client_proto_main.protocol) fitness dictator_sk @@ -49,7 +49,7 @@ let init ?(sandbox = "sandbox.json") () = return (pid, hash) let level block = - Client_alpha.Client_proto_rpcs.Context.level rpc_config block + Client_proto_rpcs.Context.level rpc_config block module Account = struct diff --git a/test/proto_alpha/proto_alpha_helpers.mli b/test/proto_alpha/proto_alpha_helpers.mli index aa1a40cd5..515e92d62 100644 --- a/test/proto_alpha/proto_alpha_helpers.mli +++ b/test/proto_alpha/proto_alpha_helpers.mli @@ -107,11 +107,11 @@ module Endorse : sig val endorse : ?slot:int -> Account.t -> - Client_alpha.Client_proto_rpcs.block -> + Client_proto_rpcs.block -> Operation.raw tzresult Lwt.t val endorsers_list : - Client_alpha.Client_proto_rpcs.block -> + Client_proto_rpcs.block -> Account.t array tzresult Lwt.t val endorsement_rights : diff --git a/test/proto_alpha/test_michelson_parser.ml b/test/proto_alpha/test_michelson_parser.ml index 582ee0a56..2f50d72f4 100644 --- a/test/proto_alpha/test_michelson_parser.ml +++ b/test/proto_alpha/test_michelson_parser.ml @@ -7,9 +7,7 @@ (* *) (**************************************************************************) -open Client_embedded_proto_alpha open Tezos_context.Script -open Client_alpha module Helpers = Proto_alpha_helpers module Assert = Helpers.Assert