aboutsummaryrefslogtreecommitdiff
path: root/build.sh
blob: 8307dfe04c1da62f5a398709286c1b981c46ac6a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

set -e

this_script_path=$(readlink -f "$0")
this_script_dir=$(dirname "$this_script_path")
source_files=$(readlink -f "$this_script_dir/src/"*)

if [ -z "$CC" ]; then
    CC=cc
fi

CFLAGS="-Wall -Wextra -Werror -g -O0 -DDEBUG -std=c89 -pedantic"
LIBS="-pthread"

set -x
time "$CC" $source_files $CFLAGS $LIBS -o amalgam