Skip to content

Commit

Permalink
Add shelley-ma to Readme and add a makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
Jared Corduan committed Sep 21, 2020
1 parent adb691c commit 1408241
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Expand Up @@ -14,6 +14,7 @@ Formal and executable specifications for the new features to be introduced by Sh
The documents are built in our CI and can be readily accessed using the
following links:

- [Multi-asset formal specification](https://hydra.iohk.io/job/Cardano/cardano-ledger-specs/specs.shelley-ma/latest/download-by-type/doc-pdf/shelley-ma): the formal mathematical specification of the additon of multi-assets to the Shelley era ledger rules.
- [Shelley design specification](https://hydra.iohk.io/job/Cardano/cardano-ledger-specs/delegationDesignSpec/latest/download-by-type/doc-pdf/delegation_design_spec): the primary design document for Cardano Shelley.
- [Shelley ledger formal specification](https://hydra.iohk.io/job/Cardano/cardano-ledger-specs/shelleyLedgerSpec/latest/download-by-type/doc-pdf/ledger-spec): the formal mathematical specification of the Shelley era ledger rules.
- [Shelley binary format specification (CDDL)](https://github.com/input-output-hk/cardano-ledger-specs/tree/master/shelley/chain-and-ledger/shelley-spec-ledger-test/cddl-files): the binary formats for the Shelley ledger using CBOR CDDL schema notation.
Expand Down
50 changes: 50 additions & 0 deletions shelley-ma/formal-spec/Makefile
@@ -0,0 +1,50 @@
##
## Makefile for a specification of the delegation rules, based on:
##
## https://tex.stackexchange.com/questions/40738/how-to-properly-make-a-latex-project
##

# Document name
ifndef DOCNAME
DOCNAME = shelley-ma
endif

# You want latexmk to *always* run, because make does not have all the info.
# Also, include non-file targets in .PHONY so they are run regardless of any
# file of the given name existing.
.PHONY: $(DOCNAME).pdf all clean

# The first rule in a Makefile is the one executed by default ("make"). It
# should always be the "all" rule, so that "make" and "make all" are identical.
all: $(DOCNAME).pdf

##
## CUSTOM BUILD RULES
##

##
## MAIN LATEXMK RULE
##

# -pdf tells latexmk to generate PDF directly (instead of DVI).
# -pdflatex="" tells latexmk to call a specific backend with specific options.
# -use-make tells latexmk to call make for generating missing files.

# -interaction=nonstopmode keeps the pdflatex backend from stopping at a
# missing file reference and interactively asking you for an alternative.

$(DOCNAME).pdf: $(DOCNAME).tex
latexmk -pdf -pdflatex="pdflatex -synctex=1 -interaction=nonstopmode" -use-make $(DOCNAME).tex

watch: $(DOCNAME).tex
latexmk -pvc -pdf -pdflatex="pdflatex -synctex=1 -interaction=nonstopmode" -use-make $(DOCNAME).tex

clean:
latexmk -CA

install:
mkdir -pv ${out}/nix-support/
for i in $(DOCNAME) ; do \
cp $$i.pdf ${out}/ ; \
echo "doc-pdf $$i ${out}/$$i.pdf" >> ${out}/nix-support/hydra-build-products ; \
done

0 comments on commit 1408241

Please sign in to comment.