24 lines
578 B
Makefile
24 lines
578 B
Makefile
|
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
|