(library
 (name tezos_protocol_006_PsCARTHA_parameters)
 (public_name tezos-protocol-006-PsCARTHA-parameters)
 (modules :standard \ gen)
 (libraries tezos-base
            tezos-protocol-environment
            tezos-protocol-006-PsCARTHA)
 (flags (:standard -open Tezos_base__TzPervasives
                   -open Tezos_protocol_006_PsCARTHA
                   -linkall))
)

(executable
 (name gen)
 (libraries tezos-base
            tezos-protocol-006-PsCARTHA-parameters)
 (modules gen)
 (flags (:standard -open Tezos_base__TzPervasives
                   -open Tezos_protocol_006_PsCARTHA_parameters
                   -linkall)))

(rule
 (targets sandbox-parameters.json)
 (deps gen.exe)
 (action (run %{deps} --sandbox)))

(rule
 (targets test-parameters.json)
 (deps gen.exe)
 (action (run %{deps} --test)))

(rule
 (targets mainnet-parameters.json)
 (deps gen.exe)
 (action (run %{deps} --mainnet)))

(install
 (section lib)
 (files sandbox-parameters.json test-parameters.json mainnet-parameters.json))

(alias
 (name runtest_lint)
 (deps (glob_files *.ml{,i}))
 (action (run %{lib:tezos-tooling:lint.sh} %{deps})))
