ldmc/examples/01-uint-example/makefile

24 lines
578 B
Makefile
Raw Normal View History

all: build/square
.PHONY: build clean
build:
mkdir -p build
build/morphisms.h: build
ldmc \
-m "marshal: \
~ native.UInt64 \
--> ~ <PosInt 10 BigEndian> ~ <Seq~<ValueTerminated 0> <Digit 10>~Char~Ascii~native.UInt8>" \
\
-m "demarshal: \
~ <PosInt 10 BigEndian> ~ <Seq~<ValueTerminated 0> <Digit 10>~Char~Ascii~native.UInt8> \
--> ~ native.UInt64 " \
\
>| build/morphisms.h
build/square: build build/morphisms.h
gcc -Os -I../../morphisms/runtime/include/ -Ibuild main.c -o build/square
clean:
rm build/ -rf