#!/bin/sh -e CC=${CC:-musl-gcc} STATIC=${STATIC:-"-static"} CFLAGS=" \ -std=c89 \ -Wall -Wextra -Wno-comment \ -ggdb -Og \ " bench() { if [ x = "x$(which time 2>/dev/null)" ]; then $@ echo "time not installed" else time $@ fi } mkdir -p artifacts >&2 bench $CC $CFLAGS sources/main.c $STATIC -o artifacts/xip-8 >&2 echo "------------------------------------------------\n"